Skeleton oil seal inner diameter and roundness composite detection system, method, equipment and medium based on machine vision

CN116576785BActive Publication Date: 2026-11-03JIANGSU XCMG CONSTRUCTION MACHINERY RESEARCH INSTITUTE LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202310510818.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-08
Publication Date
2026-11-03
Estimated Expiration
2043-05-08

AI Technical Summary

Technical Problem

Existing technologies cannot achieve combined detection of the inner diameter and roundness of skeleton oil seals, resulting in low detection efficiency and low accuracy. Furthermore, existing vision inspection systems cannot guarantee that the center of the workpiece is located at the center of the camera's field of view, leading to significant errors.

Method used

A machine vision-based inspection system is adopted, including an inspection platform, a positioning and adjustment mechanism, and an acquisition mechanism. The camera's Z-axis height is calibrated using a calibration plate, and the center point position is calculated using Canny edge detection and Hough circle transform algorithms. Combined with adaptive Gauss filtering and binarization processing, the inner diameter and roundness of multiple skeleton oil seals are detected.

Benefits of technology

It achieves high efficiency and high precision in the combined detection of the inner diameter and roundness of skeleton oil seals, improves detection efficiency, reduces errors, and meets the detection requirements of multiple samples.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116576785B_ABST
    Figure CN116576785B_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on machine vision's skeleton oil seal inner diameter and roundness composite detection system, method, equipment and medium, obtain camera Z-axis height, and establish the original coordinate system of camera field of view;Obtain the image containing all to be measured sample that camera is shot at Z-axis height, the image containing all to be measured sample is handled, obtains each to be measured sample center point position, and is converted into the coordinate in the original coordinate system of camera field of view;According to the coordinate of each to be measured sample center point position in the original coordinate system of camera field of view, the position of camera on positioning adjustment mechanism is adjusted, after adjustment, each to be measured sample is successively photographed, and the image of each to be measured sample is obtained;The image of each to be measured sample is preprocessed, and the profile point coordinate data of preprocessed image is extracted, and the inner diameter and roundness of to be measured sample are calculated according to the profile point coordinate data of preprocessed image.The application structure is simple, easy to realize, and detection efficiency and precision are high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to a composite detection system, method, equipment, and medium for the inner diameter and roundness of a skeleton oil seal based on machine vision, belonging to the field of visual inspection technology. Background Technology

[0002] The skeleton oil seal is a typical example of an oil seal. It isolates the lubricated parts in the transmission system from the external environment and is widely used in rotary drilling rig power heads, road roller vibratory wheels and drive axles, and gearboxes to prevent lubricating oil leakage and impurities from entering.

[0003] However, excessive dimensional deviations in the skeleton oil seal can lead to severe oil leakage in the components, and may even cause insufficient lubrication of the main unit and core components, resulting in abnormal noises and wear in parts such as gears and bearings, and ultimately component failure, affecting the reliability of the whole machine and core components.

[0004] Currently, the lip of the skeleton oil seal is made of elastic rubber, which is quite sensitive to measurement force, making it impossible to inspect directly using contact measurement methods such as calipers and plug gauges. Existing technology proposes a visual inspection system for the inner diameter of gearbox oil seals, using a monocular camera for non-contact inspection. However, it cannot guarantee that the center of the workpiece is at the center of the camera's field of view during photography, and lens distortion and edge defocusing can easily cause significant errors. Furthermore, existing technology can only inspect the inner diameter of a single oil seal, and cannot perform combined inspection of the inner diameter and roundness of multiple samples, resulting in low inspection efficiency and low accuracy.

[0005] Therefore, how to achieve convenient and rapid combined detection of the inner diameter and roundness of the skeleton oil seal is a technical problem that urgently needs to be solved by those skilled in the art. Summary of the Invention

[0006] Objective: In order to overcome the shortcomings of the existing technology, the present invention provides a composite detection system, method, equipment and medium for skeleton oil seal inner diameter and roundness based on machine vision.

[0007] Technical solution: To solve the above technical problems, the technical solution adopted by the present invention is as follows:

[0008] Firstly, a machine vision-based composite detection system for the inner diameter and roundness of a skeleton oil seal includes: a detection platform, a positioning and adjustment mechanism, and a data acquisition mechanism.

[0009] The testing platform includes: an LED light source board, anchor bolts, and a positioning plate. The LED light source board is mounted on the positioning plate, and anchor bolts are provided at the four corners of the positioning plate.

[0010] The positioning and adjustment mechanism includes: a first lead screw, a second lead screw, a rear plate, a longitudinal rail, a first connecting plate, a slider, a second connecting plate, a transverse rail, a first motor, and a second motor. The positioning plate has a first lead screw and a second lead screw vertically mounted at both ends. A cover plate connects the tops of the first and second lead screws, and the rear end of the cover plate is connected to the rear plate vertically mounted on the positioning plate. A first rail is mounted in front of the rear plate. A slider is movably mounted on the first rail. The first and second lead screws are movably connected to both ends of the first connecting plate. The rear side of the first connecting plate is connected to the slider, and the front side is connected to the rear side of the second connecting plate. A transverse rail is mounted on the top of the first connecting plate. A slot is cut into the top side of the second connecting plate, and a conveyor belt is installed within the slot. A first motor is mounted on the cover plate, causing the slider to slide along the longitudinal rail. A second motor is mounted at one end of the second connecting plate, causing the conveyor belt within the slot to rotate.

[0011] The acquisition mechanism includes: a slide table, a third connecting plate, a worm gear, a turbine, a third motor, a camera bracket, and a camera. One end of the slide table is movably connected to a transverse track, and the bottom of the slide table is connected to a conveyor belt on the second connecting plate. A third connecting plate is located on the top of the slide table, and the worm gear is housed within a hole in the third connecting plate, with its front end connected to the camera bracket. The camera is mounted on the camera bracket. A third motor is also located on the top of the slide table, driving the turbine to rotate; the turbine meshes with the rear end of the worm gear.

[0012] Furthermore, the LED light source board is used to place the skeleton oil seal to be tested.

[0013] Furthermore, it also includes a processing device, which is connected to a first motor, a second motor, a third motor and a camera respectively, for performing a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal.

[0014] Secondly, a machine vision-based method for combined detection of the inner diameter and roundness of a skeleton oil seal includes the following steps:

[0015] Step 1: Obtain the camera's Z-axis height using the calibration plate and standard sample, and establish the original coordinate system of the camera's field of view.

[0016] Step 2: Acquire an image of all the test samples taken by the camera at the Z-axis height. Process the image containing all the test samples to obtain the center point position of each test sample and convert it into coordinates in the original coordinate system of the camera's field of view.

[0017] Step 3: Based on the coordinates of the center point of each test sample in the original coordinate system of the camera's field of view, adjust the position of the camera on the positioning adjustment mechanism. After adjustment, take pictures of each test sample in sequence to obtain an image of each test sample.

[0018] Step 4: Preprocess the image of each sample to be tested, extract the contour point coordinate data of the preprocessed image, and calculate the inner diameter and roundness of the sample to be tested based on the contour point coordinate data of the preprocessed image.

[0019] Furthermore, it also includes step 5.

[0020] Step 5: Display the inner diameter and roundness of the sample to be tested, and save it to the database.

[0021] Furthermore, step 1 includes:

[0022] Step 1.1: Place the calibration board and standard sample on the LED light source board, turn on the LED light source and camera, and determine the appropriate camera Z-axis height based on the size of the standard sample in the camera's field of view.

[0023] Step 1.2: Calculate the actual size corresponding to the width of each pixel in the image based on the ratio of the scale markings on the calibration plate to the number of pixels in the image. Calibrate the pixel width according to the size of the standard sample, establish the original coordinate system of the camera's field of view, and complete the calibration.

[0024] Furthermore, step 2 includes:

[0025] Step 2.1: Place the multiple skeleton oil seals to be tested on the LED light source board, and take images using a camera with a determined Z-axis height. The images are processed by Canny edge detection, binarization, and Hough circle transform algorithm to calculate the center point position of each sample and convert it into coordinates in the original coordinate system of the camera's field of view.

[0026] Furthermore, step 3 includes:

[0027] Step 3.1: Based on the coordinates of the center point of each sample under test in the original coordinate system of the camera's field of view, calculate the position of the camera's X-axis and Y-axis, and adjust them using the second and third motors so that the center point of the camera's field of view is moved above the center point of the sample under test, at the same height as the calibrated Z-axis height.

[0028] Step 3.2: Move to the center point of all the test samples in sequence and take an image of each test sample.

[0029] Furthermore, step 4 includes:

[0030] Step 4.1: Perform adaptive Gauss filtering and binarization on the image of each test sample to obtain the preprocessed image.

[0031] Step 4.2: Extract the contour point coordinate data (x, y) of the preprocessed image. i y iBased on the coordinates of N contour points, calculate parameters C, D, E, G and H, and calculate parameters a and b based on C, D, E, G and H.

[0032] The calculation formulas for parameters C, D, E, G, and H are as follows:

[0033]

[0034] The formulas for calculating parameters a and b are as follows:

[0035]

[0036] Step 4.3: Based on parameters a and b, calculate the x-coordinate A and y-coordinate B of the center of the circle corresponding to each contour point.

[0037] The x-coordinate A and y-coordinate B of the center of the circle are calculated using the following formulas:

[0038]

[0039] Step 4.4: Substitute each A and B into the contour circle equation to calculate the radius R of the N contour circles. i .

[0040] The radius R of the contour circle i The calculation formula is as follows:

[0041] R i 2 =(x i -A) 2 +(y i -B) 2

[0042] Step 4.5: Calculate the radius R of the N contour circles. i The average value is used as the inner diameter of the sample to be tested.

[0043] Step 4.5: Calculate the radius R of the N contour circles. i The maximum and minimum values ​​are calculated, and the difference between the maximum and minimum values ​​is used as the roundness of the sample to be tested.

[0044] Thirdly, a machine vision-based composite detection device for the inner diameter and roundness of a skeleton oil seal includes the following modules:

[0045] Calibration module: Used to obtain the camera's Z-axis height using a calibration board and standard samples, and to establish the original coordinate system of the camera's field of view.

[0046] Center point acquisition module: used to acquire images of all test samples taken by the camera at the Z-axis height, process the images containing all test samples, obtain the center point position of each test sample, and convert it into coordinates in the original coordinate system of the camera's field of view.

[0047] Automatic positioning module: It is used to adjust the position of the camera on the positioning adjustment mechanism according to the coordinates of the center point of each test sample in the original coordinate system of the camera's field of view. After adjustment, it takes pictures of each test sample in sequence to obtain an image of each test sample.

[0048] Data processing module: used to preprocess the image of each sample to be tested, extract the contour point coordinate data of the preprocessed image, and calculate the inner diameter and roundness of the sample to be tested based on the contour point coordinate data of the preprocessed image.

[0049] Furthermore, it also includes a data results module.

[0050] Data Results Module: Used to display the inner diameter and roundness of the sample under test and save them to the database.

[0051] Furthermore, the calibration module includes:

[0052] Place the calibration board and standard sample on the LED light source board, turn on the LED light source and camera, and determine the appropriate camera Z-axis height based on the size of the standard sample in the camera's field of view.

[0053] Based on the ratio of the scale markings on the calibration plate to the number of image pixels, the actual size corresponding to the width of each pixel in the image is calculated. The pixel width is calibrated according to the size of the standard sample, and the original coordinate system of the camera field of view is established to complete the calibration.

[0054] Furthermore, the center point acquisition module includes:

[0055] Multiple skeleton oil seals to be tested were placed on an LED light source board, and images were captured using a camera with a determined Z-axis height. The images were then processed using Canny edge detection, binarization, and Hough circle transform algorithm to calculate the center point position of each sample and convert it into coordinates in the original coordinate system of the camera's field of view.

[0056] Furthermore, the automatic positioning module includes:

[0057] Based on the coordinates of the center point of each sample under test in the original coordinate system of the camera's field of view, the X-axis position and Y-axis position of the camera are calculated. The camera's field of view center point is then adjusted by the second and third motors so that it is moved above the center point of the sample under test, at the same height as the calibrated Z-axis height.

[0058] Move sequentially above the center point of all the test samples and take an image of each test sample.

[0059] Furthermore, the data processing module includes:

[0060] Adaptive Gauss filtering and binarization are performed on the image of each test sample to obtain the preprocessed image.

[0061] Extract the contour point coordinate data (x) of the preprocessed image. i y i Based on the coordinates of N contour points, calculate parameters C, D, E, G and H, and calculate parameters a and b based on C, D, E, G and H.

[0062] The calculation formulas for parameters C, D, E, G, and H are as follows:

[0063]

[0064] The formulas for calculating parameters a and b are as follows:

[0065]

[0066] Based on parameters a and b, calculate the x-coordinate A and y-coordinate B of the center of the circle corresponding to each contour point.

[0067] The x-coordinate A and y-coordinate B of the center of the circle are calculated using the following formulas:

[0068]

[0069] Substitute each A and B into the contour circle equation to calculate the radius R of the N contour circles. i .

[0070] The radius R of the contour circle i The calculation formula is as follows:

[0071] R i 2 =(x i -A) 2 +(y i -B) 2

[0072] Find the radius R of N contour circles i The average value is used as the inner diameter of the sample to be tested.

[0073] Find the radius R of N contour circles i The maximum and minimum values ​​are calculated, and the difference between the maximum and minimum values ​​is used as the roundness of the sample to be tested.

[0074] Fourthly, a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal as described in any of the second aspects.

[0075] Fifthly, a computer device comprising:

[0076] Memory is used to store instructions.

[0077] A processor is configured to execute the instructions, causing the computer device to perform an operation of a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal as described in any of the second aspects.

[0078] Beneficial effects: The machine vision-based composite detection system, method, equipment and medium for skeleton oil seal inner diameter and roundness provided by the present invention have a simple structure, are easy to implement, and have high detection efficiency and accuracy.

[0079] This invention utilizes machine vision inspection methods to achieve combined detection of the inner diameter and roundness of multiple skeleton seals, thereby improving inspection efficiency. Through "visual calibration + centering," it achieves high-definition image imaging and distortion correction, which improves inspection accuracy. Attached Figure Description

[0080] Figure 1 This is a schematic diagram of the skeleton sealing detection system of the present invention.

[0081] Figure 2 This is a schematic diagram of the positioning and adjustment mechanism of the present invention.

[0082] Figure 3 This is a schematic flowchart of the skeleton sealing detection method of the present invention.

[0083] Figure 4 This is a schematic diagram of the skeleton sealing detection device of the present invention.

[0084] In the figure: 1. Detection platform, 11. LED light source board, 12. Anchor bolt, 13. Positioning plate, 14. Detection sample; 2. Positioning adjustment mechanism, 201. Longitudinal support, 202. First lead screw, 203. Second lead screw, 204. Cover plate, 205. Rear plate, 206. Longitudinal track, 207. First connecting plate, 208. Slider, 209. Second connecting plate, 210. Transverse track, 211. First motor, 212. Second motor; 3. Acquisition mechanism, 31. Slide table, 32. Third connecting plate, 33. Worm gear, 34. Turbine, 35. Third motor, 36. Camera bracket, 37. Camera; 4. Processing device. Detailed Implementation

[0085] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the protection scope of the present invention.

[0086] The present invention will be further described below with reference to specific embodiments.

[0087] like Figure 1-2 As shown in the figure, the first embodiment is a composite detection system for the inner diameter and roundness of a skeleton oil seal based on machine vision, including: a detection platform 1, a positioning and adjustment mechanism 2, a data acquisition mechanism 3, and a processing device 4.

[0088] The testing platform 1 includes: an LED light source board 11, anchor bolts 12, a positioning plate 13, and test samples 14. The LED light source board 11 is located in the center of the positioning plate 13, and the anchor bolts 12 are located at the four corners of the positioning plate 13 for fixing the positioning plate 13. There are multiple test samples 14, which are evenly distributed in the center of the LED light source board 11 and do not overlap or obstruct each other.

[0089] The positioning and adjustment mechanism 2 includes: a longitudinal support 201, a first lead screw 202, a second lead screw 203, a cover plate 204, a rear plate 205, a longitudinal track 206, a first connecting plate 207, a slider 208, a second connecting plate 209, a transverse track 210, a first motor 211, and a second motor 212. The longitudinal support 201 is perpendicularly fixed to both ends of the positioning plate 13. The first lead screw 202 and the second lead screw 203 are positioned in front of the longitudinal support 201 and perpendicularly fixed to both ends of the positioning plate 13. The top ends of the longitudinal support 201, the first lead screw 202, and the second lead screw 203 are connected through the cover plate 204 to stabilize the first lead screw 202 and the second lead screw 203. The rear plate 205 is connected to the rear side of the longitudinal support 201, the cover plate 204, and the top surface of the positioning plate 13, and the first track 206 is arranged at the central axis of the rear plate 205. A first connecting plate 207 is arranged between the first lead screw 202 and the second lead screw 203. A slider 208 is arranged behind the first connecting plate 207, and a second connecting plate 209 with a conveyor belt is arranged in front of it. A transverse track 210 is arranged on the top of the first connecting plate 207. A slot is cut into the top side of the second connecting plate 209, and a conveyor belt is arranged within the slot. A first motor 211, externally mounted on the cover plate 204, allows the slider 208 to slide along the longitudinal track 206, enabling vertical adjustment of the acquisition mechanism 2. A second motor, externally mounted on the second connecting plate 209, allows the conveyor belt within the slot to rotate.

[0090] The acquisition mechanism 3 includes: a slide table 31, a third connecting plate 32, a worm gear 33, a turbine 34, a third motor 35, a camera bracket 36, and a camera 37. One end of the slide table 31 is movably connected to the transverse track 210 on the second connecting plate 209. The conveyor belt on the second connecting plate 209 is fixedly connected to the bottom of the slide table 31. In the positioning adjustment mechanism 2, the second motor 212 drives the slide table 31 to move left and right along the second transverse track 210 via the conveyor belt. The top of the slide table 31 is provided with the third connecting plate 32. The worm gear 33 is built into the hole of the third connecting plate 32, and the front end of the worm gear 33 is connected to the camera bracket 36. The camera 37 is installed on the camera bracket 36. The top of the slide table 31 is also provided with the third motor 35. The third motor 35 drives the turbine 34, which meshes with the rear end of the worm gear 33 to drive the worm gear 33 to move back and forth, thereby adjusting the position of the camera 37.

[0091] The processing device 4 includes an intelligent device for performing a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal.

[0092] like Figure 4 As shown in the second embodiment, a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal includes the following steps:

[0093] Step 1: Obtain the camera's Z-axis height using the calibration plate and standard sample, and establish the original coordinate system of the camera's field of view.

[0094] Step 1.1: Place the calibration board and standard sample on the LED light source board, turn on the LED light source and camera, and determine the appropriate camera Z-axis height based on the size of the standard sample in the camera's field of view.

[0095] Step 1.2: Calculate the actual size corresponding to the width of each pixel in the image based on the ratio of the scale markings on the calibration plate to the number of pixels in the image. Calibrate the pixel width according to the size of the standard sample, establish the original coordinate system of the camera's field of view, and complete the calibration.

[0096] Step 2: Acquire an image of all the test samples taken by the camera at the Z-axis height. Process the image containing all the test samples to obtain the center point position of each test sample and convert it into coordinates in the original coordinate system of the camera's field of view.

[0097] Step 2.1: Place the multiple skeleton oil seals to be tested on the LED light source board, and take images using a camera with a determined Z-axis height. The images are processed by Canny edge detection, binarization, and Hough circle transform algorithm to calculate the center point position of each sample and convert it into coordinates in the original coordinate system of the camera's field of view.

[0098] Furthermore, in one embodiment, during the use of the Hough circle transform algorithm, the image resolution, the threshold for accumulating images, the threshold for center detection, and the maximum and minimum range of the inner diameter of the skeleton oil seal are pre-set to achieve optimal sensitivity and obtain more accurate results.

[0099] Step 3: Based on the coordinates of the center point of each test sample in the original coordinate system of the camera's field of view, adjust the position of the camera on the positioning adjustment mechanism. After adjustment, take pictures of each test sample in sequence to obtain an image of each test sample.

[0100] Step 3.1: Based on the coordinates of the center point of each sample under test in the original coordinate system of the camera's field of view, calculate the position of the camera's X-axis and Y-axis, and adjust them using the second and third motors so that the center point of the camera's field of view is moved above the center point of the sample under test, at the same height as the calibrated Z-axis height.

[0101] Step 3.2: Move to the center point of all the test samples in sequence and take an image of each test sample.

[0102] Step 4: Preprocess the image of each sample to be tested, extract the contour point coordinate data of the preprocessed image, and calculate the inner diameter and roundness of the sample to be tested based on the contour point coordinate data of the preprocessed image.

[0103] Step 4.1: Perform adaptive Gauss filtering and binarization on the image of each test sample to obtain the preprocessed image.

[0104] Step 4.2: Extract the contour point coordinate data (x, y) of the preprocessed image. i y i Based on the coordinates of N contour points, calculate parameters C, D, E, G and H, and calculate parameters a and b based on C, D, E, G and H.

[0105] Step 4.3: Based on parameters a and b, calculate the x-coordinate A and y-coordinate B of the center of the circle corresponding to each contour point.

[0106] Step 4.4: Substitute each A and B into the contour circle equation to calculate the radius R of the N contour circles. i .

[0107] Step 4.5: Calculate the radius R of the N contour circles. i The average value is used as the inner diameter of the sample to be tested.

[0108] Step 4.5: Calculate the radius R of the N contour circles. i The maximum and minimum values ​​are calculated, and the difference between the maximum and minimum values ​​is used as the roundness of the sample to be tested.

[0109] The calculation formula in step 4 is as follows:

[0110] 1) The equation of the contour circle is given in formula (1).

[0111] R i 2 =(x i -A) 2 +(y i -B) 2 (1)

[0112] R i --radius

[0113] A – x-coordinate of the center of the circle

[0114] B – the ordinate of the center of the circle

[0115] x i —The i-th horizontal coordinate of the tested oil seal profile

[0116] y i —The i-th ordinate of the tested oil seal profile

[0117] 2) Take N points on the contour and use formulas (2) and (3) to calculate the center of the least squares fitted circle. The calculation results are shown in formula (4).

[0118]

[0119]

[0120]

[0121] 3) Calculate the inner diameter r of the skeleton seal according to formula (5), and calculate the roundness δ of the skeleton seal according to formula (6).

[0122] r = Average(R) i (5)

[0123] δ=max(R i )-min(R i (6)

[0124] Step 5: Display the inner diameter and roundness of the sample to be tested, and save it to the database.

[0125] like Figure 3 As shown in the third embodiment, a machine vision-based composite detection device for the inner diameter and roundness of a skeleton oil seal includes the following modules:

[0126] Calibration module: Used to obtain the camera's Z-axis height using a calibration board and standard samples, and to establish the original coordinate system for the camera's field of view. Specifically includes:

[0127] Place the calibration board and standard sample on the LED light source board, turn on the LED light source and camera, and determine the appropriate camera Z-axis height based on the size of the standard sample in the camera's field of view.

[0128] Based on the ratio of the scale markings on the calibration plate to the number of image pixels, the actual size corresponding to the width of each pixel in the image is calculated. The pixel width is calibrated according to the size of the standard sample, and the original coordinate system of the camera field of view is established to complete the calibration.

[0129] Center point acquisition module: Acquires images of all test samples captured by the camera at the Z-axis height, processes these images to obtain the center point position of each test sample, and converts it into coordinates in the original coordinate system of the camera's field of view. Specifically, this includes:

[0130] Multiple skeleton oil seals to be tested were placed on an LED light source board, and images were captured using a camera with a determined Z-axis height. The images were then processed using Canny edge detection, binarization, and Hough circle transform algorithm to calculate the center point position of each sample and convert it into coordinates in the original coordinate system of the camera's field of view.

[0131] Furthermore, in one embodiment, during the use of the Hough circle transform algorithm, the image resolution, the threshold for accumulating images, the threshold for center detection, and the maximum and minimum range of the inner diameter of the skeleton oil seal are pre-set to achieve optimal sensitivity and obtain more accurate results.

[0132] Automatic positioning module: Based on the coordinates of the center point of each test sample in the original coordinate system of the camera's field of view, the position of the camera on the positioning adjustment mechanism is adjusted. After adjustment, each test sample is photographed sequentially to obtain an image of each test sample. Specifically, this includes:

[0133] Based on the coordinates of the center point of each sample under test in the original coordinate system of the camera's field of view, the X-axis position and Y-axis position of the camera are calculated. The camera's field of view center point is then adjusted by the second and third motors so that it is moved above the center point of the sample under test, at the same height as the calibrated Z-axis height.

[0134] Move sequentially above the center point of all the test samples and take an image of each test sample.

[0135] Data processing module: Used to preprocess the image of each test sample, extract the contour point coordinate data of the preprocessed image, and calculate the inner diameter and roundness of the test sample based on the contour point coordinate data of the preprocessed image. Specifically includes:

[0136] Adaptive Gauss filtering and binarization are performed on the image of each test sample to obtain a preprocessed image.

[0137] Extract contour point coordinate data (x) from the preprocessed image i y i Based on the coordinates of N contour points, calculate parameters C, D, E, G and H, and calculate parameters a and b based on C, D, E, G and H.

[0138] Based on parameters a and b, calculate the x-coordinate A and y-coordinate B of the center of the circle corresponding to each contour point.

[0139] Substitute each A and B into the contour circle equation to calculate the radius R of the N contour circles. i .

[0140] Find the radius R of N contour circles i The average value is used as the inner diameter of the sample to be tested.

[0141] Find the radius R of N contour circles i The maximum and minimum values ​​are calculated, and the difference between the maximum and minimum values ​​is used as the roundness of the sample to be tested.

[0142] Data Results Module: Used to display the inner diameter and roundness of the sample under test and save them to the database.

[0143] The fourth embodiment is a computer-readable storage medium having a computer program stored thereon. When executed by a processor, the computer program implements a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal, as described in any of the second embodiments.

[0144] Fifth embodiment: A computer device, comprising:

[0145] Memory is used to store instructions.

[0146] A processor is configured to execute the instructions, causing the computer device to perform an operation of a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal as described in any of the second embodiments.

[0147] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0148] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0149] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0150] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0151] The above description is only a preferred embodiment of the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.

Claims

1. A composite detection method for the inner diameter and roundness of a skeleton oil seal based on a machine vision-based composite detection system, characterized in that: The composite detection system includes: a detection platform, a positioning and adjustment mechanism, and a data acquisition mechanism; The testing platform includes: an LED light source board, anchor bolts, and a positioning plate; the LED light source board is mounted on the positioning plate, and the positioning plate has anchor bolts at its four corners. The positioning and adjustment mechanism includes: a first lead screw, a second lead screw, a rear plate, a longitudinal rail, a first connecting plate, a slider, a second connecting plate, a transverse rail, a first motor, and a second motor. The positioning plate has a first lead screw and a second lead screw vertically arranged at both ends. A cover plate connects the tops of the first and second lead screws. The rear end of the cover plate is connected to the rear plate vertically arranged on the positioning plate. A first rail is arranged in front of the rear plate. A slider is movably arranged on the first rail. The first and second lead screws are movably connected to both ends of the first connecting plate. The rear side of the first connecting plate is connected to the slider, and the front side is connected to the rear side of the second connecting plate. A transverse rail is arranged on the top of the first connecting plate. A slot is cut into the top side of the second connecting plate, and a conveyor belt is arranged in the slot. A first motor is arranged on the cover plate, causing the slider to slide along the longitudinal rail. A second motor is arranged at one end of the second connecting plate, causing the conveyor belt in the slot to rotate. The acquisition mechanism includes: a slide table, a third connecting plate, a worm gear, a turbine, a third motor, a camera bracket, and a camera; one end of the slide table is movably connected to a transverse track, and the bottom of the slide table is connected to a conveyor belt on the second connecting plate; a third connecting plate is provided on the top of the slide table, the worm gear is built into a hole in the third connecting plate, and the front end of the worm gear is connected to the camera bracket; the camera is mounted on the camera bracket; a third motor is also provided on the top of the slide table, the third motor drives the turbine to rotate, and the turbine meshes with the rear end of the worm gear; The LED light source board is used to place the skeleton oil seal to be tested; It also includes a processing device for performing a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal. Includes the following steps: Step 1: Obtain the camera's Z-axis height using the calibration plate and standard sample, and establish the original coordinate system of the camera's field of view; Step 2: Acquire an image of all the test samples taken by the camera at the Z-axis height, process the image containing all the test samples, obtain the center point position of each test sample, and convert it into coordinates in the original coordinate system of the camera's field of view; Step 3: Based on the coordinates of the center point of each sample under test in the original coordinate system of the camera's field of view, adjust the position of the camera on the positioning adjustment mechanism. After adjustment, take pictures of each sample under test in sequence to obtain an image of each sample under test. Step 4: Preprocess the image of each sample to be tested, extract the contour point coordinate data of the preprocessed image, and calculate the inner diameter and roundness of the sample to be tested based on the contour point coordinate data of the preprocessed image. Step 4 includes: Step 4.1: Perform adaptive Gauss filtering and binarization on the image of each test sample to obtain the preprocessed image; Step 4.2: Extract the contour point coordinate data (x, y, z) of the preprocessed image. i y i Based on the coordinates of N contour points, calculate parameters C, D, E, G, and H, and calculate parameters a and b based on C, D, E, G, and H. The calculation formulas for parameters C, D, E, G, and H are as follows: ; The formulas for calculating parameters a and b are as follows: ; Step 4.3: Based on parameters a and b, calculate the x-coordinate A and y-coordinate B of the center of the circle corresponding to each contour point. The x-coordinate A and y-coordinate B of the center of the circle are calculated using the following formulas: ; Step 4.4: Substitute each A and B into the contour circle equation to calculate the radius R of the N contour circles. i ; The radius R of the contour circle i The calculation formula is as follows: ; Step 4.5: Calculate the radius R of the N contour circles. i The average value is used as the inner diameter of the sample to be tested; Step 4.5: Calculate the radius R of the N contour circles. i The maximum and minimum values ​​are calculated, and the difference between the maximum and minimum values ​​is used as the roundness of the sample to be tested.

2. The method for combined detection of the inner diameter and roundness of the skeleton oil seal according to claim 1, characterized in that: It also includes step 5, Step 5: Display the inner diameter and roundness of the sample to be tested, and save it to the database.

3. The method for combined detection of the inner diameter and roundness of a skeleton oil seal according to claim 1 or 2, characterized in that: Step 1 includes: Step 1.1: Place the calibration plate and standard sample on the LED light source plate, turn on the LED light source and camera, and determine the appropriate camera Z-axis height based on the size of the standard sample in the camera's field of view; Step 1.2: Calculate the actual size corresponding to the width of each pixel in the image based on the ratio of the scale markings on the calibration plate to the number of pixels in the image. Calibrate the pixel width according to the size of the standard sample, establish the original coordinate system of the camera's field of view, and complete the calibration.

4. The method for combined detection of the inner diameter and roundness of a skeleton oil seal according to claim 1 or 2, characterized in that: Step 2 includes: Step 2.1: Place the multiple skeleton oil seals to be tested on the LED light source board, and take images using a camera with a determined Z-axis height. The images are processed by Canny edge detection, binarization, and Hough circle transform algorithm to calculate the center point position of each sample and convert it into coordinates in the original coordinate system of the camera's field of view.

5. The method for combined detection of the inner diameter and roundness of a skeleton oil seal according to claim 1 or 2, characterized in that: Step 3 includes: Step 3.1: Based on the coordinates of the center point of each sample under test in the original coordinate system of the camera's field of view, calculate the position of the camera's X-axis and Y-axis, and adjust them using the second and third motors so that the center point of the camera's field of view is moved above the center point of the sample under test, with the same height as the calibrated Z-axis height. Step 3.2: Move to the center point of all the test samples in sequence and take an image of each test sample.

6. A machine vision-based composite detection device for the inner diameter and roundness of a skeleton oil seal, characterized in that: An application to a machine vision-based composite detection system for the inner diameter and roundness of skeleton oil seals, wherein the composite detection system includes: a detection platform, a positioning and adjustment mechanism, and a data acquisition mechanism; The testing platform includes: an LED light source board, anchor bolts, and a positioning plate; the LED light source board is mounted on the positioning plate, and the positioning plate has anchor bolts at its four corners. The positioning and adjustment mechanism includes: a first lead screw, a second lead screw, a rear plate, a longitudinal rail, a first connecting plate, a slider, a second connecting plate, a transverse rail, a first motor, and a second motor. The positioning plate has a first lead screw and a second lead screw vertically arranged at both ends. A cover plate connects the tops of the first and second lead screws. The rear end of the cover plate is connected to the rear plate vertically arranged on the positioning plate. A first rail is arranged in front of the rear plate. A slider is movably arranged on the first rail. The first and second lead screws are movably connected to both ends of the first connecting plate. The rear side of the first connecting plate is connected to the slider, and the front side is connected to the rear side of the second connecting plate. A transverse rail is arranged on the top of the first connecting plate. A slot is cut into the top side of the second connecting plate, and a conveyor belt is arranged in the slot. A first motor is arranged on the cover plate, causing the slider to slide along the longitudinal rail. A second motor is arranged at one end of the second connecting plate, causing the conveyor belt in the slot to rotate. The acquisition mechanism includes: a slide table, a third connecting plate, a worm gear, a turbine, a third motor, a camera bracket, and a camera; one end of the slide table is movably connected to a transverse track, and the bottom of the slide table is connected to a conveyor belt on the second connecting plate; a third connecting plate is provided on the top of the slide table, the worm gear is built into a hole in the third connecting plate, and the front end of the worm gear is connected to the camera bracket; the camera is mounted on the camera bracket; a third motor is also provided on the top of the slide table, the third motor drives the turbine to rotate, and the turbine meshes with the rear end of the worm gear; The LED light source board is used to place the skeleton oil seal to be tested; It also includes a processing device for performing a machine vision-based composite detection method for the inner diameter and roundness of a skeleton oil seal. The composite detection device includes the following modules: Calibration module: Used to obtain the camera's Z-axis height using a calibration board and standard samples, and to establish the original coordinate system of the camera's field of view; Center point acquisition module: used to acquire images of all test samples taken by the camera at the Z-axis height, process the images containing all test samples, obtain the center point position of each test sample, and convert it into coordinates in the original coordinate system of the camera's field of view; Automatic positioning module: It is used to adjust the position of the camera on the positioning adjustment mechanism according to the coordinates of the center point of each test sample in the original coordinate system of the camera's field of view. After adjustment, it takes pictures of each test sample in sequence to obtain an image of each test sample. Data processing module: used to preprocess the image of each sample to be tested, extract the contour point coordinate data of the preprocessed image, and calculate the inner diameter and roundness of the sample to be tested based on the contour point coordinate data of the preprocessed image. The data processing module includes: Step 4.1: Perform adaptive Gauss filtering and binarization on the image of each test sample to obtain the preprocessed image; Step 4.2: Extract the contour point coordinate data (x, y, z) of the preprocessed image. i y i Based on the coordinates of N contour points, calculate parameters C, D, E, G, and H, and calculate parameters a and b based on C, D, E, G, and H. The calculation formulas for parameters C, D, E, G, and H are as follows: ; The formulas for calculating parameters a and b are as follows: ; Step 4.3: Based on parameters a and b, calculate the x-coordinate A and y-coordinate B of the center of the circle corresponding to each contour point. The x-coordinate A and y-coordinate B of the center of the circle are calculated using the following formulas: ; Step 4.4: Substitute each A and B into the contour circle equation to calculate the radius R of the N contour circles. i ; The radius R of the contour circle i The calculation formula is as follows: ; Step 4.5: Calculate the radius R of the N contour circles. i The average value is used as the inner diameter of the sample to be tested; Step 4.5: Calculate the radius R of the N contour circles. i The maximum and minimum values ​​are calculated, and the difference between the maximum and minimum values ​​is used as the roundness of the sample to be tested.

7. The machine vision-based composite detection device for the inner diameter and roundness of a skeleton oil seal according to claim 6, characterized in that: Also includes: Data Results Module Data Results Module: Used to display the inner diameter and roundness of the sample under test and save them to the database.

8. A computer-readable storage medium, characterized in that: It stores a computer program, which, when executed by a processor, implements the composite detection method for the inner diameter and roundness of the skeleton oil seal as described in any one of claims 1-5.

9. A computer device, comprising: Memory, used to store instructions; A processor is configured to execute the instructions, causing the computer device to perform the operation of the composite detection method for the inner diameter and roundness of the skeleton oil seal as described in any one of claims 1-5.

Citation Information

Patent Citations

  • Automatic fire point detection method, device and equipment and storage medium

    CN115272910A

  • Method and device for acquiring pose of target camera in annular shooting and electronic equipment

    CN115311360A

  • Efficient crankshaft oil seal press fitting detection equipment

    CN214816343U