CSAMamba-YOLOv8: a method for detecting defects on steel surfaces
摘要
In order to tackle the problems of missed detections and insufficient accuracy when identifying defects on steel strips, this paper introduces Mamba into YOLOv8, proposing a defect detection approach for steel surfaces called Channel-Spatial Attention Mamba YOLOv8 (CSAMamba-YOLOv8). First, Mamba is improved by incorporating channel and spatial attention mechanisms, resulting in the CSAMamba module, which optimizes the model’s effectiveness in extracting features. Second, the simple channel concatenation in the neck network of YOLOv8 is replaced with a weighted channel concatenation approach to improve feature fusion. Lastly, a dedicated small defect detection head is added to the head network, enhancing accuracy in identifying smaller defects. CSAMamba-YOLOv8 achieves a 79.9% mAP on the NEU-DET dataset, surpassing the baseline YOLOv8n by 2.2%. Compared to mainstream object detection algorithms, CSAMamba-YOLOv8 demonstrates superior overall performance, particularly exhibiting higher accuracy and robustness in detecting small defects. However, these improvements come with a trade-off in terms of increased computational overhead. Despite the higher number of parameters and GFLOPs, the model maintains real-time processing speeds, making it a viable solution for industrial applications.