668 | 6 | 69 |
下载次数 | 被引频次 | 阅读次数 |
针对印制电路板(PCB)缺陷区域受背景干扰过多以及缺陷目标尺度较小导致缺陷检测精度低的问题,提出了一种基于注意力机制与多尺度融合的PCB缺陷检测方法。在YOLOv5模型的特征提取网络中,引入一种三维注意力模块,以增强缺陷目标特征的显著度,使模型更加注重目标特征;为充分利用微小缺陷目标的多尺度特征,在特征融合网络中引入加权双向特征金字塔网络(Bi-directional Feature Pyramid Network, BiFPN),减少缺陷目标特征信息的丢失,提高模型对微小缺陷目标的检测精度。实验结果表明,该方法能够准确检测出PCB图像中的缺陷目标,在保证实时性的同时,较原方法的平均检测精度提高了3.9%,表明了该方法的有效性。
Abstract:Considering the low detection accuracy caused by defect areas of PCB due to excessive background interference and the small scale of defective objects, a defect detection method of PCB based on attention mechanism and multi-scale fusion is proposed. Firstly, to enhance the saliency of defective object features and make the model focus more on object features, a 3D attention module is introduced in the feature extraction network based on YOLOv5. Secondly, to make full use of the multi-scale features of tiny defective object, a weighted Bi-directional Feature Pyramid Network(BiFPN) is introduced in the feature fusion network to reduce the loss of feature information of the defective object and improve the detection accuracy of the model for small defective object. Finally, the experimental results show that the method can accurately detect the defective objects in PCB images, and the average detection accuracy is improved by 3.9% compared with the original method while the real-time performance is ensured, which shows the effectiveness of the method.
[1] 董静毅,吕文涛,包晓敏,等.基于机器视觉的PCB板表面缺陷检测方法研究进展[J].浙江理工大学学报(自然科学版),2021,45(3):379-389.
[2] LUO J X,YANG Z Y,LI S P,et al.FPCB Surface Defect Detection:A Decoupled Two-stage Object Detection Framework[J].IEEE Transactions on Instrumentation and Measurement,2021,70:1-11.
[3] REN S Q,HE K M,GIRSHICK R,et al.Faster R-CNN:Towards Real-time Object Detection with Region Proposal Networks[J].IEEE Transactions on Pattern Analysis and Machine Intelligence,2017,39(6):1137-1149.
[4] DING R W,DAI L H,LI G P,et al.TDD-Net:A Tiny Defect Detection Network for Printed Circuit Boards[J].CAAI Transaction on Intelligence Technology,2019,4(2):110-116.
[5] HU B,WANG J H.Detection of PCB Surface Defects with Improved Faster-RCNN and Feature Pyramid Network[J].IEEE Access,2020,8:108335-108345.
[6] REDMON J,FARHADI A.YOLOv3:An Incremental Improvement[EB/OL].(2018-04-08)[2023-03-10].https://arxiv.org/abs/1804.02767.
[7] BOCHKOVSKIY A,WANG C Y,LIAO H Y M.YOLOv4:Optimal Speed and Accuracy of Object Detection[EB/OL].(2020-04-23)[2023-03-10].https://arxiv.org/abs/2004.10934.
[8] ULTRALYTICS.YOLOv5[EB/OL].[2023-03-25].https://github.com/ultralytics/yolov5.
[9] LIU W,ANGUELOV D,ERHAN D,et al.SSD:Single Shot MultiBox Detector[C]//European Conference on Computer Vision (ECCV).Amsterdam:Springer,2016:21-37.
[10] LAN Z,HONG Y,LI Y.An Improved YOLOv3 Method for PCB Surface Defect Detection[C]//2021 IEEE International Conference on Power Electronics,Computer Applications (ICPECA).Shenyang:IEEE,2021:1009-1015.
[11] 何国忠,梁宇.基于卷积神经网络的PCB 缺陷检测[J].图学学报,2022,43(1):21-27.
[12] TAN M X,PANG R M,LE Q V.EfficientDet:Scalable and Efficient Object Detection[C]//2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition(CVPR).Seattle:IEEE,2020:10778-10787.
[13] WANG J F,CHEN Y,DONG Z K,et al.Improved YOLOv5 Network for Real-time Multi-scale Traffic Sign Detection[J].Neural Computing and Applications,2022,35(10):7853-7865.
[14] ZHU X K,LYU S C,WANG X,et al.TPH-YOLOv5:Improved YOLOv5 Based on Transformer Prediction Head for Object Detection on Drone-captured Scenarios[C]//2021 IEEE/CVF International Conference on Computer Vision (ICCV).Montreal:IEEE,2021:2778-2788.
[15] LIN T Y,DOLLAR P,GIRSHICK R,et al.Feature Pyramid Networks for Object Detection[C]//2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR).Honolulu:IEEE,2017:2117-2125.
[16] LIU S,QI L,QIN H F,et al.Path Aggregation Network for Instance Segmentation[C]//2018 IEEE Conference on Computer Vision and Pattern Recognition (CVPR).Salt Lake City:IEEE,2018:8759-8768.
[17] PKU-Market-PCB[EB/OL].(2019-01-24)[2023-03-10].https://robotics.pkusz.edu.cn/r-esources/dataset/.
[18] LIU Y C,SHAO Z R,HOFFMANN N.Global Attention Mechanism:Retain Information to Enhance Channel-spatial Interactions[EB/OL].(2021-10-10)[2023-03-01].https://arxiv.org/abs/2112.05561.
[19] WOO S,PARK J,LEE J Y,et al.CBAM:Convolutional Block Attention Module[C]//European Conference on Computer Vision (ECCV) 2018.Munich:Springer,2018:3-19.
[20] HOU Q B,ZHOU D Q,FENG J S.Coordinate Attention for Efficient Mobile Network Design[C]//2021 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR).Nashville:IEEE,2021:13708-13717.
[21] CAI Z W,VASCONCELOS N.Cascade R-CNN:Delving into High Quality Object Detection[C]//2018 IEEE Conference on Computer Vision and Pattern Recognition (CVPR).Salt Lake City:IEEE,2018:6154-6162.
[22] 李闻,李小春,闫昊雷.基于改进YOLO v3的PCB缺陷检测[J].电光与控制,2022,29(4):106-111.
[23] GE Z,LIU S T,WANG F,et al.YOLOX:Exceeding YOLO Series in 2021[EB/OL].(2021-07-18)[2023-02-10].https://arxiv.org/abs/2107.08430.
基本信息:
DOI:
中图分类号:TP391.41;TN41
引用信息:
[1]陆维宽,周志立,阮秀凯等.基于注意力机制与多尺度融合的PCB缺陷检测[J].无线电工程,2024,54(01):6-13.
基金信息:
国家自然科学基金(61671329)~~