STWave
[ICDE'2023] When Spatio-Temporal Meet Wavelets: Disentangled Traffic Forecasting via Efficient Spectral Graph Attention Networks
This is a official PyTorch implementation of the paper: [When Spatio-Temporal Meet Wavelets: Disentangled Traffic Forecasting via Efficient Spectral Graph Attention Networks](https://ieeexplore.ieee.org/document/10184591). The project is written primarily in Python, first published in 2022. Key topics include: graph-attention-networks, graph-neural-networks, graph-transformer, graph-wavelets, icde2023.
[ICDE'2023] STWave
π Introduction
This is a official PyTorch implementation of the paper: When Spatio-Temporal Meet Wavelets: Disentangled Traffic Forecasting via Efficient Spectral Graph Attention Networks.
<img src="./stwave.png" align="middle" width="95%">β‘ Environment
- PyTorch
- fastdtw
- PyWavelets
π§ Data Preparation
PeMSD3 & PeMSD4 & PeMSD7 & PeMSD8
- Download the data PeMSD* with code: p72z.
- Unzip them to corresponding folders.
PeMSD7(M) & PeMSD7(L)
-
Download the data PeMSD7(M).
-
Email authors of STGCN to get the data PeMSD7(L).
Tips
- The name of downloaded datasets should be consistent with the name in config files.
π Folder Structure
texβββ code-and-data βββ config # Including detail configurations βββ cpt # Storing pre-trained weight files (should be created) βββ data # Including adj files and the main data should be downloaded βββ lib β |ββ utils.py # Codes of preprocessing datasets and calculating metrics β |ββ graph_utils.py # Codes of calculating eigens and deriving the temporal graph βββ log # Storing log files (should be created) βββ model β |ββ models.py # The core source code of our STWave βββ mian.py # This is the main file for training and testing βββ README.md # This document
π Run
Given the example of PeMSD8
bashmkdir ./cpt/PeMSD8 mkdir ./log/PeMSD8 python main.py --config config/PeMSD8.conf
π¬ Citation
If you find our work is helpful, please cite as:
text@inproceedings{fang2023spatio, title={When spatio-temporal meet wavelets: Disentangled traffic forecasting via efficient spectral graph attention networks}, author={Fang, Yuchen and Qin, Yanjun and Luo, Haiyong and Zhao, Fang and Xu, Bingbing and Zeng, Liang and Wang, Chenxing}, booktitle={2023 IEEE 39th International Conference on Data Engineering (ICDE)}, pages={517--529}, year={2023}, organization={IEEE} }
Further Reading
- Efficient Large-Scale Traffic Forecasting with Transformers: A Spatial Data Management Perspective, in SIGKDD 2025.
[GitHub Repo]
Authors: Yuchen Fang, Yuxuan Liang, Bo Hui, Zezhi Shao, Liwei Deng, Xu Liu, Xinke Jiang, Kai Zheng.
bibtex@article{fang2024efficient, title={Efficient Large-Scale Traffic Forecasting with Transformers: A Spatial Data Management Perspective}, author={Fang, Yuchen and Liang, Yuxuan and Hui, Bo and Shao, Zezhi and Deng, Liwei and Liu, Xu and Jiang, Xinke and Zheng, Kai}, journal={arXiv preprint arXiv:2412.09972}, year={2024} }
π Contributing
We welcome contributions and suggestions!
Contributors
Showing top 1 contributor by commit count.
