Home

Awesome

DDSTGCN

License: MIT Last Commit Issues

[Paper] [Code] [Google Scholar]

Y. Sun, X. Jiang, Y. Hu, F. Duan, K. Guo, B. Wang, J. Gao, B. Yin, "Dual Dynamic Spatial-Temporal Graph Convolution Network for Traffic Prediction," in IEEE Transactions on Intelligent Transportation Systems, vol. 23, no. 12, pp. 23680-23693, Dec. 2022, doi: 10.1109/TITS.2022.3208943.

<p align="center"> <img width="826" height="303" src=./fig/picture.jpg> </p>

Requirements

You can install all the requirements by python3 -m pip install -r requirements.txt.

Train Commands

python train.py

or

python train.py --data "data/METR-LA" --adjdata "data/METR-LA/adj_mx.pkl" --in_dim 2 --num_nodes 207

To run different datasets, you need to modify the relevant parameters of the dataset, including --data, --adjdata, --in_dim and --num_nodes. The default is METR-LA dataset.

Datasets

Dataset--data--adjdata--in_dim--num_nodes
METR-LAdata/METR-LAdata/METR-LA/adj_mx.pkl2207
PEMS-BAYdata/PEMS-BAYdata/PEMS-BAY/adj_mx_bay.pkl2325
PEMS03data/PEMS03data/PEMS03/adj_pems03.pkl1358
PEMS04data/PEMS04data/PEMS04/adj_pems04.pkl1307
PEMS07data/PEMS07data/PEMS07/adj_pems07.pkl1883
PEMS08data/PEMS08data/PEMS08/adj_pems08.pkl1170

Download the datasets from Google Drive URL: https://drive.google.com/drive/folders/1uoY8ROQU73BqWyl566ZNdRBOOTM4T2DS?usp=sharing

Code Architecture

  DDSTGCN
    │  train.py
    │  engine.py
    │  model.py
    │  util.py
    │  requirements.txt
    │  README.md
    │  LICENSE
    │
    ├─data
    │  ├─METR-LA
    │  │      adj_mx.pkl
    │  │      train.npz
    │  │      val.npz
    │  │      test.npz
    │  │
    │  ├─PEMS-BAY
    │  │      adj_mx_bay.pkl
    │  │      train.npz
    │  │      val.npz
    │  │      test.npz
    │  │
    │  ├─PEMS03
    │  │      adj_pems03.pkl
    │  │      train.npz
    │  │      val.npz
    │  │      test.npz
    │  │
    │  ├─PEMS04
    │  │      adj_pems04.pkl
    │  │      train.npz
    │  │      val.npz
    │  │      test.npz
    │  │
    │  ├─PEMS07
    │  │      adj_pems07.pkl
    │  │      train.npz
    │  │      val.npz
    │  │      test.npz
    │  │
    │  └─PEMS08
    │          adj_pems08.pkl
    │          train.npz
    │          val.npz
    │          test.npz
    │
    ├─fig
    │      picture.jpg
    │
    └─garage
            null

License

Copyright © 2022 Jiang Xiangheng

This project is licensed under the MIT license.

Contact

jiangxiangheng[at]gmail[dot]com

Citation

If our work is helpful for your research, please consider citing the following BibTeX entry in your manuscript:

@article{sun2022dual,
   author={Sun, Yanfeng and Jiang, Xiangheng and Hu, Yongli and Duan, Fuqing and Guo, Kan and Wang, Boyue and Gao, Junbin and Yin, Baocai},
   journal={IEEE Transactions on Intelligent Transportation Systems},
   title={Dual Dynamic Spatial-Temporal Graph Convolution Network for Traffic Prediction},
   year={2022},
   volume={23},
   number={12},
   pages={23680-23693},
   publisher={IEEE},
   doi={10.1109/TITS.2022.3208943}
}