China
Detecting defects is crucial to ensuring the quality of printed circuit board (PCB) products. Due to the diminutive nature of surface defects on PCBs, current detection algorithms struggle to extract small defect features accurately, leading to a propensity for missed detections. To tackle these challenges, we propose a PCB defect detection algorithm that builds upon the YOLOv7 algorithm with enhancements. Firstly, we integrate the proposed CREC module into the backbone network to enhance the capture of local features about minor defects. Secondly, we propose the integration of a multi-scale feature fusion module, SPPB, within the head network to selectively activate channels or positions related to minor defects in the feature map, thereby enhancing the accuracy of local feature extraction for minor defects. Subsequently, the algorithm is endowed with higher efficiency in learning small defect features with the help of a new loss function, MPNWD. Finally, a small target detection layer P2 is added to enrich the contextual information in order to facilitate the algorithm to understand the relationship between small defects and their surrounding regions. Experimental results demonstrate the effectiveness of the enhanced YOLOv7 algorithm in testing the PCB_DATASET defect dataset, achieving a detection accuracy (mAP) of 99.3%, surpassing YOLOv7 by 5.4%, and outperforming other algorithms in terms of detection accuracy.
© 2008-2025 Fundación Dialnet · Todos los derechos reservados