| As one of the main materials of industrial products,steel plate has a wide range of uses in various industries.With the industrial upgrading of our country,the requirements for steel plates have gradually shifted from increasing production to improving quality.Due to the influence of technical factors in the production process of steel plates,various types of defects may occur on the surface of the steel plate.These defects will affect the performance of the steel to varying degrees,and even cause serious production accidents.Therefore,the research on surface defect detection of steel plate is of great significance.Compared with traditional target detection algorithms,target detection based on deep learning has the advantages of high detection accuracy,fast detection speed,and good portability,so it is more suitable for application in industrial scenarios.In this paper,the steel plate is taken as the research object,and the YOLOv5 target detection algorithm is used as the basic algorithm to study the surface defect detection of steel plate.The specific research contents are as follows:(1)First,the current mainstream target detection algorithms are introduced and compared.After analysis,the YOLOv5 algorithm with the best comprehensive performance is selected as the basic algorithm of this research.The data set of steel surface defects was analyzed in detail.In view of the small number of data sets and insufficient samples,the data set expansion scheme combining linear contrast enhancement and Mosaic data enhancement was used to preprocess the data set to avoid the occurrence of overfitting.(2)In order to solve the problems such as large positioning deviation of prediction frame and insufficient feature extraction of defect target in steel plate surface defect detection task,K-means clustering and FCM clustering are used in YOLOv5 target detection algorithm,and CBAM and Fca Net are introduced into the backbone network.Through comparative experiments,optimizing the Anchor matching algorithm alone or adding attention mechanism can effectively improve the performance of the model.The optimization of Anchor matching algorithm reduces the prediction cross regression loss and improves the positioning accuracy of YOLOv5 model for defects.The addition of attention mechanism effectively improves the model’s ability to extract target defect features by increasing the weight of useful features on the input image.(3)Carry out the surface defect detection experiment of steel plate,and combine the two improved schemes of prediction frame matching algorithm and adding attention mechanism,and obtain four combined improved YOLOv5 network models.By comparing the performance parameters of these four improved models through experiments,the optimal YOLOv5 network is obtained.The m AP of the original YOLOv5 network is 71.8%,while the m AP value of the optimal YOLOv5 network reaches 75.1%,and the problem of false detection and missed detection has also been significantly improved.Then,the optimal YOLOv5 network model is used to detect the defects of the actual steel plate,and the detection effect is analyzed.(4)Build a software system for surface defect detection of steel plates,and the functions of data set training and steel plate surface defect detection can be realized through this software system. |