Learning Discriminative Features for Crowd Counting
Yuehai Chen, Qingzhong Wang, Jing Yang, Badong Chen, Haoyi Xiong, Shaoyi Du
TL;DR
The paper tackles inaccuracies in crowd counting under high density caused by weak localization and foreground-background confusion. It introduces LDFNet, combining a Masked Feature Prediction Module (MPM) for context-aware feature reconstruction and a Supervised Pixel-level Contrastive Learning Module (CLM) to separate foreground heads from the background in feature space; both modules are lightweight and plug-and-play, with CLM disabled at inference. Empirical results across multiple datasets show consistent improvements when LDFNet is integrated with diverse baselines, particularly in dense scenes, and ablations confirm that both modules contribute to localization and discriminability with minimal overhead. The work demonstrates practical impact by enhancing localization and counting accuracy while remaining compatible with detection models, suggesting broad applicability in cluttered visual environments.
Abstract
Crowd counting models in highly congested areas confront two main challenges: weak localization ability and difficulty in differentiating between foreground and background, leading to inaccurate estimations. The reason is that objects in highly congested areas are normally small and high level features extracted by convolutional neural networks are less discriminative to represent small objects. To address these problems, we propose a learning discriminative features framework for crowd counting, which is composed of a masked feature prediction module (MPM) and a supervised pixel-level contrastive learning module (CLM). The MPM randomly masks feature vectors in the feature map and then reconstructs them, allowing the model to learn about what is present in the masked regions and improving the model's ability to localize objects in high density regions. The CLM pulls targets close to each other and pushes them far away from background in the feature space, enabling the model to discriminate foreground objects from background. Additionally, the proposed modules can be beneficial in various computer vision tasks, such as crowd counting and object detection, where dense scenes or cluttered environments pose challenges to accurate localization. The proposed two modules are plug-and-play, incorporating the proposed modules into existing models can potentially boost their performance in these scenarios.
