SAF-YOLOv8:改进YOLOv8金属表面缺陷检测算法

Authors:
  • 姚咏姚咏儿YaoYonger
    姚咏儿YaoYonger
  • 曹一曹一青CaoYiqing
    曹一青CaoYiqing
  • 闫恪闫恪涛YanKetao
    闫恪涛YanKetao

Abstract
To address challenges such as the diversity of types, significant variations in scale, and high rates of missed detections for defects on metal surfaces, an improved defect detection algorithm based on YOLOv8 is proposed. First, by integrating the strengths of spatial and channel reconstruction convolution (SCConv) and iterative attentional feature fusion (IAFF) modules, this study replaces the C2f module in the Backbone network with the SCConv-IAFF-C2f (SI-C2f) module, thereby improving the feature learning and fusion capabilities of the model. Subsequently, four detection heads are generated using an extended head module, and the four-adaptive spatial feature fusion head (FASFFHead) module is designed by incorporating adaptive spatial feature fusion (ASFF) module for achieving multi-scale defect detection. Finally, down-sampling operations in the Neck network are optimized through the adaptive down-sampling (ADown) module, which preserves critical information in feature maps while reducing resolution. Ablation and comparative experiments are conducted on the GC10-DET dataset. Results demonstrate that the mean average precision (mAP@0.50) of the SAF-YOLOv8 algorithm reaches 70.8%, representing increases of 3.6 percentage point and 1.6 percentage point compared to YOLOv8n and YOLOv8s, respectively. Furthermore, the algorithm exhibits notable improvements in precision and mAP@0.50 when compared to YOLOv10 and YOLOv11. SAF-YOLOv8 significantly enhances the accuracy of defect detection on metal surfaces and better meets the requirements of industrial inspections.