Research on Improved Mask Detection Method Based on YOLOv5 Algorithm

被引:1
作者
Duan, Bichong [1 ,2 ]
Ma, Mingtao [2 ]
机构
[1] School of Information and Control Engineering, Jilin Institute of Chemical Technology, Jilin
[2] College of Electrical and Information Engineering, Jilin University of Agricultural Science and Technology, Jilin
关键词
attention mechanism; GhostNetV2; mask detection; Swin-Transformer;
D O I
10.3778/j.issn.1002-8331.2304-0243
中图分类号
学科分类号
摘要
The existing mask detection models cannot balance detection accuracy and detection speed, and have a large number of parameters. In order to solve these problems, an improved YOLOv5 based mask detection algorithm is proposed. It mainly includes the following four improvements:Firstly, replace the C3 module in the YOLOv5s backbone network with the lightweight network GhostNetV2 to reduce the number of parameters; Secondly, replace the last C3 module of the YOLOv5s backbone extraction network and the C3 module of the last layer of Neck with a Swin Transformer structure to obtain more complete feature information and improve detection performance; Thirdly, introduce CBAM attention mechanism to better focus on key information, thereby improving detection efficiency and accuracy; Fourth, the loss function replaces GIoU with EIoU to improve positioning accuracy and speed up convergence. The experimental results on the AIZOO dataset show that the mAP value of the proposed impoved algorithm reaches 96.2%, Params is reduced to 6.6× 106, and FPS is as high as 136. There is also a good improvement on the validation dataset, and compared to other algorithms, the performance is better. The proposed improved algorithm is more suitable for mask detection. © 2023 Journal of Computer Engineering and Applications Beijing Co., Ltd.; Science Press. All rights reserved.
引用
收藏
页码:223 / 231
页数:8
相关论文
共 23 条
[1]  
REDMON J, FARHADI A., YOLO9000:better, faster, stronger[C], Proceedings of the 2017 IEEE Conference on Computer Vision and Pattern Recognition, pp. 6517-6525, (2017)
[2]  
REDMON J, FARHADI A., YOLOv3:an incremental improvement, (2018)
[3]  
BOCHKOVSKIY A, WANG C Y, LIAO H Y M., YOLOv4: optimal speed and accuracy of object detection, (2020)
[4]  
YANG Q M, CHEN M B, HUANG Y G, Et al., Pig counting algorithm based on improved YOLOv5n, Journal of Agricultural Machinery, 54, 1, pp. 251-262, (2023)
[5]  
ZHANG L P, LI Z H, TANG Y L., Detection method of lightweight YOLOv2 mask wearing based on transfer learning, Electronic Measurement Technology, 45, 10, pp. 112-117, (2022)
[6]  
XU Z H, LIU C., Mask wearing detection algorithm based on improved YOLOv3, Information Recording Materials, 23, 7, pp. 158-161, (2022)
[7]  
CHEN Z L, QI H, WANG X C., Research on mask wearing detection based on improved YOLOv5 algorithm, Electronic Design Engineering, 30, 22, pp. 67-72, (2022)
[8]  
MA C, WU H R, YU H S., Detection method of cabbage disease based on YOLOX[J], Jiangsu Agricultural Science, 51, 8, pp. 193-202, (2023)
[9]  
HE K, ZHANG X, REN S, Et al., Spatial pyramid pooling in deep convolutional networks for visual recognition[J], IEEE Transactions on Pattern Analysis and Machine Intelligence, 37, 9, pp. 1904-1916, (2014)
[10]  
WANG C Y, LIAO H, YEH I H, Et al., CSPNet:a new backbone that can enhance learning capability of CNN[C], Proceedings of the 2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops, pp. 1571-1580, (2019)