电子科技 ›› 2023, Vol. 36 ›› Issue (2): 73-80.doi: 10.16180/j.cnki.issn1007-7820.2023.02.011

• • 上一篇    下一篇

改进YOLO的口罩佩戴实时检测方法

程长文,陈玮,陈劲宏,尹钟   

  1. 上海理工大学 光电信息与计算机工程学院,上海 200093
  • 收稿日期:2021-08-29 出版日期:2023-02-15 发布日期:2023-01-17
  • 作者简介:程长文(1997-),男,硕士研究生。研究方向:图像处理。|陈玮(1964-),女,副教授。研究方向:图像处理与模式识别。|陈劲宏(1996 -),男,硕士研究生。研究方向:图像处理。|尹钟(1988-),男,副教授。研究方向:基于脑电信号的深度学习。
  • 基金资助:
    国家自然科学基金(61703277)

YOLO-Improve Detection Method of Real-Time Mask Wearing

CHENG Changwen,CHEN Wei,CHEN Jinhong,YIN Zhong   

  1. School of Optical-Electrical and Computer Engineering,University of Shanghai for Science and Technology,Shanghai 200093,China
  • Received:2021-08-29 Online:2023-02-15 Published:2023-01-17
  • Supported by:
    National Natural Science Foundation of China(61703277)

摘要:

现有的YOLO目标检测模型基于One-stage思想进行多目标检测,其对于双分类检测有所不足,并且检测时性能消耗较大。为了能够在新冠疫情爆发的特殊时期,提高双分类口罩佩戴的检测精度和检测效率,文中提出了一种基于YOLO的双目标口罩佩戴实时检测方法。改进模型的前馈输入层,优化了数据增强部分,添加了自适应图片缩放,以便提升双分类和小目标的检测精度和检测效率。添加了自适应锚定框,替换了激活函数,降低了方法的计算量从而提高方法的检测效率。Neck部分优化和添加的Focus结构提高了特征融合能力并且减少了参数量,达到了提速的效果。实验结果表明,与YOLOv4相比,所提方法在文中数据集中的F1提高了0.33%,mAp提高了0.71%,并且相同实验环境下的检测效率也提升明显。

关键词: YOLOv4, CSPDenseNet, Focus, 数据增强, 激活函数, CSP2, 目标检测, 口罩佩戴

Abstract:

The existing YOLO target detection model is based on the One-stage idea for multi-target detection. It is insufficient for dual-classification detection, and the performance consumption is large during detection. In order to improve the detection efficiency of dual-classification mask wearing during the period of the outbreak of COVID-19, this study proposes a real-time detection method based on YOLO for detecting the condition of bi-objective mask wearing. The feedforward input layer of the model is improved, the data enhancement part is optimized, and adaptive image scaling is added to improve the detection accuracy and detection efficiency of dual-classification and small targets. The adaptive anchoring frame is added to replace the activation function so as to reduce the computational complexity of the method and improves the detection efficiency of the method. The optimization of Neck and the addition of Focus structure improve the capability of feature fusion and reduce the amount of parameters to raise the efficiency. The experimental results showed that compared with the YOLOv4, the proposed method has a 0.33% increase in F1 and a 0.71% increase in mAp in the data set in the text, and the detection efficiency is also significantly improved under the same experimental environment.

Key words: YOLOv4, CSPDenseNet, Focus, data augmentation, activation function, CSP2, target detection, mask wearing

中图分类号: 

  • TP391