| Metal shield is a protective component of semiconductor chip,its surface quality has a direct impact on the performance and reliability of the chip,so in the production process,metal shield surface defect detection is very important.However,the surface of metal shield contains complex background texture,which will cause interference in the process of defect detection and affect the accuracy of detection.Although artificial eye inspection and machine vision detection methods already exist,but there are some limitations,and the detection accuracy is not high.In recent years,deep learning has been widely adopted and applied in defect detection by virtue of its strong versatility and autonomous learning ability.Therefore,this paper proposes a complex metal surface defect detection method based on the deep learning method.The main contents are as follows.1)Aiming at the small data set and uneven data distribution of metal surface defect image,a least squares conditional generation adduction network(LS-CGAN)was developed to enhance the existing data set of metal surface defect image.By introducing the classification information of metal surface defects into discriminators and generators that generate adversant networks(Gans),the network model is able to generate defect data of a specified category.The least square loss function is used to improve the original network objective function,which makes the training of the network model more stable and improves the quality of the generated image.2)In order to solve the problem that the complex background texture on metal surface interferes with the defect detection,a background texture suppression method based on the connected area is studied.In this method,Gabor texture feature extraction method is used to obtain the background texture of metal surface,and then the extracted texture feature image is detected based on binarization connected region,and the background texture is distinguished according to different connected region areas.For pits with large areas,improved wavelet transform is used to suppress the texture.Grayscale co-occurrence matrix and non-negative matrix decomposition are used to process the fringe texture and abrasive texture with small area,so as to achieve the purpose of suppressing background texture.3)Aiming at the problems of low accuracy and large model of defect recognition and classification algorithm,a defect recognition and classification model based on Ghost NetYOLOv5 was studied.Firstly,K-means algorithm is used to generate a prior box suitable for the data set in this paper by clustering,so as to improve the detection accuracy to a certain extent.Then,a small target detection head is added to the network model to improve the feature extraction ability of small targets,so as to solve the problem of low detection accuracy when the defect target is small.In addition,Ghost Net is used to replace the original backbone network,reducing the number of parameters and making the network model more lightweight.4)The above defect detection methods are coordinated and a visual software interface is designed to verify the detection methods.In this paper,by studying the data enhancement of metal surface defect image,image background texture suppression and defect recognition and classification methods,the accurate detection of metal surface defect has been achieved,and the detection speed is fast,which meets the requirements of actual industrial detection. |