摘要
[目的]针对苹果无损检测过程中表面缺陷检测精度低的问题,提出一种基于DSCS-YOLO的苹果表面缺陷检测方法。[方法]首先为提高网络对表面缺陷细节特征的提取能力,设计一种基于Dense模块以及SE模块的深浅特征选择模块DSCS(deep and shallow feature selection module),采用DSCS替换Backbone中的C3模块,在保留表面缺陷浅层信息的基础上强化对重要特征的学习,并起到削弱冗余特征的作用;针对Backbone与Neck部分输出信息过多导致的参数耦合问题,利用解耦头原理对Head层部分进行分层预测。其次采用ELU激活函数改进原有解耦头,简化末端结构,使网络训练更加容易。最后针对表面缺陷标注困难的问题,采用Wise-IoU损失函数代替CIoU损失函数,为不同质量的标注提供非线性增益,实现网络的动态聚焦学习。[结果]DSCS-YOLO提高了对小目标的检测能力,在苹果表面缺陷测试集上平均精度均值达到90.9%,相较于YOLOv3-tiny、YOLOv5s、YOLOX-s以及SSD分别提高了4.5%、1.9%、6.3%、16.3%,检测效果最优。同时模型参数量为9.54 M,推理时间仅为2.8 ms,检测速度快,满足实际应用需求。[结论]改进后的DSCS-YOLO提高了YOLOv5s算法的精度,实现了苹果表面缺陷的精准识别。
[Objectives]Aiming at the low detection accuracy of apple surface defects in the process of non-destructive testing,an apple surface defect detection method based on DSCS-YOLO was proposed.[Methods]Firstly,in order to improve the network’s ability to extract detailed features of surface defects,a deep and shallow feature selection module DSCS based on Dense and SE modules was designed.The C3 module in Backbone was replaced by DSCS,which strengthened the learning of important features and weakened redundant features on the basis of retaining superficial information of surface defects.In order to solve the problem of parameter coupling caused by excessive output information of Backbone and Neck,the Decoupled Head principle was used to make hierarchical prediction of Head layer.At the same time,the ELU activation function was used to improve the original Decoupled Head,simplify the terminal structure,and make the network training easier.Finally,to solve the difficulty of labeling surface defects,Wise-IoU loss function was used to replace CIoU loss function,which provided nonlinear gain for labeling of different qualities and realized dynamic focused learning of the network.[Results]DSCS-YOLO improved the detection of small targets,and the mean average precision of the apple surface defect test set reached 90.9%,which was 4.5%,1.9%,6.3%and 16.3%higher than that of YOLOv3-tiny,YOLOv5s,YOLOX-s and SSD,respectively,showing the best detection effect.At the same time,the number of model parameters was 9.54 M,and the inference time was only 2.8 ms.The detection speed was fast,which could meet the needs of practical applications.[Conclusions]The improved DSCS-YOLO improved the accuracy of YOLOv5s algorithm and realized the accurate identification of apple surface defects.
作者
朱琦
周德强
盛卫锋
左文娟
朱家豪
ZHU Qi;ZHOU Deqiang;SHENG Weifeng;ZUO Wenjuan;ZHU Jiahao(College of Mechanical Engineering,Jiangnan University,Wuxi 214122,China;Jiangsu Key Laboratory of Advanced Food Manufacturing Equipment&Technology,Wuxi 214122,China)
出处
《南京农业大学学报》
CAS
CSCD
北大核心
2024年第3期592-601,共10页
Journal of Nanjing Agricultural University
基金
无锡市科技局资助项目(G20222014)。