Fabric Defect Detection Algorithm Based on Improved Canny Operator
An improved algorithm based on Canny operator is proposed to solve the problem that the tradition-al Canny algorithm is greatly affected by noise and has poor adaptability when applied to defects detection.Firstly,the compound morphological filter is used to replace the original Gaussian filter,and the noise reduc-tion effect is better.Secondly,the 3×3 Sobel operator is used to calculate the gradient amplitude and direction to improve the positioning accuracy.Finally,according to the gray characteristics of the image,the iterative threshold method is used to improve the shortcomings of the artificially set threshold and enhance the adap-tive threshold acquisition.The experimental results show that compared with the traditional Canny algorithm and other algorithms,the improved Canny algorithm can obtain defect information more accurately,effective-ly enhance the anti-interference of fabric images to noise,and perform better in mean square error and peak signal-to-noise ratio,which improves the universality of the detection algorithm.