Skip to content

Elliebababa/Multi-Attention-Spatiotemporal-Network-for-mobile-traffic-prediction

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Multi-Attention-Spatiotemporal-Network-for-mobile-traffic-prediction

Implementing Multi-level attention spatio-temporal network for mobile traffic prediction using Keras.

Download the data

Mobile traffic data is released by Telecom Italia and the data can be acquired here.

You can download the first 7 days of November as demo for testing the code.

Cleaning data and making data set

data preprocesing and generating h5 File
  • run : src> python datapreprocessing.py ../data/raw ../data/processed
making dataset
  • to calculate series distance, run: src> python calSeriesDis.py

    notice that series distance is calculated based on weekly average traffic series, so if using only 7 days as demo for testing, the whole demo data will be used to calculate series distance

  • to generate weight matrix, run: src>python genweight.py

  • to train and test data set for the model, run : src >python makedataset.py

    test_len is specified in this py file

MASTNN Model

Framework

image

Train and evaluate model
  • src> python train.py

    model type is specified by the parameter modelbase

  • baseline model STN(spatio-temporal network that incoporating 3Dconv and convlstm for forecasting)$[3]$

    • make dataset: src > python stn_makedataset.py
    • train and evaluate: src > python stn_model_train.py
  • baseline mode ARIMA:

    • run: src > python arima_train_evaluate.py

Reference

About

Implementing Multi-level attention netowrk for spatio-temporal prediction

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published