NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

DiffSTG: Probabilistic Spatio-Temporal Graph Forecasting with Denoising Diffusion Models

Haomin Wen, Youfang Lin, Yutong Xia, Huaiyu Wan, Qingsong Wen, Roger Zimmermann, Yuxuan Liang

TL;DR

DiffSTG is the first framework to adapt Denoising Diffusion Probabilistic Models (DDPMs) to spatio-temporal graph (STG) forecasting. By combining a non-autoregressive diffusion architecture with a novel denoising network called UGnet, it captures complex spatial-temporal dependencies while accurately quantifying prediction uncertainty, outperforming existing probabilistic methods by up to 14%.

What Problem Does This Paper Address?

Spatio-temporal graph (STG) forecasting is essential for real-world applications like traffic management, taxi demand estimation, and air quality monitoring. While modern Spatio-Temporal Graph Neural Networks (STGNNs) excel at making point predictions, they are almost entirely deterministic. They fail to account for intrinsic data uncertainties—such as sudden traffic spikes or weather shifts—which limits their utility in high-stakes decision-making.

Conversely, existing probabilistic time-series models (like TimeGrad or CSDI) fall short when applied to graphs. They typically model temporal trends within isolated nodes, completely ignoring the spatial correlations across the network (e.g., how traffic congestion on one highway affects adjacent roads). Furthermore, many of these models rely on slow, autoregressive (step-by-step) generation, making long-term forecasting computationally expensive.

Methods

The authors introduce DiffSTG, a novel framework that brings the power of score-based diffusion models to graph structured spatio-temporal data.

Figure 1: Illustration of probabilistic STG forecasting. (a): Spatio-temporal graph forecasting; (b): Motivation of proba- bilistic prediction.

Key components of the methodology include:

  • Generalized Conditional Diffusion: Instead of treating historical data purely as an external condition, DiffSTG unifies history and future horizons into a single tensor ($x_{\text{all}}$). The historical steps are masked out during training, allowing the model to learn a joint distribution that unifies prediction, generation, and interpolation.
  • Non-Autoregressive Generation: Rather than predicting the future step-by-step, DiffSTG generates the entire multi-horizon forecast simultaneously in a single reverse diffusion process.
  • UGnet Denoising Network: Standard diffusion models use U-Nets (for images) or WaveNets (for audio). DiffSTG introduces UGnet, which applies a U-Net structure across the temporal dimension to capture multi-scale time dependencies (e.g., 15-minute vs. 1-hour trends) and integrates Graph Convolutional Networks (GCNs) to model spatial relationships.
  • Sampling Acceleration: To bypass the high computational cost of standard DDPMs, the authors implement an accelerated sampling strategy that skips diffusion steps and reuses intermediate outputs, drastically reducing the required iterations.
The architecture of DiffSTG and its core denoising network, UGnet, which combines temporal U-structures with spatial graph convolutions.

Datasets

The model was evaluated on three real-world benchmarks:

  1. PEMS08: A traffic flow dataset from California sensors containing 170 nodes sampled at 5-minute intervals.
  2. AIR-BJ: Air quality ($\text{PM}_{2.5}$) data from 34 monitoring stations in Beijing, sampled hourly.
  3. AIR-GZ: Air quality ($\text{PM}_{2.5}$) data from 41 monitoring stations in Guangzhou, sampled hourly.

Key Insights and Ideas

  • Flipping the U-Net Dimension: In computer vision, U-Nets aggregate features spatially. UGnet cleverly flips this paradigm by applying the U-structure to the temporal dimension to capture multi-granularity history, while relying on GCNs to handle the non-Euclidean spatial graph structure.
  • The Power of Masking: Treating the forecasting problem as a masked data-reconstruction task allows the network to better utilize historical context to model the true underlying data distribution.
  • Overcoming the Speed Bottleneck: Diffusion models are notoriously slow due to iterative sampling. DiffSTG proves that a non-autoregressive approach can predict long horizons all at once on graphs without sacrificing probabilistic accuracy.

Key Results

  • State-of-the-Art Probabilistic Accuracy: DiffSTG consistently outperformed top probabilistic baselines (including Latent ODE, DeepAR, TimeGrad, and CSDI). It reduced the Continuous Ranked Probability Score (CRPS)—the primary metric for probabilistic accuracy—by 5.6% on AIR-BJ, 4.3% on AIR-GZ, and 14.3% on PEMS08.
  • Massive Speedups: Compared to the autoregressive TimeGrad model, DiffSTG achieved up to a 40× speedup in inference time (e.g., taking just 0.24 seconds per prediction vs. TimeGrad's 9.58 seconds on the AIR-GZ dataset).
  • Ablation Validation: Removing either the spatial GCN component or the temporal TCN component caused severe performance degradation, confirming that joint spatio-temporal modeling is vital for accurate denoising.

Limitations and Future Work

Despite its superior probabilistic performance, DiffSTG still exhibits a slight performance gap when evaluated purely on deterministic point forecasting (derived by averaging its generated samples) compared to specialized, state-of-the-art deterministic STGNNs (like GMSDR). The authors note that the variational inference objective can occasionally yield slightly inaccurate posteriors when training data is insufficient.

Future work includes replacing the vanilla GCN layers in UGnet with more advanced graph neural architectures and extending the DiffSTG framework to spatio-temporal graph data imputation (filling in missing sensor values).

Summary updated

BibTeX
@inproceedings{wen2023diffstg,
  author = {Haomin Wen and Youfang Lin and Yutong Xia and Huaiyu Wan and Qingsong Wen and Roger Zimmermann and Yuxuan Liang},
  title = {{DiffSTG: Probabilistic Spatio-Temporal Graph Forecasting with Denoising Diffusion Models}},
  booktitle = {SIGSPATIAL/GIS},
  year = {2023},
  doi = {10.1145/3589132.3625614},
}
Figure