用生成数据提升PCB缺陷检测,小缺陷识别率显著提高
UniPCB: A Generation-Assisted Vision-Based Measurement Framework for PCB Defect Inspection

- 通过生成带边缘、深度和纹理条件的合成缺陷图增强训练数据
- 在改进的DsPCBSD+数据集上达到98.0% [email protected]和61.8% [email protected]:0.95
- 适合需要高精度小缺陷检测的工业视觉系统开发者
自动化光学检测(AOI)通过图像识别印刷电路板(PCB)上的物理缺陷,但常受限于缺陷样本稀缺、类别不平衡,以及小而低对比度缺陷在密集电路图案中难以识别。本文提出UniPCB,一种基于生成辅助的视觉检测框架,结合可控缺陷合成与任务特定检测。生成分支从真实PCB图像中提取异质的边缘、相对伪深度和纹理条件,通过四尺度U-Net结构的ScaleEncoder编码,并利用FiLM风格的空间自适应融合块进行条件调制。检测分支引入倒置残差移位注意力模块实现全局-局部联合建模,以及跨层级互补融合模块实现选择性层次特征整合。生成图像用于扩充训练数据,提升缺陷覆盖范围,且不改变在线检测流程。在修正标注的DsPCBSD+数据集上,[email protected]达98.0%,[email protected]:0.95为61.8%。相同生成增强训练下,较RT-DETR基线分别提升2.1和1.7个百分点。生成分支的FID为129.61,SSIM为0.619。结果表明,结构化合成数据与面向PCB的特征建模对提升视觉缺陷检测具有潜力。代码已开源。
原文摘要 · Abstract (English)
Automated optical inspection (AOI) is a vision-based instrumentation process that detects and localizes physical defects on printed circuit boards (PCBs) from optically acquired images. Its reliability is often limited by scarce and class-imbalanced defect observations and by insufficient representation of small, low-contrast defects against dense circuit patterns. We propose UniPCB, a generation-assisted PCB inspection framework that combines controlled defect synthesis with task-specific detection. The generation branch derives heterogeneous edge, relative pseudo-depth, and text conditions from PCB images. A ScaleEncoder embeds the conditions at four U-Net resolutions, while a Condition Modulation block performs FiLM-style spatially adaptive fusion. The detection branch introduces an Inverted Residual Shift Attention block for joint global-local modeling and a Cross-level Complementary Fusion block for selective hierarchical feature integration. The generated images augment the detector training data and improve defect coverage without changing the online inspection path. Experiments using the corrected annotations of DsPCBSD+ yield an [email protected] of 98.0% and an [email protected]:0.95 of 61.8%. Under the same generation-augmented training setting, these values exceed those of the RT-DETR baseline by 2.1 and 1.7 percentage points, respectively. The generation branch obtains an FID of 129.61 and an SSIM of 0.619. These results indicate the potential of structured synthetic data and PCB-oriented feature modeling for improving vision-based defect inspection. Code is available at https://github.com/House-yuyu/UniPCB.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。