Abstract
Crowd counting in dense scenes is a challenging task due to extreme scale variations and heavy occlusions. Traditional multi-column networks address these issues but often at the cost of high parameter counts and training complexity. We present the Scale Aggregation Network (SANet), a lightweight encoder-decoder architecture that employs an Inception-style scale aggregation module to capture multi-scale features efficiently. By combining a standard Euclidean loss with a Structural Similarity Index (SSIM) loss, SANet produces high-quality density maps that respect local spatial correlations. Experimental results demonstrate that SANet achieves state-of-the-art accuracy on major benchmarks while utilizing significantly fewer parameters (0.91M) than previous models.
Introduction
Crowd counting is a deceptively simple task that is incredibly difficult for computer vision systems. The primary challenges include heavy occlusions, background clutter, and extreme scale variation—where a person near the camera may occupy hundreds of pixels while someone in the distance is represented by only a few.
Existing solutions often rely on "multi-column" networks that run several sub-networks with different filter sizes in parallel. However, these architectures are often inefficient, difficult to train, and limited by a fixed number of scales. Furthermore, most models rely solely on Euclidean loss (pixel-wise difference), which treats every pixel as independent and often results in "blurry" density maps that ignore the local spatial correlation between people.
The SANet Architecture
SANet is designed as an end-to-end encoder-decoder pipeline to generate high-resolution density maps from input images.
Feature Map Encoder (FME)
Instead of using fixed columns, SANet utilizes Scale Aggregation Modules. Inspired by the Inception architecture, each module contains four parallel branches with different filter sizes ($1\times1, 3\times3, 5\times5, 7\times7$). This allows the network to adaptively choose the best scale for different parts of the image. By stacking four of these modules, the network can represent a vast range of person sizes with high efficiency.
Density Map Estimator (DME)
The DME acts as the decoder, using a series of transposed convolutions (deconvolutions) to upscale the features back to the original image resolution. This ensures the output density map is high-resolution and detailed, providing precise localization of individuals within the crowd.
Hybrid Loss Function and Training
To address the "blurry map" problem common in crowd counting, the authors introduced a Local Pattern Consistency Loss based on the Structural Similarity Index (SSIM). While the standard Euclidean loss ensures the total count is roughly correct, the SSIM loss forces the network to respect the local structure and patterns of the crowd. This leads to much cleaner and more accurate density estimations by capturing local spatial correlations.
To prevent gradients from vanishing during training, Instance Normalization (IN) was employed. The authors identified a "statistic shift" problem where models trained on small patches performed poorly on full images; they resolved this by implementing a consistent patch-based testing scheme.
Experimental Results
SANet was evaluated on four major benchmarks: ShanghaiTech (Part A & B), UCF_CC_50, WorldExpo’10, and UCSD.
Performance and Efficiency
SANet achieved top-tier results across the board while remaining incredibly lightweight:
- Accuracy: On the ShanghaiTech Part A dataset, SANet achieved a Mean Absolute Error (MAE) of 67.0, outperforming popular models like CSRNet (68.2) and MCNN (110.2).
- Robustness: On the dense UCF_CC_50 dataset, it achieved an MAE of 258.4, a significant lead over previous methods.
- Efficiency: This is the standout metric. SANet has only 0.91 million parameters. For comparison, CP-CNN has 68.4 million and CSRNet has 16.26 million. This makes SANet highly suitable for real-time applications or deployment on edge devices.
Conclusion
SANet demonstrates that massive model size is not a prerequisite for state-of-the-art performance in crowd counting. By aggregating scales within a single module and utilizing a structure-aware loss function, the network achieves high precision and efficiency. Future work may explore normalization techniques that are more scale-invariant to further improve the model's flexibility across different input dimensions.
Summary updated