Computer Engineering and Applications ›› 2019, Vol. 55 ›› Issue (6): 13-23.DOI: 10.3778/j.issn.1002-8331.1812-0010

Previous Articles     Next Articles

Attention-YOLO:YOLO Detection Algorithm That Introduces Attention Mechanism

XU Chengji, WANG Xiaofeng, YANG Yadong   

  1. College of Information Engineering, Shanghai Maritime University, Shanghai 201306, China
  • Online:2019-03-15 Published:2019-03-14



  1. 上海海事大学 信息工程学院,上海 201306

Abstract: YOLOv3 is a real-time object detection algorithm, its speed and accuracy reach good trade-off, but the disadvantages are that the boundary box positioning is inaccurate and it is difficult to distinguish overlapping objects. For the above problems, this paper proposes the Attention-YOLO algorithm based on the item-wise attention mechanism which embeds channel and spatial attention mechanism in the feature extraction network, uses the filtered weighted feature vector to replace the original residual fusion, and adds a second-order item to reduce the information loss in the process of fusion and accelerate the convergence of the model. Based on the experiments on COCO and PASCAL VOC datasets, the results show that the Attention-YOLO algorithm effectively reduces the boundary box positioning loss and improves the detection accuracy. Compared with YOLOv3, the Attention-YOLO improves at most 2.5 mAP@IoU[0.5∶0.95] on COCO dataset, and reaches 81.9 mAP on PASCAL VOC 2007 test.

Key words: object detection, YOLOv3 algorithm, Attention-YOLO algorithm, channel attention, spatial attention

摘要: 实时目标检测算法YOLOv3的检测速度较快且精度良好,但存在边界框定位不够精确、难以区分重叠物体等不足。提出了Attention-YOLO算法,该算法借鉴了基于项的注意力机制,将通道注意力及空间注意力机制加入特征提取网络之中,使用经过筛选加权的特征向量来替换原有的特征向量进行残差融合,同时添加二阶项来减少融合过程中的信息损失并加速模型收敛。通过在COCO和PASCAL VOC数据集上的实验表明,该算法有效降低了边界框的定位误差并提升了检测精度。相比YOLOv3算法在COCO测试集上的mAP@IoU[0.5:0.95]提升了最高2.5 mAP,在PASCAL VOC 2007测试集上达到了最高81.9 mAP。

关键词: 目标检测, YOLOv3算法, Attention-YOLO算法, 通道注意力机制, 空间注意力机制