Metal Surface Defect Segmentation Algorithm Based on Improved YOLOv5
Aiming at the problem of poor positioning accuracy of the current industrial image surface defect detection algorithm,a defect segmentation algorithm based on improved YOLOv5 is proposed.Firstly,ODConv is used to replace the original Conv module in the first two layers of the backbone network,so that the downsampling information of the picture can be better preserved;Secondly,using Meta-ACON activa-tion function instead of SiLU activation function can improve the feature extraction ability by learning to automatically use activation function with better performance;Thirdly,SimAM attention mechanism is intro-duced into the lower feature extraction part and Neck layer to enhance the feature extraction ability;Finally,Alpha-IoU is introduced as the loss function,which improves the accuracy of bounding box regression.The experimental results show that the detection accuracy(map)of the improved segmentation model is 86.7%,which is 20.1%higher than the original YOLOv5 network and 2%higher than the latest detection model YOLOv8.Therefore,the improved model in this paper not only has high detection accuracy,but also the segmentation detection algorithm can locate the defect position more accurately.