| To resolve the problems of heavy workload, low efficiency, high requirements for operators during anti sand blasting device thread detecting, the device trapezoidal thread parameters measuring theory and technology are researched in this thesis. The research findings can be used to enhancing the automation degree and stability of the thread measuring process, and provide theoretical and technical basis for a complete parameters measurement of the device.The thread measurement platform at the basis of double telecentric optical system is designed. The structure and requirements of detection object are introduced, the working principle and advantages of double telecentric optical system are analyzed, the system accuracy are analyzed and calculated at the basis of engineering test theory, the main devices are selected according to measureing accuracy, and the trapezoidal thread measuring scheme for the detection system is designed. The double telecentric imaging system work bench are designed based on system scheme.The thread image processing methods, which are included by gray scale image conversion method, image filtering method, and image segmentation method, are researched. Different gray scale image conversion methods are analyzed and experiments are preformed, according to the experiment results, the physiology gray scale image conversion method tend to get more clear object feature. Experiments using different image filtering method are performed and the results showed that the Disk filtering algorithm is better for noise area suppressing. Different image segmentation methods are used for object extracting, and the Otsu threshold segmentation method is selected. Above methods are used for the thread image processing.The detection region extraction method is studied. Gray level projection methods are proposed for the purposed of determining the target area coordinates, and The mathematical model of the maximum gray level projection and the cumulative projection method are builded. Experiments are performed and the results tell that the cumulative projection method obtained more clear and comprehensive object feature information, thus it is selected to compute Horizontal and vertical projection of the image. Finally, the project curves were shaping.The detection region determination method is studied. According to feature points of the detected image, the gradient algorithm is used to highlight the feature points on the projection curves, and absolute value calculation is used to convert the negative valley points to peak points. The peak points detection method is used to extract the peak points, and the coordinates of detection area are calculated according to the relationship among the detected peak points. The detection region is extended for the purpose of get more complete detection region information.The thread parameters image measuring methods are studied. In the process of contour data extraction, traditional edge detection methods are analyzed, and the experiment results showed that the traditional methods include many interference factors, and the detected edge width is not uniform. To resolve those disadvantages, mathematical morphology based contour extraction method is proposed. At the basis of detected contour data, the measuring and computing methods of lead, large diameter, small diameter, height of the tooth and middle diameter are studied. In the process of lead measuring, one-dimensional extraction method is used to obtain contour feature and multi-curve extraction method is used to get lead parameters. The left lead and right lead are computed and the comprehensive measuring result is calculated. During thread diameter measurement, large diameter, small diameter and height of the tooth are computed according to bilateral image model, and the middle diameter is calculated according to definition of middle diameter.The researching results can be used for parameters image measuring of triangular thread, slot and step, moreover, the findings can provide theoretical basis and method support for nn line visual inspection of workpiece contour parameters. |