摘要
针对汽车漆面缺陷检测精度不足和速度缓慢的难题,提出一种基于改进YOLOv8的汽车漆面缺陷检测算法。首先,在YOLOv8网络中Neck部分嵌入卷积块注意力模块(Convolutional Block Attention Module, CBAM),它能够有效挖掘汽车漆面缺陷的通道和空间特征信息。其次,采用轻量化的CARAFE(Content-Aware Reassembly of Features)模块取代原YOLOv8网络中Neck部分的传统上采样模块,避免上采样过程中特征信息的丢失,生成更多的细节和平滑的边缘,有效增加了模型的感受域。这些优化措施显著提升了模型对漆面缺陷特征的捕捉能力,进而提高了模型的检测精度。最后,采用了知识蒸馏(教师-学生模型)技术,即将改进的YOLOv8算法作为教师模型,将轻量化的YOLOv8s算法作为学生模型,利用领学-互学策略,实现了计算成本的节约和检测速度的提升。实验结果表明:改进后的YOLOv8对汽车漆面缺陷检测的平均精度为92.6%,相比于YOLOv8提升了3.7个百分点,且改进后的模型参数量为1.1×10^(6),相比于YOLOv8的参数量减少了2.1×10^(6),且该模型每秒传输帧数超过YOLOv8,检测速度保持在149 f/s,可以满足实时识别的要求,能够有效解决汽车漆面缺陷检测准确率低和检测速度慢的问题,表明了所提算法具有有效性。
In order to address the challenges of insufficient accuracy and sluggish speed in automotive paint surface defect detection,an automotive paint surface detection method based on YOLOv8 is proposed.Firstly,the convolutional block attention module(CBAM)within the Neck section of the YOLOv8 network is embeded,which effectively mines both channel and spatial feature information pertaining to automotive paint defects.Secondly,the conventional upsampling module in the Neck section of the original YOLOv8 network is substituted with a lightweight content-aware reassembly of features(CARAFE)module.This substitution mitigates the loss of feature information during upsampling,generates more intricate details and smoother edges,and notably expands the model's receptive field.These optimizations significantly bolster the model's ability to capture paint surface defect features,thereby enhancing detection accuracy.Lastly,knowledge distillation(teacher-student model)is applied to the improved YOLOv8 network,with the improved YOLOv8 algorithm as the teacher mod-el and a lightweight YOLOv8s serving as the student model.Leveraging a lead-learn-collaborate strategy,saving computational cost and enhancing detection speed are achieved.Experimental results demonstrate that the im-proved YOLOv8 achieves a mean average precision of 92.6%for automotive paint surface defect detection,marking a 3.7%improvement over the original YOLOv8.Furthermore,the refined model has a parameter count of 1.1×10^(6),which is 2.1×10^(6)fewer than YOLOv8.Additionally,the model transmits more frames per second than YOLOv8 and maintains a detection speed of 149 f/s,which meets the requirements of real-time recogni-tion.It can effectively solve the problems of low accuracy and slow detection speed in automotive paint defect detection,demonstrating the effectiveness of the automotive paint defect detection algorithm.
作者
王剑楠
胡璐萍
管声启
白永平
臧凯
林文彩
WANG Jiannan;HU Luping;GUAN Shengqi;BAI Yongping;ZANG Kai;LIN Wencai(School of Automotive Engineering,Xi'an Aeronautical Polytechnic Institute,Xi'an 710089,China;School of Mechanical and Electrical Engineering,Xi'an Traffic Engineering Institute,Xi'an 710300,China;School of Mechanical and Electrical Engineering,Xi'an Polytechnic University,Xi'an 710048,China)
出处
《测控技术》
2025年第6期32-39,共8页
Measurement & Control Technology
基金
陕西省教育厅科研计划项目(23JK0531)。