Font Size: a A A

Research And Application Of Metal Surface Defect Detection Algorithm Based On Pixel Segmentation Method

Posted on:2024-01-30Degree:MasterType:Thesis
Country:ChinaCandidate:Y X WangFull Text:PDF
GTID:2531307124994639Subject:Computer technology
Abstract/Summary:PDF Full Text Request
In the defect detection method based on deep learning,the image segmentation method regards the defect detection task as a segmentation task.This method has the ability to obtain the precise shape and position information of the defect,accurately measure the size of the defect,and has more advantages in the detection of weak semantic defects.Because of these advantages,it can provide more reliable help in judging product quality during quality inspection.It has attracted a large number of domestic and foreign scholars to pay extensive attention and research on its theory and applications.As one of the most important products in the manufacturing industry,the product quality of metal products is particularly important,so the research on algorithms related to defect detection on metal surfaces has important application value.This paper firstly introduces and analyzes the defect detection algorithm and its development status in the industry systematically,and compares the advantages and disadvantages of various methods.Secondly,two improved algorithms are proposed for the defect detection algorithm based on pixel segmentation.Finally,the improved algorithm is applied to the problem of metal surface defect detection.The research work and innovation points mainly include the following aspects:(1)For surface images with various interference factors,this paper proposes a surface defect detection algorithm based on U~2-Net(Attention-U~2Net).First of all,in order to solve the problem that the background image is misjudged and the information obtained by the sampling layer is not detailed enough due to excessive surface image noise in actual production,a U-shaped attention coding module is designed.This method can increase the weight of defect area while suppressing background noise during coding.Then,in order to solve the complex problems of difficult-to-detect samples and boundaries in the image,a weighted loss function is designed and combined with a multi-level supervision method,so that the detection algorithm pays more attention to the difficult-to-detect samples and boundary pixels,and improves the prediction accuracy.Finally,an algorithm that automatically calculates the grayscale threshold according to the image results is used to optimize the results,and finally a high-quality defect prediction map is generated.Through a large number of simulation experiments,and compared with other pixel segmentation methods used in the field of defect detection,the experimental results show that the algorithm has strong anti-interference factor ability,and the final defect prediction image has high pixel accuracy and obvious boundaries.(2)In order to solve the problems of difficult-to-detect samples,unbalanced distribution of positive and negative samples in practical applications,and the large amount of training data and long training time required for deep learning algorithms,this paper proposes a surface defect detection algorithm based on attention coding Res Net.First,the improved Res Net34 is used as the encoder to form an encoding-decoding structure with the corresponding decoder,and the processing module of the attention mechanism is added to the skip connection layer.Then,a low-resolution feature refinement module(LFRM)for low-resolution images is designed,and it is applied to the deepest skip connection layer,so that the algorithm can effectively extract the feature information in low-resolution images to achieve the purpose of the refinement feature.Finally,a loss function that combines Focal Loss and Dice Loss is used,so that the detection algorithm can better cope with the uneven distribution of positive and negative samples and the problem of difficult-to-detect samples.A large number of simulations and comparative experiments show that the proposed algorithm has obvious advantages in average pixel accuracy compared with other image segmentation algorithms,and it also has good results in the precision rate,another important index that is concerned in the industry,which can meet the practical needs of the industry.need.(3)Based on the algorithm proposed in Chapter 4,this paper designs a metal surface defect detection system,and applies the algorithm to the metal surface defect detection scene.In terms of the specific implementation of the system,after the steps of acquiring data,processing data,and training the network in the initialization phase,the system is deployed in practical application scenarios.Demonstration of actual cases proves that the algorithm and system proposed in this paper can well complete the task of defect detection in actual scenarios,and have high application value.
Keywords/Search Tags:deep learning, defect detection, image segmentation, pixel segmentation, attention coding
PDF Full Text Request
Related items