All models

NeuralForecast StemGNN

A multivariate forecaster that moves series into the spectral domain with graph and discrete Fourier transforms.

Time series · 170 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

Loading diagram (15 KB)

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Parameters
4.2M
Operations
170
Framework
PyTorch
Recurrent
No
Published
NeurIPS 2020
Cited by
388 (as of 18 October 2026)
Authors
Defu Cao, Yujing Wang, Juanyong Duan and others
License
Apache-2.0
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m1923
Graph hash
3d6cf0c11b66036b8f1a072da60b4015628ac4062006b54f076a02e8ea0b1940
Skeleton hash
fd1ade297459ff71f8fb0a898794b73f48d925f65017355a5965d0c3c12e517f
Architecture hash
a0a03b694e8cc7652e20b22bd2171f4f50e50f85c2339df5ad1162e6d984d0e1
Diagram SHA-256
657aded682a9addc7fd1cb4e303f20c5fc13cfed95bb9c5a1e20e539aaf48f8d
TorchLens version
2.36.0
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

What it is

StemGNN, the Spectral Temporal Graph Neural Network, was proposed to further improve the accuracy of multivariate time-series forecasting. The challenge it addresses is that one needs to consider both intra-series temporal correlations and inter-series correlations simultaneously. StemGNN captures inter-series correlations and temporal dependencies jointly in the spectral domain.

It combines a Graph Fourier Transform (GFT), which models inter-series correlations, with a Discrete Fourier Transform (DFT), which models temporal dependencies, in an end-to-end framework. After passing through GFT and DFT, the spectral representations hold clear patterns and can be predicted effectively by convolution and sequential learning modules. Where earlier work resorted to pre-defined priors for inter-series relationships, StemGNN learns inter-series correlations automatically from the data.

The paper reports extensive experiments on ten real-world datasets. The official repository evaluates traffic flow forecasting on PEMS03, PEMS07 and PEMS08 and traffic speed forecasting on PEMS04, PEMS-BAY and METR-LA. Input CSV files to that code carry no header and have shape T by N, where T is the total number of timestamps and N the number of nodes. The member traced here is NeuralForecast's StemGNN, which sits in that library's model list beside its transformer forecasters. In the official code the sliding window defaults to 12 steps and the predict horizon to 3.

Key idea. StemGNN forecasts many series at once by combining a Graph Fourier Transform for inter-series correlations with a Discrete Fourier Transform for temporal dependencies, learned end to end without pre-defined priors.

  • stemgnn
  • spectral temporal graph neural network
  • multivariate time series forecasting
  • graph fourier transform
  • gft
  • discrete fourier transform
  • neuralforecast
  • nixtla
  • traffic forecasting
  • gnn forecasting
  • pems
  • metr-la

AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.

Cite the paper

@misc{cao2021spectraltemporalgraphneural,
      title={Spectral Temporal Graph Neural Network for Multivariate Time-series Forecasting}, 
      author={Defu Cao and Yujing Wang and Juanyong Duan and Ce Zhang and Xia Zhu and Conguri Huang and Yunhai Tong and Bixiong Xu and Jing Bai and Jie Tong and Qi Zhang},
      year={2021},
      eprint={2103.07719},
      archivePrefix={arXiv},
      primaryClass={cs.LG},
      url={https://arxiv.org/abs/2103.07719}, 
}