Flowing Crowd to Count Flows: A Self-Supervised Framework for Video Individual Counting

Feng-Kai Huang, Bo-Lun Huang, Li-Wu Tsao, Jhih-Ciang Wu, Hong-Han Shuai, Wen-Huang Cheng

TL;DR

This paper introduces VIC-SSL, a novel self-supervised framework for Video Individual Counting (VIC) that significantly reduces the need for expensive manual annotations. By employing a unique feature-level data augmentation technique called Foreground-driven ShiftMix, VIC-SSL learns to accurately track individuals across video frames without relying on identity-level labels, achieving state-of-the-art performance.

What Problem Does This Paper Address?

Traditional Video Crowd Counting (VCC) focuses on estimating the number of people in individual frames. However, Video Individual Counting (VIC) is a more advanced task that aims to count unique individuals across an entire video sequence, ensuring no one is counted twice. This is crucial for applications like urban planning, event management, and safety monitoring. Current VIC methods often rely on extensive annotations, such as identity-level or group-level labels, which are time-consuming and costly to obtain, especially in dense crowd scenarios. This paper addresses the challenge of reducing these annotation costs while maintaining high accuracy and robustness in VIC.

Methods

VIC-SSL employs a two-stage training approach: self-supervised pre-training and fine-tuning.

  • Foreground-driven ShiftMix (F-ShiftMix): This is the core novelty. Instead of augmenting images, F-ShiftMix operates in the feature space. It synthesizes realistic crowd motion by blending and shifting feature maps. This process is guided by a foreground mask to ensure that foreground elements (moving individuals) are shifted more realistically than background elements. This feature-level augmentation preserves global semantic coherence and avoids the fragmentation issues of image-level methods.
  • Cost-guided Flow Prompt (CFP): This module generates a motion-aware prompt by computing a localized cost volume between the original and synthesized feature maps. This prompt helps the model focus on regions with significant inter-frame motion.
  • Distinction-aware Cross-Attention (DCA): This module uses a modified cross-attention mechanism to learn inter-frame correspondences. It explicitly emphasizes the differences between consecutive frames, which is crucial for distinguishing between new and existing individuals.
  • Self-supervised Pre-training: The F-ShiftMix, CFP, and DCA modules are trained on unlabeled video data. The F-ShiftMix generates a pseudo-reference feature map and a transportation map, which are used as supervision signals for the attention mechanism.
  • Fine-tuning: After pre-training, the model is fine-tuned on a small amount of labeled data. Here, real reference frames are used, and the model predicts inflow and shared crowd densities, which are then used to estimate the total count.

Datasets

The paper evaluates VIC-SSL on three datasets:

  • SenseCrowd: A large-scale dataset with 634 video sequences and over 62,000 frames, featuring diverse scenarios and crowd densities.
  • CroHD: A dataset with densely crowded scenes, containing 11,463 frames across 9 video sequences.
  • CARLA: A synthetic dataset with 10 video sequences, designed to simulate varying weather conditions and camera perspectives.

Key Insights and Ideas

  • Feature-level augmentation is key for realistic motion synthesis: Operating in the feature space with F-ShiftMix allows for more semantically coherent and realistic crowd motion synthesis compared to image-level augmentations, which can easily break visual continuity in dense scenes.
  • Foreground-driven shifting is crucial for mimicking real-world dynamics: Differentiating the shifting of foreground and background elements in the feature map leads to more accurate simulation of pedestrian movement.
  • Self-supervision can drastically reduce annotation burden: By learning robust inter-frame correspondences from unlabeled data, VIC-SSL significantly lowers the need for costly manual annotations, making VIC systems more practical.
  • Explicitly modeling differences between frames aids individual counting: The Distinction-aware Cross-Attention module's focus on frame differences is vital for accurately identifying unique individuals and their movements.

Key Results

  • State-of-the-art performance: VIC-SSL achieves state-of-the-art results on the SenseCrowd dataset, outperforming existing methods by a significant margin (e.g., 14.6% improvement in MSE over CGNet when using pre-training).
  • Improved data efficiency: Even with only 50% of the labeled data, VIC-SSL can outperform state-of-the-art methods in MSE, and with 25% of the data, it matches DRNet's performance.
  • Robustness across datasets: The method demonstrates strong performance on diverse datasets like CroHD and CARLA, including a synthetic dataset with domain gaps, highlighting its adaptability.
  • Significant gains from pre-training: The self-supervised pre-training stage provides substantial improvements across all metrics, validating the effectiveness of F-ShiftMix.
  • Component effectiveness: Ablation studies show that each proposed module (DCA, CFP, and pre-training) contributes significantly to the overall performance.

Limitations and Future Work

  • Fixed radius for cost volume: The paper notes that the fixed radius for the localized cost volume might not be optimal for scenes with highly varying motion scales.
  • Challenges with complex motion: Generating reference frames might encounter difficulties in highly complex or non-linear motion patterns, such as abrupt movements or significant occlusions.
  • Future work: The authors aim to explore the interplay between self-supervised learning and video-specific temporal structures to further enhance model generalization.

Summary updated

BibTeX
@inproceedings{huang2026flowing,
  author = {Feng-Kai Huang and Bo-Lun Huang and Li-Wu Tsao and Jhih-Ciang Wu and Hong-Han Shuai and Wen-Huang Cheng},
  title = {{Flowing Crowd to Count Flows: A Self-Supervised Framework for Video Individual Counting}},
  booktitle = {The 33rd ACM International Conference on Multimedia},
  year = {2026},
  url = {https://openreview.net/forum?id=GdVSp9pkSC},
}
Figure