Multi-Scale Spatio-Temporal Attention Networks for Network-Scale Traffic Learning and Forecasting
Abstract
:1. Introduction
- To develop a model that integrates graph convolutional networks (GCNs) with multi-dimensional long short-term memory (MDLSTM) networks for concurrently capturing both spatial and temporal dependencies in very long sequences of graph-structured traffic data.
- To propose and validate the use of multi-scale temporal convolutional layers within the STNE framework, allowing the model to effectively process and learn from extended input sequences that exhibit diverse temporal properties, such as closeness, periodicity, and trends.
- To empirically evaluate the performance of the STNE model on large-scale real-world traffic datasets, demonstrating its superiority over existing state-of-the-art traffic forecasting methods, particularly in terms of accuracy and robustness across varying network scales.
- To establish the versatility of the STNE model by demonstrating its applicability to other domains that involve very long sequences of graph-structured time series data, such as weather forecasting and car-hailing demand–supply analysis.
2. Materials and Methods
2.1. Traffic Forecasting Problem
2.2. Model Architecture
- GC Layer: The GC layer is fundamental for capturing the spatial dependencies within traffic networks. Traffic data, collected from sensors dispersed across a road network, can be naturally represented as a graph where nodes correspond to sensors and edges represent the connections (e.g., roads) between them. The GC layer operates on this graph structure to extract spatial features, enabling the model to aggregate information from neighboring nodes and learn representations that capture the spatial relationships between various locations in the traffic network.
- Multi-Scale TC: To capture temporal dynamics over varying time scales, the MSTAN model employs multi-scale TC. TC are effective for modeling sequential data, as they apply a sliding window of filters across the time axis, allowing the model to learn temporal patterns. The multi-scale nature of TC ensures that the model uses multiple filters with different kernel sizes, enabling it to attend to temporal features at various resolutions—from short-term fluctuations to long-term trends—thereby effectively capturing the diverse temporal characteristics inherent in traffic data.
- MD-LSTM: To enhance the model’s ability to manage complex temporal dependencies, particularly over long sequences, the MSTAN integrates an attention-based MD-LSTM. LSTMs, a type of RNN, are well-suited for sequence data, capable of learning long-term dependencies through a gating mechanism that controls the flow of information. The multi-dimensional aspect allows the LSTM to process data across multiple dimensions (e.g., spatial and temporal), facilitating the capture of interactions between these dimensions. Additionally, an attention mechanism is incorporated to further enhance the model’s ability to focus on the most relevant parts of the input sequence. This mechanism enables the model to weigh different parts of the sequence according to their relevance to the prediction task at hand.
2.3. Spatial Attention with Graph Convolutions
- Laplacian Matrix Calculation.
- Graph Spectral Filtering.
- Chebyshev Polynomials Approximation.
- Graph Convolutional Layer.
2.4. Multi-Scale Temporal Convolutions
- Temporal Convolution Architecture.
- Standard LSTM Unit.
- Attention-based Multi-Dimensional LSTM.
2.5. Objective Function
3. Results
3.1. Dataset Description
3.2. Experimental Settings
3.3. Experiment Results
4. Discussion
4.1. Performance Comparison
4.2. Insights from Visualization
4.3. Impact of Hyperparameters
5. Conclusions
5.1. Potential Application
- Weather Forecasting.
- Short-term application: The STNE model can be adapted for short-term weather forecasting by analyzing sensor data from weather stations. By focusing on fine-grained temporal patterns such as hourly fluctuations in temperature, humidity, and precipitation, the model enhances the accuracy of short-term weather predictions by effectively capturing sudden weather changes.
- Long-term application: For long-term weather forecasting, the STNE model can be applied to analyze seasonal patterns and long-term climate trends. Extensive historical weather data can be processed to predict future conditions over extended periods, providing valuable insights into potential climate change impacts.
- Car-Hailing Supply–Demand Analysis.
- Short-term application: The STNE model can be utilized to predict real-time demand for car-hailing services in various urban areas, leveraging historical booking data and current traffic conditions. Localized patterns such as peak hours and demand surges are focused on, allowing for the optimization of fleet management and improvement of service availability in real-time.
- Long-term application: In long-term supply–demand analysis, the STNE model can be used to forecast trends in car-hailing demand over different seasons or years. This capability aids in strategic resource allocation and long-term fleet management, enabling service providers to optimize operations over extended periods.
5.2. Limitations
5.3. Applicability for Traffic Management
- Optimized Traffic Control.
- Dynamic traffic signal control: Enhanced traffic pattern predictions enable more effective dynamic traffic signal control. By anticipating traffic flow and congestion, traffic signals can be adjusted in real-time to reduce delays and improve traffic flow.
- Adaptive traffic management systems: The STNE model facilitates the development of adaptive traffic management systems capable of responding dynamically to traffic condition changes, thereby optimizing traffic management strategies and mitigating congestion.
- Enhanced Route Planning.
- Real-time route optimization: Accurate traffic forecasts improve real-time route planning, assisting drivers in avoiding congested areas and reducing travel time. This capability benefits navigation systems and GPS services.
- Predictive Travel Time Estimates: Improved traffic condition forecasts offer more reliable travel time estimates, aiding drivers in planning trips and making informed decisions regarding departure times.
- Efficient Public Transportation.
- Transit scheduling: Accurate predictions of traffic conditions and passenger demand enhance the scheduling of public transportation services, leading to reduced wait times, increased service frequency, and optimized resource allocation.
- Demand-responsive transit: The STNE model supports the development of demand-responsive transit systems that adjust routes and schedules based on real-time and forecasted demand, thereby improving public transportation efficiency and effectiveness.
5.4. Future Work
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Conflicts of Interest
References
- Lana, I.; Del Ser, J.; Velez, M.; Vlahogianni, E.I. Road traffic forecasting: Recent advances and new challenges. IEEE Intell. Transp. Syst. Mag. 2018, 10, 93–109. [Google Scholar] [CrossRef]
- Williams, B.M.; Hoel, L.A. Modeling and forecasting vehicular traffic flow as a seasonal ARIMA process: Theoretical basis and empirical results. J. Transp. Eng. 2003, 129, 664–672. [Google Scholar] [CrossRef]
- Thomas, T.; Weijermars, W.; Van Berkum, E. Predictions of urban volumes in single time series. IEEE Trans. Intell. Transp. Syst. 2010, 11, 71–80. [Google Scholar] [CrossRef]
- Guo, J.; Williams, B.M. Real-Time Short-Term Traffic Speed Level Forecasting and Uncertainty Quantification Using Layered Kalman Filters. Transp. Res. Rec. J. Transp. Res. Board 2010, 2175, 28–37. [Google Scholar] [CrossRef]
- Ghosh, B.; Basu, B.; O’Mahony, M. Multivariate short-term traffic flow forecasting using time-series analysis. IEEE Trans. Intell. Transp. Syst. 2009, 10, 246–254. [Google Scholar] [CrossRef]
- Castro-Neto, M.; Jeong, Y.-S.; Jeong, M.-K.; Han, L.D. Online-SVR for short-term traffic flow prediction under typical and atypical traffic conditions. Expert Syst. Appl. 2009, 36, 6164–6173. [Google Scholar] [CrossRef]
- Castillo, E.; Nogal, M.; Menendez, J.M.; Sanchez-Cambronero, S.; Jimenez, P. Stochastic demand dynamic traffic models using generalized beta-Gaussian Bayesian networks. IEEE Trans. Intell. Transp. Syst. 2012, 13, 565–581. [Google Scholar] [CrossRef]
- Atluri, G.; Karpatne, A.; Kumar, V. Spatio-temporal data mining: A survey of problems and methods. ACM Comput. Surv. (CSUR) 2018, 51, 1–41. [Google Scholar] [CrossRef]
- Huang, W.; Song, G.; Hong, H.; Xie, K. Deep architecture for traffic flow prediction: Deep belief networks with multitask learning. IEEE Trans. Intell. Transp. Syst. 2014, 15, 2191–2201. [Google Scholar] [CrossRef]
- Lv, Y.; Duan, Y.; Kang, W.; Li, Z.; Wang, F.-Y. Traffic flow prediction with big data: A deep learning approach. IEEE Trans. Intell. Transp. Syst. 2015, 16, 865–873. [Google Scholar] [CrossRef]
- Yang, H.F.; Dillon, T.S.; Chen, Y.P.P. Optimized structure of the traffic flow forecasting model with a deep learning approach. IEEE Trans. Neural Netw. Learn. Syst. 2017, 28, 2371–2381. [Google Scholar] [CrossRef]
- Ma, X.; Tao, Z.; Wang, Y.; Yu, H.; Wang, Y. Long short-term memory neural network for traffic speed prediction using remote microwave sensor data. Transp. Res. Part C Emerg. Technol. 2015, 54, 187–197. [Google Scholar] [CrossRef]
- Tian, Y.; Pan, L. Predicting short-term traffic flow by long short-term memory recurrent neural network. In Proceedings of the IEEE International Conference on Smart City Socialcom Sustaincom, Chengdu, China, 19–21 December 2015; pp. 153–158. [Google Scholar]
- Yu, R.; Li, Y.; Shahabi, C.; Demiryurek, U.; Liu, Y. Deep learning: A generic approach for extreme condition traffic forecasting. In Proceedings of the 2017 SIAM International Conference on Data Mining, Houston, TX, USA, 27–29 April 2017; pp. 777–785. [Google Scholar]
- Ke, J.; Zheng, H.; Yang, H.; Chen, X. Short-term forecasting of passenger demand under on-demand ride services: A spatio-temporal deep learning approach. Transp. Res. Part C Emerg. Technol. 2017, 85, 591–608. [Google Scholar] [CrossRef]
- Wu, Y.; Tan, H. Short-term traffic flow forecasting with spatial-temporal correlation in a hybrid deep learning framework. arXiv 2016, arXiv:1612.01022. [Google Scholar]
- Ma, X.; Dai, Z.; He, Z.; Ma, J.; Wang, Y.; Wang, Y. Learning traffic as images: A deep convolutional neural network for large-scale transportation network speed prediction. Sensors 2017, 17, 818. [Google Scholar] [CrossRef]
- Zhang, J.; Zheng, Y.; Qi, D. Deep spatio-temporal residual networks for citywide crowd flows prediction. In Proceedings of the Thirty-First AAAI Conference on Artificial Intelligence, San Francisco, CA, USA, 4–9 February 2017. [Google Scholar]
- Zhang, J.; Zheng, Y.; Qi, D.; Li, R.; Yi, X. DNN-based prediction model for spatio-temporal data. In Proceedings of the 24th ACM SIGSPATIAL International Conference on Advances in Geographic Information Systems, Burlingame, CA, USA, 31 October–3 November 2016; p. 92. [Google Scholar]
- Yu, H.; Wu, Z.; Wang, S.; Wang, Y.; Ma, X. Spatiotemporal recurrent convolutional networks for traffic prediction in transportation networks. Sensors 2017, 17, 1501. [Google Scholar] [CrossRef] [PubMed]
- Yao, H.; Wu, F.; Ke, J.; Tang, X.; Jia, Y.; Lu, S.; Gong, P.; Ye, J.; Li, Z. Deep multi-view spatial-temporal network for taxi demand prediction. In Proceedings of the Thirty-Second AAAI Conference on Artificial Intelligence, New Orleans, LA, USA, 2–7 February 2018. [Google Scholar]
- Yao, H.; Liu, Y.; Wei, Y.; Tang, X.; Li, Z. Learning from Multiple Cities: A Meta-Learning Approach for Spatial-Temporal Prediction. arXiv 2019, arXiv:1901.08518. [Google Scholar]
- Yu, B.; Yin, H.; Zhu, Z. Spatio-temporal graph convolutional networks: A deep learning framework for traffic forecasting. arXiv 2017, arXiv:1709.04875. [Google Scholar]
- Li, Y.; Yu, R.; Shahabi, C.; Liu, Y. Diffusion convolutional recurrent neural network: Data-driven traffic forecasting. arXiv 2017, arXiv:1707.01926. [Google Scholar]
- Geng, X.; Li, Y.; Wang, L.; Zhang, L.; Yang, Q.; Ye, J.; Liu, Y. Spatiotemporal multi-graph convolution network for ride-hailing demand forecasting. Proc. AAAI Conf. Artif. Intell. 2019, 33, 3656–3663. [Google Scholar] [CrossRef]
- Yao, H.; Tang, X.; Wei, H.; Zheng, G.; Li, Z. Revisiting spatial-temporal similarity: A deep learning framework for traffic prediction. Proc. AAAI Conf. Artif. Intell. 2019, 33, 5668–5675. [Google Scholar] [CrossRef]
- Ma, C.; Dai, G.; Zhou, J. Short-term traffic flow prediction for urban road sections based on time series analysis and LSTM_BILSTM method. IEEE Trans. Intell. Transp. Syst. 2021, 23, 5615–5624. [Google Scholar] [CrossRef]
- Wang, K.; Ma, C.; Qiao, Y.; Lu, X.; Hao, W.; Dong, S. A hybrid deep learning model with 1DCNN-LSTM-Attention networks for short-term traffic flow prediction. Phys. A Stat. Mech. Its Appl. 2021, 583, 126293. [Google Scholar] [CrossRef]
- Shu, W.; Cai, K.; Xiong, N.N. A short-term traffic flow prediction model based on an improved gate recurrent unit neural network. IEEE Trans. Intell. Transp. Syst. 2021, 23, 16654–16665. [Google Scholar] [CrossRef]
- Berlotti, M.; Di Grande, S.; Cavalieri, S. Proposal of a machine learning approach for traffic flow prediction. Sensors 2024, 24, 2348. [Google Scholar] [CrossRef] [PubMed]
- Rossi, D.; Pascale, A.; Mascolo, A.; Guarnaccia, C. Coupling different road traffic noise models with a multilinear regressive model: A measurements-independent technique for urban road traffic noise prediction. Sensors 2024, 24, 2275. [Google Scholar] [CrossRef]
- Huang, X.; Wang, J.; Lan, Y.; Jiang, C.; Yuan, X. MD-GCN: A multi-scale temporal dual graph convolution network for traffic flow prediction. Sensors 2023, 23, 841. [Google Scholar] [CrossRef]
- Ji, J.; Wang, J.; Huang, C.; Wu, J.; Xu, B.; Wu, Z.; Zhang, J.; Zheng, Y. Spatio-temporal self-supervised learning for traffic flow prediction. Proc. AAAI Conf. Artif. Intell. 2023, 37, 4356–4364. [Google Scholar] [CrossRef]
- Li, M.; Li, M.; Liu, B.; Liu, J.; Liu, Z.; Luo, D. Spatio-temporal traffic flow prediction based on coordinated attention. Sustainability 2022, 14, 7394. [Google Scholar] [CrossRef]
- Cui, Z.; Zhang, J.; Noh, G.; Park, H.J. Mfdgcn: Multi-stage spatio-temporal fusion diffusion graph convolutional network for traffic prediction. Appl. Sci. 2022, 12, 2688. [Google Scholar] [CrossRef]
- Li, W.; Zhan, X.; Liu, X.; Zhang, L.; Pan, Y.; Pan, Z. SASTGCN: A Self-Adaptive Spatio-Temporal Graph Convolutional Network for Traffic Prediction. ISPRS Int. J. Geo-Inf. 2023, 12, 346. [Google Scholar] [CrossRef]
- Ma, H.; Qin, X.; Jia, Y.; Zhou, J. Dynamic Spatio-Temporal Graph Fusion Convolutional Network for Urban Traffic Prediction. Appl. Sci. 2023, 13, 9304. [Google Scholar] [CrossRef]
Model | LOOP-GS | PeMS-LA | ||||
---|---|---|---|---|---|---|
MAE | RMSE | MAPE | MAE | RMSE | MAPE | |
15 min | ||||||
ARIMA | 3.19 | 5.26 | 8.72% | 3.03 | 5.24 | 7.87% |
SVR | 3.09 | 5.27 | 8.01% | 2.96 | 5.28 | 7.52% |
FNN | 3.08 | 5.05 | 8.32% | 2.96 | 5.11 | 7.81% |
LSTM | 3.03 | 5.04 | 7.85% | 2.85 | 5.06 | 7.36% |
GC-LSTM | 2.88 | 4.64 | 7.24% | 2.84 | 4.84 | 7.26% |
STNE | 2.23 | 3.72 | 5.49% | 2.01 | 3.70 | 5.14% |
30 min | ||||||
ARIMA | 3.89 | 6.58 | 11.71% | 4.59 | 7.70 | 12.57% |
SVR | 3.69 | 6.60 | 10.32% | 4.31 | 7.78 | 11.28% |
FNN | 3.73 | 6.24 | 10.97% | 4.33 | 7.35 | 11.97% |
LSTM | 3.65 | 6.24 | 9.93% | 4.16 | 7.36 | 10.91% |
GC-LSTM | 3.43 | 5.75 | 9.05% | 4.14 | 7.02 | 10.87% |
STNE | 2.91 | 4.90 | 7.44% | 3.20 | 5.63 | 8.33% |
60 min | ||||||
ARIMA | 5.07 | 8.44 | 16.72% | 6.85 | 10.55 | 19.83% |
SVR | 4.72 | 8.45 | 14.86% | 6.18 | 10.74 | 17.00% |
FNN | 4.79 | 7.87 | 15.44% | 6.23 | 9.91 | 18.03% |
LSTM | 4.71 | 7.88 | 13.82% | 5.85 | 9.75 | 15.90% |
GC-LSTM | 4.29 | 7.21 | 11.88% | 5.50 | 9.11 | 14.93% |
STNE | 3.88 | 6.64 | 10.68% | 4.46 | 7.60 | 11.83% |
(m, nd, nr) | MAPE (K = 3) | MAPE (K = 4) | MAPE (K = 5) |
---|---|---|---|
(12, 3, 3) | 8.12% | 7.91% | 7.85% |
(18, 3, 3) | 7.93% | 7.74% | 7.76% |
(24, 3, 3) | 8.04% | 7.85% | 7.78% |
(18, 4, 4) | 7.82% | 7.57% | 7.62% |
(18, 6, 4) | 7.79% | 7.67% | 7.61% |
(12, 3, 3) | 8.12% | 7.91% | 7.85% |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2024 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Wu, C.; Ding, H.; Fu, Z.; Sun, N. Multi-Scale Spatio-Temporal Attention Networks for Network-Scale Traffic Learning and Forecasting. Sensors 2024, 24, 5543. https://doi.org/10.3390/s24175543
Wu C, Ding H, Fu Z, Sun N. Multi-Scale Spatio-Temporal Attention Networks for Network-Scale Traffic Learning and Forecasting. Sensors. 2024; 24(17):5543. https://doi.org/10.3390/s24175543
Chicago/Turabian StyleWu, Cong, Hui Ding, Zhongwang Fu, and Ning Sun. 2024. "Multi-Scale Spatio-Temporal Attention Networks for Network-Scale Traffic Learning and Forecasting" Sensors 24, no. 17: 5543. https://doi.org/10.3390/s24175543
APA StyleWu, C., Ding, H., Fu, Z., & Sun, N. (2024). Multi-Scale Spatio-Temporal Attention Networks for Network-Scale Traffic Learning and Forecasting. Sensors, 24(17), 5543. https://doi.org/10.3390/s24175543