Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Working on Graph data #5

Open
JasonStraka opened this issue Jul 2, 2024 · 4 comments
Open

Working on Graph data #5

JasonStraka opened this issue Jul 2, 2024 · 4 comments

Comments

@JasonStraka
Copy link

Hi, thank you for your nice work and for sharing the code.

The datasets used in expernments are based on grid structure with Shape: $(N \times T \times H \times W)$ , but in README (which says UniST supports Data Format of Grid/Graph). How to Work on Graph data like METR-LA (Metro Traffic Los Angeles) with shape [N, T, C] (Number of nodes, time length, feature). There is no grid structure in raw dataset METR-LA.

@YuanYuan98
Copy link
Collaborator

To adapt UniST to graph-based data, you can adjust the spatial patch size to 1. This will allow you to apply the same spatio-temporal patching technique that is used for grid-based data.

Specifically, you would reshape the data to have a shape of $N\times T \times 1 \times W$, where $W$ is the number of nodes.

This will enable UniST to process the graph data by treating each node as a single spatial unit over time.

@YuanYuan98 YuanYuan98 reopened this Jul 2, 2024
@HuangYH0921
Copy link

Hello, may I ask how to reflect the relationship between the spatial positions of each point after the data is reshaped into the shape of N × T × 1 × W? For example, how do I input the adjacency matrix?

@ZhangXiangyu23
Copy link

Hello, may I ask how to reflect the relationship between the spatial positions of each point after the data is reshaped into the shape of N × T × 1 × W? For example, how do I input the adjacency matrix?

Hi, I have the same question. According to the modifications provided by the authors, this four-dimensional tensor can represent time and features, but it cannot represent the connectivity between topologies (i.e. the adjacency matrix). Friend, have you solved this problem yet? Is it convenient to communicate?

@ZhangXiangyu23
Copy link

To adapt UniST to graph-based data, you can adjust the spatial patch size to 1. This will allow you to apply the same spatio-temporal patching technique that is used for grid-based data.

Specifically, you would reshape the data to have a shape of N × T × 1 × W , where W is the number of nodes.

This will enable UniST to process the graph data by treating each node as a single spatial unit over time.

Hello, author. The modification you mentioned, my understanding is: W-dimension data is the characteristic value corresponding to each graph node, that is, W= the number of topology graph nodes. H=1, N is the number of samples, and T is the length of time. This represents only the features in the topology, but how do you represent the adjacencies in the topology? Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants