Computer and Modernization ›› 2024, Vol. 0 ›› Issue (02): 88-92.doi: 10.3969/j.issn.1006-2475.2024.02.014

Previous Articles     Next Articles

Lightweight PCB Defect Detection Method Based on Multi-scale Features and Attention Mechanism

  

  1. (School of Computer Science and Technology, Guangdong University of Technology, Guangzhou 510006, China)
  • Online:2024-02-19 Published:2024-03-19

Abstract: Abstract: To address the issues of surface background interference in PCB defect detection and resource consumption caused by large detection models, a lightweight network model called SL-Unet is proposed for effective extraction of multi-scale and edge information in PCB surface defect detection. SL-Unet utilizes the U-Net structure as the backbone network. Firstly, the U-shaped residual structure is used to capture multi-scale information in each dimension of the backbone network, strengthening the communication between shallow and deep information, and introducing the DropBlock module to improve the model’s generalization ability. Secondly, the edge information of the decoder is used to complete deep supervision, and a lightweight channel attention module is incorporated to enhance the feature dependence of edge information, guiding the backbone network to perceive the edge information of defects when extracting features. Then, a multi-level joint loss is constructed through the edge-aware module for the optimization of the overall model. Finally, the Leaky ReLU function is used to replace the ReLU function in the network, improving the model’s feature extraction ability in the negative interval. Experimental results show that the Dice coefficient, intersection over union, image detection frame rate and model size indicators of SL-Unet reach 79.3%, 67.4%, 22 frames/s and 3.46MB, respectively, greatly ensuring the lightweight of the model and significantly improving the detection accuracy of PCB surface defect images.

Key words: Key words: deep supervision, defect detection, lightweight network, attention mechanism, U-Net

CLC Number: