摘要
现有印刷电路板(PCB)缺陷检测方法,多采用参考法进行检测,对图片配准要求高,不仅耗时且定位误差大。YOLOv4速度快,精度高,但应用在PCB检测上存在着漏检的情况,对小目标检测效果不佳,现提出了一种基于改进YOLOv4算法的PCB缺陷检测方法。首先,以CSPDarknet53为主干网络,采用单特征层结构,避免了数据不均衡带来的先验框分配问题。然后,将网络中的5次卷积改进为CSP结构的残差单元,进一步提高特征提取能力。最后,采取K-means++对先验框重新进行聚类,提高模型训练效果。实验部分采取北京大学发布的PCB数据集进行训练,结果表明,改进后的算法平均精度均值(mAP)达到98.71%,在精度上优于其他常见的目标检测算法。
Reference template is used in most methods of PCB defect detection, which is very time consuming and causes a big position error. YOLOv4 is fast but it misses the object easily in PCB detection and its accuracy is not high in detecting the small object. Therefore, the method of PCB defect detection based on improved YOLOv4 algorithm is proposed. Firstly, CSPDarknet53 is used as backbone and the structure of single feature layer is adopted, which avoids the prior boxes assignment problem caused by data imbalance. Then, five convolutions are improved using CSP to increase further the ability offeature extract.Finally, prior boxes are gotten by using K-means++ to improve the training effect. In the experiment, Peking University PCB public dataset is used for training. The result shows that mean average precision of our algorithm achieves 98.71% and it has a better performance compared with other several classical object detection algorithms.
作者
李澄非
蔡嘉伦
邱世汉
梁辉杰
Li Chengfei;Cai Jialun;Qiu Shihan;Liang Huijie(Faculty of Intelligent Manufacturing,Wuyi University,Jiangmen 529020,China)
出处
《电子测量技术》
北大核心
2021年第17期146-153,共8页
Electronic Measurement Technology
基金
2017年广东省科技发展专项(2017A010101019)
2019年广东省普通高校特色创新类项目(2019KTSCX181)资助。