Detection method of position and posture of cheese yarn based on machine vision
Objective Aiming at the detection of cheese yarn's posture and position of cheese packages in the process of cheese yarn handling,this research proposes a machine vision based method for detecting the position and posture of cheese packages to provide data support for robots to accurately grasp the cheese package in manufacturing.Method An industrial camera was adopted to capture an image of the cheese yarn.Improved median filtering was adopted to preprocess the image,then Canny edge detection was adopted to acquire the contour curve of the cheese yarn,the discrete curve was smoothed using B-spline curve,the curvature distribution of the discrete curve was calculated and to determine the placement status,and finally the bobbin yarn center point was calculated.A curvature distribution based line detection algorithm was adopted to acquire the edges of the cheese yarn and calculate the pose angle of the cheese yarn axis.Results Through experiments,it was found that improved median filtering can distinguish between texture and edge regions in images,and adaptively use windows of different sizes for filtering.This effectively filters texture signals while preserving edge signals.This research compares the accuracy and stability of several line detection algorithms in experiments.250 images of the cheese yarn in a horizontal position were selected and their two edges are marked.Then,the line detection algorithm proposed,Hough transform,and EDLines were adopted to detect the images.The accuracy rate,missed detection rate,time consumption,angle error and position error of the algorithms were compared.The algorithm proposed has a detection accuracy of 100%for 250 images,without missed detections.The angle and position errors also reach the level of conventional line detection algorithms,ensuring the accuracy of the pose angle calculation of the cheese yarn,and the computational complexity is small,which can effectively save calculation time.Three different sizes of cheese yarns were selected for pose detection and conduct fetching experiments.The selected three types of cheese yarn have diameters of 160 mm,200 mm,250 mm,with cheese lengths of 180 mm.The cheese is FANUC M-20iA/35M.The cheese yarn was randomly placed on the device platform,then an industrial camera was adopted to take photos of the cheese yarn and the algorithm proposed was utilized to detect the position of the cheese yarn.The detected position results are sent to the robotic arm,guiding the robotic arm to fetch the cheese yarn and conducting 50 tests on each size of cheese yarn.From the experiment results,it can be seen that the algorithm proposed can accurately identify the position and pose of different sizes of cheese yarns,and has a small error.It can guide the robotic arm to accurately grasp the cheese yarn,with a success rate of 100%.The algorithm proposed also has real-time performance,and the average detection time for different sizes and placement states of cheese yarn is stable between 19 ms and 24 ms,with an overall average time of 21.61 ms.Conclusion This research proposes a method for detecting the pose of cheese yarn based on machine vision.Firstly,based on the improved median filtering algorithm,the collected image of the bobbin yarn is preprocessed.Then,the Canny edge detection algorithm is adopted to extract the contour of the cheese yarn,and the contour curvature of the bobbin yarn is calculated.Finally,the contour curvature is adopted to calculate the pose information of the cheese yarn.Through experiments,it has been proven that the algorithm proposed can effectively detect the position and orientation of the cheese yarn,and has good accuracy and adaptability.It can accurately guide the robotic arm to grasp the cheese yarn,and the success rate for grasping light-colored cheese yarn of variable sizes is 100%,with an average time consumption of 21.61 ms.
cheese yarnmachine visionposture detectioncheese yarn handlingB-spline curveline detectionautomatic production