摘要
针对行人检测任务中出现拥挤和目标尺寸小所导致的行人检测精度低和效果不佳问题,提出一种基于改进YOLOv5的检测算法.首先,将多头自注意力机制嵌入YOLOv5骨干网络末端,加强了网络对目标行人的全局信息感知,进一步增强了对行人目标可视化区域的特征提取.其次,改进了PANet结构,使模型可以获取更细粒度的特征图.最后,采用更适合密集场景的Varifocal Loss损失函数代替Focal Loss损失函数,以提高模型的鲁棒性.实验结果表明,相比于YOLOv5模型,改进后的算法mAP@0.5与mAP0.5∶0.95分别提高到90.2%和63%,并且对小尺度行人以及密集行人都表现出更好的检测效果,同时比其他同类主流算法拥有更高的鲁棒性和准确性.
Aiming at the problems of low pedestrian detection accuracy and poor performance in crowded scenarios and with small target sizes,a detection algorithm based on improved YOLOv5 is proposed.Firstly,a multi-head self-attention mechanism is embedded into the end of the YOLOv5 backbone network to strengthen the global information perception of the target pedestrian,further enhancing feature extraction in the visualized regions of pedestrian targets.Secondly,the PANet structure is improved to enable the model to acquire more fine-grained feature maps.Finally,the Varifocal Loss function,more suitable for dense scenes,is employed to replace the Focal Loss function,aiming to enhance the model's robustness.The experimental results show that compared with the YOLOv5 model,the improved algorithm achieves an increase in mAP@0.5 and mAP0.5∶0.95 to 90.2%and 63%,respectively.Moreover,it demonstrates better detection performance for small-scale and dense pedestrians.Simultaneously,it possesses higher robustness and accuracy than other similar mainstream algorithms.
作者
宋子昂
刘惠临
SONG Ziang;LIU Huilin(College of Computer Science and Engineering,Anhui University of Science and Technology,Huainan Anhui 232001)
出处
《宁夏师范学院学报》
2024年第1期93-101,共9页
Journal of Ningxia Normal University
基金
国家自然科学基金项目(62102003).