Table of Contents
Fetching ...

How Different from the Past? Spatio-Temporal Time Series Forecasting with Self-Supervised Deviation Learning

Haotian Gao, Zheng Dong, Jiawei Yong, Shintaro Fukushima, Kenjiro Taura, Renhe Jiang

TL;DR

This work tackles spatio-temporal forecasting under dynamic deviations between current observations and historical patterns by introducing ST-SSDL, a framework that anchors inputs to historical averages and discretizes latent deviations with learnable prototypes. Two self-supervised objectives, a contrastive loss and a deviation loss, enforce a structured latent space and relative distance consistency between physical and latent representations, integrated within a GCRU-based encoder-decoder and an adaptive adjacency mechanism. The approach yields state-of-the-art results across six benchmark datasets and demonstrates robustness to varying deviation levels through extensive ablations and case studies. The method reduces reliance on labels while enabling adaptive, deviation-aware forecasting with practical implications for traffic management and urban sensing.

Abstract

Spatio-temporal forecasting is essential for real-world applications such as traffic management and urban computing. Although recent methods have shown improved accuracy, they often fail to account for dynamic deviations between current inputs and historical patterns. These deviations contain critical signals that can significantly affect model performance. To fill this gap, we propose ST-SSDL, a Spatio-Temporal time series forecasting framework that incorporates a Self-Supervised Deviation Learning scheme to capture and utilize such deviations. ST-SSDL anchors each input to its historical average and discretizes the latent space using learnable prototypes that represent typical spatio-temporal patterns. Two auxiliary objectives are proposed to refine this structure: a contrastive loss that enhances inter-prototype discriminability and a deviation loss that regularizes the distance consistency between input representations and corresponding prototypes to quantify deviation. Optimized jointly with the forecasting objective, these components guide the model to organize its hidden space and improve generalization across diverse input conditions. Experiments on six benchmark datasets show that ST-SSDL consistently outperforms state-of-the-art baselines across multiple metrics. Visualizations further demonstrate its ability to adaptively respond to varying levels of deviation in complex spatio-temporal scenarios. Our code and datasets are available at https://github.com/Jimmy-7664/ST-SSDL.

How Different from the Past? Spatio-Temporal Time Series Forecasting with Self-Supervised Deviation Learning

TL;DR

This work tackles spatio-temporal forecasting under dynamic deviations between current observations and historical patterns by introducing ST-SSDL, a framework that anchors inputs to historical averages and discretizes latent deviations with learnable prototypes. Two self-supervised objectives, a contrastive loss and a deviation loss, enforce a structured latent space and relative distance consistency between physical and latent representations, integrated within a GCRU-based encoder-decoder and an adaptive adjacency mechanism. The approach yields state-of-the-art results across six benchmark datasets and demonstrates robustness to varying deviation levels through extensive ablations and case studies. The method reduces reliance on labels while enabling adaptive, deviation-aware forecasting with practical implications for traffic management and urban sensing.

Abstract

Spatio-temporal forecasting is essential for real-world applications such as traffic management and urban computing. Although recent methods have shown improved accuracy, they often fail to account for dynamic deviations between current inputs and historical patterns. These deviations contain critical signals that can significantly affect model performance. To fill this gap, we propose ST-SSDL, a Spatio-Temporal time series forecasting framework that incorporates a Self-Supervised Deviation Learning scheme to capture and utilize such deviations. ST-SSDL anchors each input to its historical average and discretizes the latent space using learnable prototypes that represent typical spatio-temporal patterns. Two auxiliary objectives are proposed to refine this structure: a contrastive loss that enhances inter-prototype discriminability and a deviation loss that regularizes the distance consistency between input representations and corresponding prototypes to quantify deviation. Optimized jointly with the forecasting objective, these components guide the model to organize its hidden space and improve generalization across diverse input conditions. Experiments on six benchmark datasets show that ST-SSDL consistently outperforms state-of-the-art baselines across multiple metrics. Visualizations further demonstrate its ability to adaptively respond to varying levels of deviation in complex spatio-temporal scenarios. Our code and datasets are available at https://github.com/Jimmy-7664/ST-SSDL.

Paper Structure

This paper contains 25 sections, 11 equations, 10 figures, 7 tables, 1 algorithm.

Figures (10)

  • Figure 1: (a) Deviations between current and historical states vary with spatio-temporal context. (b) Such deviations in latent space are hard to quantify, so we leverage relative distance consistency: current–history pairs that are close (far) in physical space should remain close (far) in latent space, i.e., $D_1$ > $D_2$$\Rightarrow$$\widetilde{D}_1$ > $\widetilde{D}_2$.
  • Figure 2: The overview of our proposed framework ST-SSDL: Spatio-Temporal Time Series Forecasting with Self-Supervised Deviation Learning.
  • Figure 3: 12 steps average RMSE w.r.t. #prototypes $M$ and dimension $d$.
  • Figure 4: Visualization of predictions and query-prototype association under various deviation levels.
  • Figure 5: Visualization of prototype and query distribution in latent space.
  • ...and 5 more figures