gsta
GSTA: Gated Spatial-Temporal Attention Approach for Travel Time Prediction
Science Score: 57.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
✓DOI references
Found 5 DOI reference(s) in README -
○Academic publication links
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (10.1%) to scientific vocabulary
Keywords
Repository
GSTA: Gated Spatial-Temporal Attention Approach for Travel Time Prediction
Basic Info
Statistics
- Stars: 6
- Watchers: 1
- Forks: 1
- Open Issues: 0
- Releases: 0
Topics
Metadata Files
README.md
GSTA
- The source code and data of the paper "GSTA: gated spatial–temporal attention approach for travel time prediction"

Spatial-temporal Attention

Data
- A sample of 81K trips is provided for each of the NYC and Chengdu Taxi datasets in folders (NYC Data, Chengdu Data).
- The data samples are already pre-processed (Data Cleaning, Feature Engineering,... etc) and randomly split into train (Xtrain, Ytrain), validation (Xval, Yval), and test (Xtest, Ytest).
- The implementation of the prediction model for each dataset is given in a separate jupyter notebook (GSTA on NYC.ipynb, and GSTA on Chengdu.ipynb).
Each data sample is a CSV file. The key contains:
* Location Features: 'pickuplongitude', 'pickuplatitude', 'dropofflongitude', 'dropofflatitude', 'centerlatitude', 'centerlongitude', 'dropoffpca0', 'dropoffpca1', 'pickuppca0', 'pickuppca1'
* Cluster Features: 'pickupcluster', 'dropoffcluster', 'pickupcountsonclusterid', 'dropoffcountsonclusterid'
* Geo-hash Features: 'pickupgeohash', 'dropoffgeohash'
* Date/Time Features: 'DayofMonthsin', 'DayofMonthcos', 'Hoursin', 'Hourcos', 'dayofweeksin', 'dayofweekcos', 'Weekendday', 'Workday'
* Weather Features: 'tempm', 'dewptm', 'hum', 'rain', 'snow', 'wdird', 'vism', 'fog', 'thunder', 'tornado', 'condsClear', 'condsHaze',
'condsHeavy Rain', 'condsHeavy Snow', 'condsLight Rain', 'condsLight Snow'
* Distance: 'distancehaversine', 'distancedummymanhattan'
* Direction: 'direction'
* Speed: 'avgspeedKMperHour'
* Public Holiday: 'PublicHoliday'
* Peak period: 'PeakHour'
* Travel Time: 'tripduration'
Parameters:
(These parameteres are tuned with whole dataset, you can change them manually)
The default parameters are:
- optimizer=Adam(lr=0.001).
- loss='meanabsoluteerror'
- metrics=['mae','mape']
- Dropout=0.2
- epochs = 50
- batchsize = 256
- kernelregularizer=l2(0.001)
- Activation('elu')
- BatchNormalization(epsilon=1e-06, momentum=0.98)
- kernelinitializer="heuniform"
- num_heads = 4 , which is the number of heads in Multi-Head attention.
Results

Best Model
The best model for each data during training phase is saved to folder "Models" as hdf5 file.
Dependencies:
Keras 2.4.3, Tensorflow 2.3.0, Bokeh 2.2.1, Numpy 1.19.3, Pandas 1.1.5, Sklearn.
BibTeX Citation
If you use our paper in a scientific publication, we would appreciate using the following citations:
@article{Khaled2021,
author = {Khaled, Alkilane and Elsir, Alfateh M Tag and Shen, Yanming},
doi = {10.1007/s00521-021-06560-z},
issn = {1433-3058},
journal = {Neural Computing and Applications},
title = {{GSTA: gated spatial–temporal attention approach for travel time prediction}},
url = {https://doi.org/10.1007/s00521-021-06560-z},
year = {2021}
}
Owner
- Name: KhaledAlkilane
- Login: KhaledAlkilane89
- Kind: user
- Location: Hangzhou, China
- Company: Zhejiang University–University of Illinois Urbana-Champaign (ZJU-UIUC)
- Repositories: 1
- Profile: https://github.com/KhaledAlkilane89
Postdoctoral Research Fellow
Citation (CITATION.cff)
cff-version: 1.2.0
message: "If you use this paper, please cite it as below."
authors:
- family-names: "Alkilane"
given-names: "Khaled"
- family-names: "Elsir"
given-names: "Alfateh M Tag"
- family-names: "Yanming"
given-names: "Shen"
title: "GSTA: gated spatial–temporal attention approach for travel time prediction"
doi: 10.1007/s00521-021-06560-z
date-released: 2021-9-27
year: 2021
url: "https://doi.org/10.1007/s00521-021-06560-z"
preferred-citation:
type: article
authors:
- family-names: "Alkilane"
given-names: "Khaled"
- family-names: "Elsir"
given-names: "Alfateh M Tag"
- family-names: "Yanming"
given-names: "Shen"
doi: "10.1007/s00521-021-06560-z"
journal: "Neural Computing and Applications"
title: "GSTA: gated spatial–temporal attention approach for travel time prediction"
year: 2021
url: "https://doi.org/10.1007/s00521-021-06560-z"
issn: "1433-3058"