Physics-informed neural cellular automata learn traffic flow rules accurately

Learning Traffic Flow Dynamics with Stochastic Physics-Informed Neural Cellular Automata

Machine Learning

Summary

Traffic flow models help predict how cars move on roads and prevent jams. The authors designed a new computer method, called physics-informed neural cellular automata, which learns how cars behave by following rules that match real-world physics and road layouts. This method can also handle randomness in driving behavior while ensuring the total number of cars stays consistent. Tests show their approach learns traffic patterns better than standard methods, capturing both regular and unpredictable driving dynamics.

What this means in practice

  • For traffic management teams: Improve simulation tools that predict traffic jams by integrating learned, physically consistent local traffic behaviors including randomness.
  • For urban infrastructure planners: Enhance accuracy of traffic flow models used in designing road networks by enforcing vehicle conservation and stochastic driving rules.

Authors

Federica Bragone, Matthieu Barreau

Abstract

Traffic flow modeling is essential for understanding and predicting the collective dynamics of vehicles on road networks. Cellular automata provide a simple, interpretable yet powerful framework for representing these dynamics via local interaction rules, while retaining the ability to reproduce complex macroscopic traffic phenomena. However, learning local transition rules from data while preserving physically meaningful constraints remains challenging, particularly for stochastic models. In this work, we propose a physics-informed neural cellular automaton (PI-NCA) for data-driven traffic flow modeling. Building on the standard neural cellular automaton (NCA), we design a neural architecture that is physically consistent with the road topology and guarantees conservation of the total number of vehicles, thereby constraining the learned transition rules to physically admissible dynamics. We further extend this framework to stochastic dynamics by parameterizing probabilistic transition rules while preserving the same physics-informed constraints. We evaluate the proposed models on multiple traffic scenarios generated by the well-established Nagel-Schreckenberg and Kerner-Klenov-Wolf cellular automata. The results demonstrate that the PI-NCA successfully learns the dynamics of both traffic models and consistently outperforms a standard NCA, while the stochastic extension captures probabilistic transition rules without compromising the imposed physical constraints.