摘要
针对PCB在生产过程中会出现短路、漏孔等缺陷,已有的损失函数和降采样算法存在定位不准确等导致缺陷检测收敛缓慢、检测结果不准确的问题,提出了一种基于掩模降采样和微小缺陷交并比损失的一阶段缺陷检测器.首先,提出基于面积损失的微小缺陷交并比损失函数,以进行更精确的微小缺陷回归定位;其次,提出基于动态掩模的降采样算法,以利于检测器在缩小参数矩阵尺寸过程中自动筛选重要特征、次要特征和噪声特征,提升缺陷检测器的特征提取能力.实验结果表明,提出的缺陷检测器在北京大学PCB缺陷数据集和Deep PCB数据集上可分别达到98.50%的mAP和99.02%的mAP,优于对比算法;提出的降采样算法使YOLOv5等检测器的mAP在北京大学PCB数据集中提升了1.6个百分点,提出的损失函数有利于YOLOv3和YOLOv4等检测器提升其在2个数据集上的检测准确率,展现出良好的鲁棒性.
Aiming at the PCB in the production process will appear short circuit,missing holes and other defects,the existing loss function and down sampling algorithms have inaccurate localization and so on leading to the slow convergence of defect detection,inaccurate detection results,a mask down sampling and tiny defects based on the intersection of the ratio of the loss of the one-stage defect detector is proposed.First,an area loss-based loss function is proposed for more accurate regression localization of tiny defects.Second,a dynamic mask-based down sampling algorithm is proposed to facilitate the automatic screening of important,secondary and noisy features in the process of reducing the size of the parameter matrix,so as to improve the feature extraction capability of the defect detector.The experimental results show that the proposed defect detector can achieve 98.50%mAP and 99.02%mAP on the Peking University PCB defect dataset and Deep PCB dataset,respectively,which is better than the comparison algorithms;the proposed downsampling algorithm improves the mAP of the detectors such as YOLOv5 in the PCB dataset of Peking University by 1.6 percentage points.The proposed loss function facilitates the detectors such as YOLOv3 and YOLOv4 to improve their detection accuracies on the two datasets,showing good robustness.
作者
李刚
邵瑞
李敏
万洪林
周鸣乐
韩德隆
Li Gang;Shao Rui;Li Min;Wan Honglin;Zhou Mingle;Han Delong(Key Laboratory of Computing Power Network and Information Security,Ministry of Education,Shandong Computer Science Center(National Supercomputer Center in Jinan),Qilu University of Technology(Shandong Academy of Sciences),Jinan 250014;Shandong Provincial Key Laboratory of Computer Networks,Shandong Fundamental Research Center for Computer Science,Jinan 250014;School of Physical and Electronic Sciences,Shandong Normal University,Jinan 250358)
出处
《计算机辅助设计与图形学学报》
北大核心
2025年第1期176-184,共9页
Journal of Computer-Aided Design & Computer Graphics
基金
山东省重点研发计划(重大科技创新工程)(2023CXGC010112)
泰山学者工程(tsqn202103097).
关键词
损失函数设计
降采样
缺陷检测
目标检测
loss function design
down sampling
defect detection
object detection