In order to solve the problems of a high mismatching rate and being easily affected by noise and gray transformation, an improved product defect detection method combining centroid distance and textural information is proposed in this paper. Based on image preprocessing, the improved fuzzy C-means clustering method is used to extract the closed contour features. Then, the contour center distance description operator is used for bidirectional matching, and a robust coarse matching contour pair is obtained. After the coarse matching contour pair is screened, the refined matching result is obtained by using the improved local binary pattern operator. Finally, by comparing whether the number of fine matching pairs is consistent with the number of template outlines, the detection of good and bad industrial products is realized, and the closed contour extraction experiment, the anti-rotation matching experiment, the anti-gray difference matching experiment, and the defect detection experiment of three different products are designed. The experimental results show that the improved product defect detection method has good performance in relation to anti-rotation transformation and anti-gray difference, the detection accuracy can reach more than 90%, and the detection time is up to 362.6 ms, which can meet the requirements of industrial real-time detection.
Read full abstract