针对复杂环境下高铁轨道入侵异物对列车的安全行驶有严重的威胁,而现有检测方法不能满足实际的高铁轨道异物检测工作,提出一种基于改进YOLOv7的高铁异物入侵检测算法.引入CARAFE算子作为上采样算法,减少输入图像的特征信息损失,增大网络感受野;在YOLOv7模型中引入GhostConv卷积,可以有效地减少模型的计算量和参数量;引入全局注意力机制(Global Attention Mechanisms,GAM),增强全局信息交互能力和表达能力,提高检测性能;采用Alpha_GIoU损失函数,提升小目标的检测能力和模型的收敛速度.实验结果表明,改进后的YOLOv7-CGGA模型的平均检测精度(mean Average Precision,mAP)和平均每秒推理速度(Frames Per Second,FPS)值分别达到 96.7%和 96.1,与原 YOLOv7模型相比,分别提升了1.6%和31.1,较好地平衡了模型的检测精度和效率,可以满足实际的检测需求.
High-speed Rail Foreign Object Intrusion Detection Algorithm Based on Improved YOLOv7
The intrusion of foreign objects on high-speed rail tracks in complex environments is a serious threat to the safe traveling of trains,and the existing detection methods cannot meet the actual detection of foreign objects on high-speed rail tracks,a high-speed rail foreign object intrusion detection algorithm based on the improved YOLOv7 is proposed.Firstly,the CARAFE operator is introduced as the up-sampling algorithm to reduce the feature information loss of the input image and increase the network receptive field;secondly,the GhostConv convolution is introduced into the YOLOv7 model,which can effectively reduce the computational and parametric quantities of the model;and then the Global Attention Mechanisms(GAM)is introduced to enhance the global information interaction ability and expression ability and improve the detection performance;finally,the Alpha_GIoU loss function is used to improve the detection ability of small targets and the convergence speed of the model.The experimental results show that the mean Average Precision(mAP)and Frames Per Second(FPS)values of the improved YOLOv7-CGGA model reach 96.7%and 96.1,respectively,which are improved by 1.6%and 31.1 compared with the original YOLOv7 model,and better balance the detection accuracy and efficiency of the model and can meet practical detection needs.