Author Login Chief Editor Login Reviewer Login Editor Login Remote Office

Computer Engineering

   

An improved dense pedestrian detection algorithm based on YOLOv8-n in complex scenes

  

  • Published:2025-06-05

复杂场景下的改进YOLOv8-n密集行人检测模型

Abstract: Dense pedestrian detection is one of the key problems in the development of crowd flow monitoring system in large public places. Aiming at the difficulty of small target detection caused by crowd occlusion in dense pedestrian detection scenes and the deployment requirement of lightweight model, this paper proposes an improved YOLOv8-n dense pedestrian detection model CAD-YOLO(CGDown-Adaptive Fusion Module-Dyhead). Embedded CGDown subsampling module, through an efficient context information extraction mechanism, effectively alleviates the problem that the traditional target detector is easy to lose context features when dealing with dense scenes, and significantly enhances the ability to capture dense pedestrian features and focus on small targets. A BiFPN-Adaptive structure was designed and the neck network was reconstructed. By adaptive fusion of feature information of different scales, the model was more accurate in extracting features of obscured pedestrians and small and medium-sized target pedestrians, and the number of parameters and calculation cost of the model were greatly reduced. The dynamic detection head Dyhead, combined with the new 160×160 small target detection layer, enables the model to capture the fine features of the dense small target area more accurately, thus effectively alleviating the problem of missing detection in the occlusion scene. The experimental results show that compared with YOLOv8-n, the detection accuracy of CAD-YOLO on Crowd Human dataset and WiderPerson dataset is improved by 5.1% and 2.1%, respectively. Despite the significant performance improvement, CAD-YOLO has a reference count of only 2.9M and a model compute capacity of 12.3GFLOPs, meeting the requirements of low power consumption and high precision when deployed on edge devices or mobile devices.

摘要: 密集行人检测是大型公共场所人流监控系统发展的关键问题之一。针对密集行人检测场景中由于人群遮挡导致的小目标检测困难以及模型轻量化的部署需求,本文提出一种改进的YOLOv8-n密集行人检测模型CAD-YOLO(CGDown-Adaptive Fusion Module-Dyhead)。嵌入了CGDown下采样模块,通过高效的上下文信息提取机制,有效缓解了传统目标检测器在处理密集场景时上下文特征易丢失的问题,显著增强了对密集行人特征的捕获能力以及对小目标的聚焦性能。设计了一种BiFPN-Adaptive结构并重构了颈部网络,通过自适应融合不同尺度的特征信息,使模型在提取被遮挡行人及中小型目标行人特征时表现更加精准,同时大幅减少了模型的参数量与计算成本。引入了动态检测头Dyhead,结合新增的160×160尺度的小目标检测层,使模型能够更加精确地捕获密集小目标区域的细微特征,从而有效缓解遮挡场景中的漏检问题。实验结果显示,相较于YOLOv8-n,CAD-YOLO在Crowd Human数据集上和在WiderPerson数据集上的检测精度分别提升了5.1%和2.1%。尽管性能大幅提升,CAD-YOLO的参数量仅为2.9M,模型计算量为12.3GFLOPs,满足了在边缘设备或移动设备上部署时低功耗、高精度的要求。