Temporal Graph ODEs for Irregularly-Sampled Time Series

Alessio Gravina, Daniele Zambon

Abstract

We present Temporal Graph Ordinary Differential Equations (TG-ODE), a novel framework for modeling the evolution of graph-structured data as a continuous-time dynamical system. Traditional Deep Graph Networks (DGNs) often rely on discrete "snapshots," which struggle with the irregular and sparse observations common in real-world social, physical, and traffic systems. By defining node state changes through message-passing ODEs, TG-ODE learns underlying latent dynamics rather than simple state-to-state mappings. Our results on heat diffusion and large-scale traffic datasets demonstrate that TG-ODE significantly outperforms state-of-the-art discrete models in accuracy and computational efficiency, while exhibiting remarkable robustness to data sparsity.

Introduction

Most modern graph learning models operate under a "snapshot" assumption, expecting data to arrive in neat, regularly spaced intervals. However, real-world phenomena—such as social network interactions, sensor readings, and traffic patterns—are characterized by continuous dynamics but sporadic, irregular observations. When faced with these irregular time gaps, standard models often resort to interpolation or treat gaps as uniform, leading to poor predictions and a failure to capture the system's true physics. We address this by moving from discrete-time sequences to continuous-time modeling via the TG-ODE framework.

Methods

The core innovation of the TG-ODE framework is the shift from learning a mapping between discrete states to learning the derivative of node states.

  1. Continuous Dynamics: TG-ODE defines the change in a node's state ($dx_u/dt$) as a function of its current state, exogenous variables, and a message-passing aggregation from its neighbors.
  2. Message-Passing ODEs: By adapting the standard message-passing paradigm into a differential equation, the model can "evolve" node embeddings over any arbitrary time duration.
  3. Numerical Integration: To predict future states, the model integrates the learned ODE from the last known observation to the target time using numerical solvers like the forward Euler method.
Conceptual comparison between standard ODE modeling and the TG-ODE framework for continuous-time graph dynamics.

A significant advantage of this approach is its generality; many existing state-of-the-art DGNs can be reinterpreted as specific, discretized instances of a TG-ODE.

Experimental Evaluation

The authors evaluated TG-ODE on both synthetic and real-world benchmarks:

  • Heat Diffusion: A synthetic task simulating heat spreading across a grid graph to test the model's ability to capture physical laws.
  • Traffic Forecasting: Six real-world datasets (MetrLA, Montevideo, PeMS03, PeMS04, PeMS07, and PeMS08) were intentionally subsampled to create irregular time series, using as little as 3% of the original data in some tests.

Key Results

TG-ODE demonstrates substantial improvements over traditional temporal DGNs across several metrics:

  • Superior Accuracy: In heat diffusion tasks, TG-ODE achieved a $log_{10}(MAE)$ score 308% to 628% better than competitors. On traffic benchmarks, it outperformed the runner-up by up to 202%.
  • Computational Efficiency: The framework was found to be 2x to 13x faster per training epoch than other temporal DGNs, largely due to its simpler architecture compared to complex RNN-based models.
  • Robustness to Sparsity: As shown in the performance analysis, TG-ODE maintains high accuracy even when the number of samples is drastically reduced. It remains effective with only 3-7% of the original data, a regime where other models' performance degrades significantly.
Performance comparison (Test MAE) vs. number of training samples, highlighting TG-ODE's robustness to data sparsity.

Conclusion

TG-ODE represents a significant step forward in temporal graph modeling by treating time as a continuous variable. By focusing on latent dynamics rather than discrete mappings, it provides a more robust and efficient solution for real-world data characterized by irregular sampling. Future work will explore more sophisticated adaptive numerical solvers and the application of TG-ODE to missing data reconstruction.

Summary updated

BibTeX
@inproceedings{gravina2024temporal,
  author = {Alessio Gravina and Daniele Zambon},
  title = {{Temporal Graph ODEs for Irregularly-Sampled Time Series}},
  booktitle = {International Joint Conference on Artificial Intelligence},
  year = {2024},
  url = {https://openreview.net/forum?id=bD0eoYeUzS},
}
Figure