Implementing Multi-level attention spatio-temporal network for mobile traffic prediction using Keras.
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.
- run : src> python datapreprocessing.py ../data/raw ../data/processed
-
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
-
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
- 1.Barlacchi G , De Nadai M , Larcher R , et al. A multi-source dataset of urban life in the city of Milan and the Province of Trentino[J]. Scientific Data, 2015, 2:150055.
- 2.Yuxuan Liang, Songyu Ke, Junbo Zhang, Xiuwen Yi, Yu Zheng, "GeoMAN: Multi-level Attention Networks for Geo-sensory Time Series Prediction", IJCAI, 2018.
- 3.Zhang C , Patras P . Long-Term Mobile Traffic Forecasting Using Deep Spatio-Temporal Neural Networks[J]. 2017.