https://github.com/crim-ca/t-gcn

Temporal Graph Convolutional Network for Urban Traffic Flow Prediction Method

https://github.com/crim-ca/t-gcn

Science Score: 10.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
    Links to: arxiv.org
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (13.4%) to scientific vocabulary
Last synced: 10 months ago · JSON representation

Repository

Temporal Graph Convolutional Network for Urban Traffic Flow Prediction Method

Basic Info
  • Host: GitHub
  • Owner: crim-ca
  • License: mit
  • Language: Jupyter Notebook
  • Default Branch: master
  • Size: 30.4 MB
Statistics
  • Stars: 0
  • Watchers: 6
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Fork of lehaifeng/T-GCN
Created about 7 years ago · Last pushed about 7 years ago

https://github.com/crim-ca/T-GCN/blob/master/

This is a TensorFlow implementation of T-GCN: A Temporal Graph Convolutional Network for Traffic Prediction.

# Manuscript
## T-GCN: A Temporal Graph Convolutional Network for Traffic Prediction

Accurate and real-time traffic forecasting plays an important role in the Intelligent Traffic System and is of great significance for urban traffic planning, traffic management, and traffic control. However, traffic forecasting has always been considered an open scientific issue, owing to the constraints of urban road network topological structure and the law of dynamic change with time, namely, spatial dependence and temporal dependence. To capture the spatial and temporal dependence simultaneously, we propose a novel neural network-based traffic forecasting method, the temporal graph convolutional network (T-GCN) model, which is in combination with the graph convolutional network (GCN) and gated recurrent unit (GRU). Specifically, the GCN is used to learn complex topological structures to capture spatial dependence and the gated recurrent unit is used to learn dynamic changes of traffic data to capture temporal dependence. Then, the T-GCN model is employed to traffic forecasting based on the urban road network. Experiments demonstrate that our T-GCN model can obtain the spatio-temporal correlation from traffic data and the predictions outperform state-of-art baselines on real-world traffic datasets. 

The manuscript can be visited at https://arxiv.org/abs/1811.05320

GCN module:
GRU module:
T-GCN Cell:
# The Code ## Notebooks To make code review easier, all notebooks have to be cleaned with `nbstripout`. Two choices here; either: 1. the notebook is manually cleaned with `nbstripout ` 2. or the utility is installed as a git filter, as such: `nbstripout --install` (see [this video](https://www.youtube.com/watch?v=BEMP4xacrVc) for a quick understanding) ## Requirements: * tensorflow * scipy * numpy * matplotlib * pandas * math Install it with `conda create -f environment.yml` (or `conda update`, if you have a conda environment already; look [here](conda env update -f local.yml --prune) if you need specific help) ## Run the demo Python main.py Our baselines included:
(1) History Average model (HA)
(2) Autoregressive Integrated Moving Average model (ARIMA)
(3) Support Vector Regression model (SVR)
(4) Graph Convolutional Network model (GCN)
(5) Gated Recurrent Unit model (GRU)
The python implementations of HA/ARIMA/SVR models were in the baselines.py; The GCN and GRU models were in gcn.py and gru.py respective. The T-GCN model was in the tgcn.py ## Implement In this paper, we set time interval as 15 minutes, 30 minutes, 45 minutes and 60 minutes. In the sz_taxi dataset, we set the parameters seq_len to 4 and pre_len to 1, 2, 3, 4; In the los_loop dataset, we set the parameters seq_len 12 and the pre_len to 3, 6, 9, 12 respectively. ## Data Description There are two datasets in the data fold.
(1) SZ-taxi. This dataset was the taxi trajectory of Shenzhen from Jan. 1 to Jan. 31, 2015. We selected 156 major roads of Luohu District as the study area.
(2) Los-loop. This dataset was collected in the highway of Los Angeles County in real time by loop detectors. We selected 207 sensors and its traffic speed from Mar.1 to Mar.7, 2012 In order to use the model, we need * A N by N adjacency matrix, which describes the spatial relationship between roads, * A N by D feature matrix, which describes the speed change over time on the roads.

Owner

  • Name: crim-ca
  • Login: crim-ca
  • Kind: organization

GitHub Events

Total
Last Year