# Online Test-Time Adaptation of Spatial-Temporal Traffic Flow Forecasting

arXiv: https://arxiv.org/abs/2401.04148 · HTML: https://mlsanity.com/paper/2401.04148/

## Key facts

- Cited by 11 papers in the map (data through 14 Oct 2026).
- Builds on 22 of its 55 references that are in the map.
- First posted on arXiv 8 Jan 2024.

## Builds on (most cited first, 22 of 22)

- [Adam: A Method for Stochastic Optimization](https://mlsanity.com/paper/1412.6980/) (2014)
- [Layer Normalization](https://mlsanity.com/paper/1607.06450/) (2016)
- [Gaussian Error Linear Units (GELUs)](https://mlsanity.com/paper/1606.08415/) (2016)
- [Adaptive Graph Convolutional Recurrent Network for Traffic Forecasting](https://mlsanity.com/paper/2007.02842/) (2020)
- [Continual Test-Time Domain Adaptation](https://mlsanity.com/paper/2203.13591/) (2022)
- [Efficient Test-Time Model Adaptation without Forgetting](https://mlsanity.com/paper/2204.02610/) (2022)
- [T-GCN: A Temporal Graph ConvolutionalNetwork for Traffic Prediction](https://mlsanity.com/paper/1811.05320/) (2018)
- [A Comprehensive Survey on Test-Time Adaptation under Distribution Shifts](https://mlsanity.com/paper/2303.15361/) (2023)
- [Graph Neural Network for Traffic Forecasting: A Survey](https://mlsanity.com/paper/2101.11174/) (2021)
- [Test-Time Training with Masked Autoencoders](https://mlsanity.com/paper/2209.07522/) (2022)
- [Parameter-free Online Test-time Adaptation](https://mlsanity.com/paper/2201.05718/) (2022)
- [NOTE: Robust Continual Test-time Adaptation Against Temporal Correlation](https://mlsanity.com/paper/2208.05117/) (2022)
- [CoST: Contrastive Learning of Disentangled Seasonal-Trend Representations for Time Series Forecasting](https://mlsanity.com/paper/2202.01575/) (2022)
- [PDFormer: Propagation Delay-Aware Dynamic Long-Range Transformer for Traffic Flow Prediction](https://mlsanity.com/paper/2301.07945/) (2023)
- [AdaRNN: Adaptive Learning and Forecasting of Time Series](https://mlsanity.com/paper/2108.04443/) (2021)
- [MixNorm: Test-Time Adaptation Through Online Normalization Estimation](https://mlsanity.com/paper/2110.11478/) (2021)
- [Temporal Domain Generalization with Drift-Aware Dynamic Neural Networks](https://mlsanity.com/paper/2205.10664/) (2022)
- [Meta-Learning Fast Weight Language Models](https://mlsanity.com/paper/2212.02475/) (2022)
- [Long-Short Term Spatiotemporal Tensor Prediction for Passenger Flow Profile](https://mlsanity.com/paper/2004.11022/) (2020)
- [Self-Adaptive Forecasting for Improved Deep Learning on Non-Stationary Time-Series](https://mlsanity.com/paper/2202.02403/) (2022)
- [Physics-Informed Deep Learning For Traffic State Estimation: A Survey and the Outlook](https://mlsanity.com/paper/2303.02063/) (2023)
- [Combating Distribution Shift for Accurate Time Series Forecasting via Hypernetworks](https://mlsanity.com/paper/2202.10808/) (2022)

## Built on by (most cited first, 11 of 11)

- [Learning with Calibration: Exploring Test-Time Computing of Spatio-Temporal Forecasting](https://mlsanity.com/paper/2506.00635/) (2025)
- [Learning the Context of Errors: Black-Box Online Adaptation of Time Series Foundation Models](https://mlsanity.com/paper/2606.14222/) (2026)
- [Online time series prediction using feature adjustment](https://mlsanity.com/paper/2509.03810/) (2025)
- [Position: Universal Time Series Foundation Models Rest on a Category Error](https://mlsanity.com/paper/2602.05287/) (2026)
- [Learning to Factorize and Adapt: A Versatile Approach Toward Universal Spatio-Temporal Foundation Models](https://mlsanity.com/paper/2601.12083/) (2026)
- [TEFL: Prediction-Residual-Guided Rolling Forecasting for Multi-Horizon Time Series](https://mlsanity.com/paper/2602.22520/) (2026)
- [Deep Causal Learning to Explain and Quantify The Geo-Tension's Impact on Natural Gas Market](https://mlsanity.com/paper/2407.10878/) (2024)
- [Transformer-based Drum-level Prediction in a Boiler Plant with Delayed Relations among Multivariates](https://mlsanity.com/paper/2407.11180/) (2024)
- [M2OE2-GL: A Family of Probabilistic Load Forecasters That Scales to Massive Customers](https://mlsanity.com/paper/2511.17623/) (2025)
- [Expert-Guided Forecast Editing for Time-Series Foundation Models](https://mlsanity.com/paper/2607.19659/) (2026)
- [Online Test-Time Adaptation for Generalizable Dynamic Graph Anomaly Detection](https://mlsanity.com/paper/2608.19858/) (2026)

## Abstract (arXiv)

Accurate spatial-temporal traffic flow forecasting is crucial in aiding traffic managers in implementing control measures and assisting drivers in selecting optimal travel routes. Traditional deep-learning based methods for traffic flow forecasting typically rely on historical data to train their models, which are then used to make predictions on future data. However, the performance of the trained model usually degrades due to the temporal drift between the historical and future data. To make the model trained on historical data better adapt to future data in a fully online manner, this paper conducts the first study of the online test-time adaptation techniques for spatial-temporal traffic flow forecasting problems. To this end, we propose an Adaptive Double Correction by Series Decomposition (ADCSD) method, which first decomposes the output of the trained model into seasonal and trend-cyclical parts and then corrects them by two separate modules during the testing phase using the latest observed data entry by entry. In the proposed ADCSD method, instead of fine-tuning the whole trained model during the testing phase, a lite network is attached after the trained model, and only the lite network is fine-tuned in the testing process each time a data entry is observed. Moreover, to satisfy that different time series variables may have different levels of temporal drift, two adaptive vectors are adopted to provide different weights for different time series variables. Extensive experiments on four real-world traffic flow forecasting datasets demonstrate the effectiveness of the proposed ADCSD method. The code is available at https://github.com/Pengxin-Guo/ADCSD.
