摘 要: 为了提升复杂多尺度目标检测任务下的分类及定位准确度,在基准的YOLOv5目标检测算法基础上,设计了四组引入注意力机制模块的改进型YOLOv5网络,并在变电站内复杂多尺度检测场景数据集上进行对比实验。实验结果表明,相较于基准YOLOv5网络,SwinTrans-YOLOv5网络的mAP指标提升达9.0%,但模型运算量高达1,061.6GFLOPS(每秒千兆次浮点运算);CA-YOLOv5网络的mAP指标提升也达到4.1%,模型运算量仅需115.8 GFLOPS。因此,在硬件算力充足的情况下使用SwinTrans-YOLOv5网络可以获得更高的检测精度,但在硬件算力不足的情况下使用CA-YOLOv5网络,则实现了检测精度和速度间较好的平衡。 |
关键词: 注意力机制;YOLOv5网络;目标检测;Transformer;复杂多尺度 |
中图分类号: TP391
文献标识码: A
|
基金项目: 南瑞集团有限公司科技项目(JS2001712). |
|
Research on the Improved YOLOv5 Network with Attention Mechanism |
ZENG Kai, LI Xiang, CHEN Hongjun, WEN Jifeng
|
(NR Electric Co., Ltd., Nanjing 211102, China )
zengkai2@nrec.com; lix@nrec.com; chenhj@nrec.com; wenjf@nrec.com
|
Abstract: In order to improve the classification and positioning accuracy of complex and multi-scale object detection tasks, this paper proposes to design four groups of improved YOLOv5 networks with attention mechanism modules based on the benchmark YOLOv5 objet detection algorithm, and their comparative tests are conducted on multi-scale detection datasets in the substation. Test results show that compared with the benchmark YOLOv5 network, the mAP index of SwinTrans-YOLOv5 network is improved by 9.0%, but the model calculation amount is as high as 1061.6 GFLOPS (Giga Floating-point Operations Per Second); the mAP index of CA-YOLOv5 network is also improved by 4.1%, and only 115.8 GFLOPS is needed. Therefore, using the SwinTrans-YOLOv5 network can achieve higher detection accuracy when the hardware computing power is sufficient, but using the CA-YOLOv5 network when the hardware computing power is insufficient can achieve a good balance between detection accuracy and speed. |
Keywords: attention mechanism; YOLOv5 algorithm; object detection; Transformer; complex and multi-scale |