Papers
Topics
Authors
Recent
Search
2000 character limit reached

STDDN: A Physics-Guided Deep Learning Framework for Crowd Simulation

Published 3 Apr 2026 in cs.LG | (2604.02756v1)

Abstract: Accurate crowd simulation is crucial for public safety management, emergency evacuation planning, and intelligent transportation systems. However, existing methods, which typically model crowds as a collection of independent individual trajectories, are limited in their ability to capture macroscopic physical laws. This microscopic approach often leads to error accumulation and compromises simulation stability. Furthermore, deep learning-driven methods tend to suffer from low inference efficiency and high computational overhead, making them impractical for large-scale, efficient simulations. To address these challenges, we propose the Spatio-Temporal Decoupled Differential Equation Network (STDDN), a novel framework that guides microscopic trajectory prediction with macroscopic physics. We innovatively introduce the continuity equation from fluid dynamics as a strong physical constraint. A Neural Ordinary Differential Equation (Neural ODE) is employed to model the macroscopic density evolution driven by individual movements, thereby physically regularizing the microscopic trajectory prediction model. We design a density-velocity coupled dynamic graph learning module to formulate the derivative of the density field within the Neural ODE, effectively mitigating error accumulation. We also propose a differentiable density mapping module to eliminate discontinuous gradients caused by discretization and introduce a cross-grid detection module to accurately model the impact of individual cross-grid movements on local density changes. The proposed STDDN method has demonstrated significantly superior simulation performance compared to state-of-the-art methods on long-term tasks across four real-world datasets, as well as a major reduction in inference latency.

Summary

  • The paper introduces a novel framework that integrates microscopic deep learning and macroscopic physical constraints via Neural ODEs and dynamic graph modules.
  • It employs the continuity equation for mass conservation, reducing error accumulation and achieving significant improvements on multiple benchmarks.
  • Empirical results demonstrate reduced inference times and enhanced trajectory accuracy, making STDDN ideal for real-time crowd management and evacuation planning.

Authoritative Summary of "STDDN: A Physics-Guided Deep Learning Framework for Crowd Simulation" (2604.02756)

Introduction and Motivation

Crowd simulation is indispensable for public safety, evacuation planning, and intelligent transportation systems. Traditional simulation paradigms—physics-based, data-driven, and physics-guided deep learning—each demonstrate inherent limitations. Physics-based models (e.g., Social Force Model, cellular automata) possess interpretability but fail under complex, nonlinear, or high-density conditions. Pure deep learning approaches (RNNs, GNNs, diffusion models) achieve expressive modeling but lack physical consistency, resulting in unrealistic behaviors, such as overlap or physically implausible congestion. Recent physics-guided designs typically focus on the microscopic level, neglect macroscopic constraints, and suffer from error accumulation in iterative simulation. The STDDN framework directly addresses these deficiencies by embedding macroscopic physical laws into deep learning architectures, enforcing global constraints for improved fidelity, stability, and efficiency.

Model Architecture

STDDN comprises three major modules: a microscopic trajectory prediction network, a Neural ODE-based macroscopic density evolution component, and a density-velocity coupled dynamic graph (DVCG) module. The DVCG incorporates a Differentiable Density Mapping (DDM), Continuous Grid Detection (CGD), and Node Embedding (NE), together forming a dynamic GNN that models spatial-temporal density flux induced by pedestrian movement. The topological structure is explicitly linked to velocity transitions, enabling principled modeling of mass conservation and collective transport phenomena. Figure 1

Figure 1: Overview of the STDDN framework, illustrating the macro-micro coupling facilitated by trajectory prediction, Neural ODEs for density evolution, and DVCG for flux computation.

Key innovations include adopting the continuity equation from fluid dynamics as an explicit constraint on microscopic predictions, mapping pedestrian trajectories onto a discretized spatial grid with radial basis soft assignments for gradient continuity, and quantifying cross-grid flux with Jensen-Shannon divergence. Node embeddings are constructed via outer products in low-dimensional latent space, reducing computational complexity from O(N2)O(N^2) to O(Nd)O(Nd) per grid node.

Physically Constrained Coupled Dynamics

The continuity equation is used to enforce mass conservation:

ρt+(ρv)=0\frac{\partial \rho}{\partial t} + \nabla \cdot(\rho \mathbf{v}) = 0

The neural ODE, driven by predictions from the microscopic trajectory network, evolves the density field according to a flux function constructed by DVCG:

ρdt=Gin(Φ,t,ρt)Gout(Φ,t,ρt)\frac{\partial\rho}{dt}= \mathbf{G}_{in}(\Phi, t, \rho^{t}) - \mathbf{G}_{out}(\Phi, t, \rho^{t})

Inflow and outflow are computed from predicted velocities and densities, with cross-grid masks determined by differentiable probabilistic assignments and the cross-grid detection module, maintaining continuous gradients for end-to-end optimization.

Microscopic Trajectory Modeling

The microscopic trajectory prediction component mirrors that of SPDiff, using Equivariant Graph Convolution Layers (EGCL) for message passing and position, velocity, and acceleration update. Current and future velocity vectors define temporal graph edges, enabling explicit modeling of density transport. Figure 2

Figure 2: Detailed architecture of the next trajectory prediction model, with EGCL for spatiotemporal message passing.

The joint training objective supervises both velocity and density predictions:

ljoint=λ1vvθ+λ2ρρθl_{joint} = \lambda_1 \| \mathbf{v} - \mathbf{v}_\theta \| + \lambda_2 \| \rho - \rho_\theta \|

Parameters λ1\lambda_1 and λ2\lambda_2 control the balance between trajectory accuracy and density evolution consistency.

Experimental Validation

STDDN was evaluated on GC, UCY, ETH, and HOTEL datasets. Across all benchmarks, STDDN consistently outperformed competitive baselines—SFM, CA, STGCNN, PECNet, MID (diffusion-based), PCS, NSP, SPDiff—in both trajectory accuracy (MAE, OT) and inference speed.

  • GC: 50% inference time reduction, MAE/OT improvements of 2.6%/2.46%
  • UCY: 90% inference time reduction, MAE/OT improvements of 5.39%/10.01%
  • ETH: 50% inference time reduction, accuracy gains of 6.0%/19.81%
  • HOTEL: 75% inference time reduction, MAE/OT improvements of 12.66%/12.21%

Error accumulation analyses revealed that STDDN demonstrated the lowest long-term prediction error, confirming its effectiveness against drift phenomena. Figure 3

Figure 3

Figure 3: Accumulated simulation error (MAE, OT) over time, demonstrating robustness of STDDN against error propagation.

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4

Figure 4: Visualization of predicted trajectories across GC, UCY, ETH, HOTEL datasets: STDDN maintains high fidelity and avoids overlap with obstacles.

Macroscopic density prediction also showed substantial improvement over SPDiff and PCS. Figure 5

Figure 5: Accumulated density prediction error comparison on GC dataset, showing STDDN's superior density tracking.

Figure 6

Figure 6: Accumulated density prediction error comparison on UCY dataset.

Ablation and Sensitivity Analyses

Ablation studies established the necessity of both the neural ODE constraint and the CGD module. Removing these components resulted in marked degradation in MAE and OT, verifying the importance of explicit macroscopic constraints and accurate flux modeling. Node embeddings and trajectory-driven graph construction surpassed static attention mechanisms for spatial interaction. Higher-order ODE solvers (Dopri5, RK4) did not yield improvements over the Euler method, due to their alignment mismatch with discrete frame sampling.

Sensitivity analyses on grid size, ODE steps, loss coefficients, and embedding dimensions demonstrated that an optimal trade-off between physical and data-driven constraints yielded maximal predictive accuracy. Figure 7

Figure 7: Sensitivity analysis on UCY dataset, elucidating effects of grid size, ODE steps, loss balance, and embedding dimension.

Figure 8

Figure 8: Sensitivity analysis on ETH dataset.

Figure 9

Figure 9: Sensitivity analysis on HOTEL dataset.

Practical and Theoretical Implications

The STDDN framework delivers efficient, physically consistent crowd simulation, robust to error accumulation, and scalable to large-scale, long-duration scenarios. By systematically integrating the continuity equation as a differentiable constraint, STDDN realizes macro-micro coupling in predictive models, enabling interpretable simulation with guarantees on density and mass conservation. The significant reduction in inference latency and parameter count supports deployment in real-time, high-throughput settings.

Theoretical implications include the validation of integrating macroscopic conservation laws into deep learning architectures for spatiotemporal forecasting. The modular design offers extensibility to other domains where mass or energy conservation is essential, such as traffic flow, air quality prediction, or collective biological dynamics.

Future directions involve adaptive constraint weighting, implicit spatial representations, multi-scale graph architectures, and boundary-aware extensions with explicit source/sink terms in the continuity equation to accommodate open environment dynamics.

Conclusion

STDDN establishes a new paradigm for physics-guided deep learning in crowd simulation. By leveraging the continuity equation for macroscopic constraint, coupled with dynamic graph networks and differentiable mapping, it achieves high-precision, efficient, and interpretable simulations. Empirical results confirm superiority over mainstream approaches in both accuracy and efficiency, indicating strong potential for deployment in operational crowd management, evacuation analytics, and intelligent infrastructure systems. The principled integration of physical laws with neural architectures marks a substantial step toward physically plausible, scalable predictive modeling in complex multi-agent domains.

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We found no open problems mentioned in this paper.

Collections

Sign up for free to add this paper to one or more collections.