PCB-AM: Enhanced Defect Detection for PCBs via Attention-Guided Modules
摘要
Accurate detection of defects in printed circuit boards (PCBs) is essential to ensure the quality and reliability of electronic products. However, traditional inspection methods are often labor-intensive and prone to errors, necessitating more automated and effective solutions. In this work, we propose PCB-AM, an enhanced detection framework that integrates two novel components: the Attention and Channel Shuffle Enhanced C2f (ACSE-C2f) module and the Multi-Scale Probabilistic Sampling Attention (MSPSA) mechanism. The ACSE-C2f module replaces the standard C2f block in the YOLOv8s backbone, improving feature representation through attention-guided channel interactions. Meanwhile, MSPSA dynamically adjusts receptive fields and highlights defect-prone regions via adaptive pooling and feature shuffling. Extensive experiments on the DsPCBSD+ dataset demonstrate that PCB-AM achieves state-of-the-art performance, particularly in detecting small and intricate defects, with an impressive mAP@50 of 85.7%, validating both the accuracy and efficiency of the proposed method.