Introduction
Predicting citywide crowd flow—the movement of people and vehicles into and out of specific urban regions—is a cornerstone of modern urban planning and traffic management. Accurate forecasts enable better resource allocation, congestion mitigation, and enhanced public safety. However, crowd dynamics are notoriously difficult to model due to complex temporal dependencies, periodic daily/weekly cycles, and the influence of external factors like weather and holidays.
Methodology: The ACFM Module
The core contribution of this work is the Attentive Crowd Flow Machine (ACFM). Unlike traditional models that treat all spatial regions with uniform importance, ACFM employs a progressive spatial-temporal modeling approach to adaptively identify influential areas.
Dual ConvLSTM and Attention Mechanism
The ACFM module utilizes two stacked Convolutional Long Short-Term Memory (ConvLSTM) units. The first unit processes raw flow data to generate a hidden state, which is then passed through a convolutional layer to produce a dynamic Attention Map. This map identifies critical spatial regions at each time step. The input data is then weighted by this map before being processed by the second ConvLSTM, allowing the model to focus its representational capacity on the most influential areas.
Sequential-Periodic Network (SPN)
To capture both immediate trends and long-term cycles, the authors propose the Sequential-Periodic Network (SPN). This architecture features two parallel ACFM branches:
- Sequential Branch: Processes recent historical data (e.g., the last few hours) to capture short-term fluctuations.
- Periodic Branch: Processes data from the same time slots on previous days to capture recurring daily patterns.
These branches are fused using a learnable gate influenced by external factors (e.g., weather, holidays), allowing the model to dynamically adjust the relative importance of short-term versus periodic information based on environmental context.
Experimental Evaluation
The model was evaluated on two large-scale real-world datasets representing different urban dynamics:
- TaxiBJ (Beijing): Taxicab GPS trajectories partitioned into a $32 \times 32$ grid.
- BikeNYC (New York City): Bike-sharing data partitioned into a $16 \times 8$ grid.
Results and Discussion
The ACFM-based SPN model demonstrated superior performance over state-of-the-art baselines, including ST-ResNet and DeepST. On the TaxiBJ dataset, the model achieved a Root Mean Square Error (RMSE) of 15.40, representing a 7.7% relative improvement. Similarly, on BikeNYC, the RMSE was reduced to 5.64, outperforming the previous state-of-the-art of 6.33.
Ablation studies confirmed that the attention mechanism is vital; removing it led to a significant increase in error. Furthermore, analysis of the fusion gate revealed that while sequential data is generally more predictive, periodic data becomes dominant during late-night hours when city movement is highly regular and repetitive.
Conclusion
The Attentive Crowd Flow Machine introduces a powerful mechanism for dynamic spatial weighting in urban computing. By "learning where to look," the model provides both higher accuracy and increased interpretability for urban planners. Future work will focus on adapting the architecture to irregular road networks and improving robustness during extreme, non-periodic events.
Summary updated