引用本文: | 凌强,刘宇,王春举,贺海东,孙立宁.DN-YOLOv5的金属双极板表面缺陷检测算法[J].哈尔滨工业大学学报,2023,55(12):104.DOI:10.11918/202212004 |
| LING Qiang,LIU Yu,WANG Chunju,HE Haidong,SUN Lining.DN-YOLOv5 algorithm for detecting surface defects of metal bipolar plates[J].Journal of Harbin Institute of Technology,2023,55(12):104.DOI:10.11918/202212004 |
|
摘要: |
为解决氢燃料电池中金属双极板表面缺陷尺寸小,缺陷对比不明显、种类多造成的难以检测,易误检漏检以及缺陷检测模型复杂度太大难以部署等问题,提出一种改进版的金属双极板缺陷检测算法DN-YOLOv5,来探究缺陷检测在冲压成形的金属双极板视觉检测工作台场景下进行快速精准检测的可行性,从而实现智能检测,提升检测效率。本研究着重于修改YOLOv5主干网络Backbone部分,添加网络中模块数量,加入NAM注意力机制和使用深度可分离卷积模块来替代原来CSP/CBS主干网络卷积模块,并引入SIoU对损失函数重新进行了定义,极大的提升了主干网络的轻量化程度。结果表明,本算法的map@0.5可达0.988,每秒检测传输帧率为9.98,模型参数量降低了52.13%,在测试集75张缺陷图像中真检率达到了99.74%。该方法在保证模型较高检测率的同时,显著降低了模型复杂度和参数计算量。此外,该算法结合新的检测尺度设计特征融合网络,提升网络的小目标、多目标检测能力。该算法具有良好的稳定性和鲁棒性,综合性能较好,满足部署移动端场景进行缺陷检测的轻量化需求。 |
关键词: 金属双极板 表面缺陷检测 DN-YOLOv5 轻量化网络 注意力机制 特征融合 |
DOI:10.11918/202212004 |
分类号:TP391 |
文献标识码:A |
基金项目:国防基础科研重点项目(JCKY2020203B056);江苏省高等学校自然科学研究重大项目(20KJA460003);江苏省前沿引领技术基础研究专项(SBK2019060036) |
|
DN-YOLOv5 algorithm for detecting surface defects of metal bipolar plates |
LING Qiang,LIU Yu,WANG Chunju,HE Haidong,SUN Lining
|
(School of Mechanical and Electrical Engineering, Soochow University, Suzhou 215137, Jiangsu, China)
|
Abstract: |
To solve the problems of small size of metal bipolar plate surface defects in hydrogen fuel cells, indistinct defect contrast and various types of defects that make it difficult to detect, easily cause false and leaky detection and large size of the complexity of defect detection model that makes it difficult to deploy, an improved metal bipolar plate defect detection algorithm DN-YOLOv5 is proposed to explore the feasibility of rapid and accurate defect detection in the scene of metal bipolar plate visual detection workbench formed by stamping, so as to realize intelligent detection and improve detection efficiency. This research focuses on modifying the Backbone part of YOLOv5 backbone network, adding the number of modules in the network and the NAM attention mechanism, using the deeply separable convolution module to replace the original CSP/CBS backbone network convolution module and introducing SIoU to redefine the loss function, which greatly improves the lightweight degree of the backbone network. The experimental results show that the algorithm map@0.5 can reach 0.988, the detection transmission frame rate per second is 9.98, the number of model parameters is reduced by 52.13% and the true detection rate of 75 defect images in the test set reaches 99.74%. This method not only ensures the high detection rate of the model, but also significantly reduces the complexity of the model and the amount of parameter calculation. In addition, the algorithm combines the new detection scale to design a feature fusion network, which improves the small target and multi-target detection capabilities of the network. It has good stability, good robustness and good comprehensive performance, meeting the lightweight requirements of deploying mobile end scenarios for defect detection. |
Key words: metal bipolar plate surface defect detection DN-YOLOv5 lightweight network attention mechanism feature fusion |