With the rapid development of industrial manufacturing intelligence,the demand for product measurement in enterprises is gradually increasing.Enterprises need to judge whether to adjust production processes based on timely measurement feedback.Traditional measurement methods can no longer meet the measurement task needs of enterprises.Compared with traditional measurement methods,machine vision technology not only has high measurement accuracy,fast speed,no need to touch the test piece,can achieve non-destructive measurement,but also can achieve online measurement.Therefore,this article takes hole shaped workpieces as the research object and studies the online measurement technology of their external dimensions.The main research content is as follows:This article designs the overall structure of the online measurement system based on the actual measurement needs for the measurement of the external dimensions of the hole shaped workpiece production process,builds an intuitive lightweight measurement system platform,selects the hardware,and jointly develops the measurement software system using programming methods such as Lab VIEW,MATLAB,and Python;Preprocess the collected image of the hole workpiece,propose an improved adaptive median filtering method,and compare and study it with other filtering algorithms.Introduce image evaluation indicators for objective evaluation,and the results show that the proposed method has good image filtering and denoising effect;Propose the use of AOA improved OTSU threshold segmentation method to binarize the image,separating the target area to be measured from the background,reducing useless information interference.Compare and analyze the proposed method with other threshold segmentation methods,and the results show that the proposed segmentation method can effectively preserve edge details,improve the running speed by 50.18% compared to traditional OTSU methods,and improve the evaluation index Recall value by 0.006554 compared to traditional OTSU methods,The proposed method is superior to traditional methods for image segmentation;Adopting a deep learning RCF edge detection method to detect and extract image edge features,and comparing and analyzing it with other edge extraction methods,optimizing the phenomenon of coarse edges generated by RCF edge detection method in extracting images;The Zernike moment subpixel level edge detection method is used to further extract more accurate subpixel level edge points than the pixel level,and the least squares method is used to measure the circular fitting size and linear fitting size of subpixel edge points.Two sets of measurement experiments are set up,and the measurement results show that the measurement accuracy of the measurement system is 0.01 mm,with a standard deviation of0.0028 mm,a relative error of less than 0.060%,and a single measurement speed of 2.3s,which is 13.04 times faster than manual sampling.With the online measurement system,measurements are made more rapidly than with manual sampling,and they are more accurate,which has certain practical applications. |