Design of defect detection system for glass fiber plied yarn based on machine vision
Objective It is important that tension abnormalities and yarn hairiness can be detected accurately and efficiently during the production of glass fiber plied yarns as a type of raw material for electronic fabric production.Manual inspection has disadvantages such as low efficiency,high leakage rate and long lag time.Therefore,a machine vision-based method for detecting defects in plied yarns is proposed to meet the need for accurate detection of defects in real time during plied yarn production.Method The conventional algorithm pre-processes the image with threshold segmentation,open operation and contour extraction,and makes a preliminary judgement on the image by calculating whether the limits and heights of the contours are within the normal range,while the deep learning algorithm uses YOLOv5 and is optimized and accelerated using the TensorRT framework to make a secondary judgement on the image and locate defects.The proposed system used a Jetson Nano B01 as the hardware platform,an industrial camera to capture images of the plied yarn in real time,and a relay to control the winder and alarm light circuit.Results In this research,the image size of the training data set was 1 280 pixel×288 pixel,and the types of defects were divided into two categories,namely uneven tension and hairiness,according to the actual requirements.The proportion of samples used in the training set,validation set and test set were 70%,15%and 15%,respectively.The training was conducted using YOLOv5 weights,with a batch size of 32 samples,where the image size was adjusted to 640 pixel×640 pixel,and the number of processes set to 2,for a total of 300 iterations.Training and testing were conducted on a deep learning server with a primary configuration of an Intel Core(TM)i9-10900X CPU 3.70 GHz,a 24 GB GPU GeForce RTX 3090 graphics card,and 128 GB of running memory.The test results showed that pre-processing using the conventional algorithm had the advantage of higher speed and low loss,detecting much faster than using the deep learning network alone,significantly reducing the amount of network computation and increasing the detection efficiency of the system.The use of deep learning algorithms for secondary determination had the advantage of high accuracy and defect localization,effectively avoiding false detection caused by using traditional algorithms alone and improving detection accuracy and production efficiency.In the production of plied yarns,considering the extremely high production speed and the need for product quality,the accuracy of detection,the miss detection rate and the detection processing time were used as indicators,and plied yarn samples that were normal and free of defects as well as those containing tension irregularities and hairiness were selected for testing.The experimental results showed that the system achieved 99.07%detection accuracy and 1.4%leakage rate.The camera acquisition yarn processed one frame at an average of 0.007 s,the algorithm detection yarn processed one frame at an average of 0.005 6 s and the subsequent processing yarn processed one frame at an average of 0.004 9 s.The camera acquisition and detection processing speed was above 112 frames per second,which meets the actual production inspection needs and effectively improves the inspection efficiency and facilitates the automatic detection of plied yarn defects.Conclusion The system is based on the Jetson Nano B01 as the hardware processing platform,and uses a combination of conventional algorithms and deep learning algorithms for detection.The system takes the advantages of fast processing speed of conventional algorithms for image pre-processing and preliminary judgement,and using the advantages of high accuracy of deep learning algorithms for secondary judgement when the conventional algorithms think there is a defect.It overcomes the shortcomings of the conventional algorithm's poor defect location ability and the deep learning algorithm's slow detection speed,while ensuring detection speed and accuracy.The Tkinter human-machine interface and the logging module provide the necessary functions for industrial sites.The system meets the need for real-time defect detection during the production of plied yarns,improving production efficiency and product quality.