Scanning structured light center contour extraction method suitable for non-uniform reflection object

By using a color camera and an auxiliary LED light source to set a nonlinear threshold to extract the center contour of structured light during scanning of unevenly reflective objects, the problems of incomplete contour extraction and noise interference in the existing technology are solved, and the efficiency of structured light scanning is improved. Integrity and reliability, adapted to the needs of the manufacturing industry.

CN118670301APending Publication Date: 2024-09-20SHANGHAI JIAOTONG UNIV
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410670377.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-28
Publication Date
2024-09-20

AI Technical Summary

Technical Problem

When dealing with non-uniform reflective objects in the existing technology, the extraction of the center contour of the structured light has problems of incompleteness or noise interference, resulting in low integrity and reliability of the measurement results. In addition, the existing improvement scheme has complex devices, high costs, and computational complexity. time increases, it is difficult to meet the needs of mass production in the manufacturing industry.

Method used

A color camera, a tilted structured laser source and an auxiliary LED light source are used to extract images through the RGB channel. The contour extraction threshold of the structured light image is set based on the average gray value of the LED light image. The nonlinear relationship is used to adjust the threshold to improve the extraction effect. , to avoid incomplete contour extraction or noise interference caused by a single threshold.

Benefits of technology

It effectively improves the integrity and reliability of structured light scanning results, reduces device complexity and cost, reduces calculation time, adapts to differences in light and dark caused by factors such as material differences and surface contamination, and improves the adaptability and adaptability of the detection system. Measurement accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118670301A
    Figure CN118670301A
Patent Text Reader

Abstract

The invention relates to a scanning structured light center contour extraction method suitable for a non-uniform reflection object, and the method comprises the steps: S1, arranging a color camera above a measured workpiece, obliquely arranging a structured laser source, and arranging an LED light source at one side of the structured laser source, s2, starting a structural laser source and an LED light source, and shooting to obtain a color image of the surface of the workpiece; s3, extracting an RGB channel of the color image; s4, dividing the image into different micro-regions, calculating an average gray value of the LED light image, and multiplying the average gray value by an adjustment coefficient to serve as a contour extraction threshold value; and S5, performing center contour extraction on each micro-region of the structured light image based on the contour extraction threshold, connecting the obtained micro-region contours, and performing morphological processing to obtain a contour extraction result. Compared with the prior art, the method has the advantages that the completeness and the anti-interference capability of part contour extraction are considered, and the like.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the technical field of part surface morphology reconstruction, and in particular to a scanning structured light center contour extraction method suitable for an object with uneven reflectivity. Background Art

[0002] The three-dimensional measurement of parts is a common demand in the manufacturing industry. Non-contact measurement based on structured light has the advantages of no wear, good flexibility, and high measurement accuracy. However, when the object being measured has uneven reflection, the brightness of the structured light in the image fluctuates greatly, which can easily lead to failure in extracting the center contour of too dark or too bright areas, and the height information of the corresponding area cannot be calculated, limiting subsequent analysis and judgment. This uneven reflection is related to the surface morphology, contaminants, and roughness of the object, and its impact on actual measurement cannot be ignored.

[0003] The search found that in order to improve the detection integrity of scanning structured light, some improvement strategies have been proposed in recent years: the paper "Viewpoint Planning for Structured Light Scanning of Complex Surface Parts" proposed a binocular scanning method based on grid surface structured light, and used the viewpoint quality evaluation function to select available viewpoints. This method improves the integrity of the detection point cloud by increasing the complexity of structured light and the number of cameras, and has achieved certain results, but the complexity of hardware and algorithms has greatly increased, and the cost and computational time limit its wide application. The paper "Three-dimensional Measurement System of Workpieces Based on Dual Structured Light Scanning" also improves the detection results by adding structured light incident at different angles. The reflection conditions of light from different incident directions are different, which helps to suppress the influence of reflection, but the two beams of structured light must be calibrated, the operation process is complicated, and mutual interference may occur during the measurement process, which increases the difficulty of image processing. The patent "A structured light three-dimensional scanning method for workpieces with high reflective surfaces" (publication number: CN113091647A) calculates several projected brightnesses based on the distribution of the surface reflectivity of the object being measured, and then fuses the images after shooting with stripes of different brightness. This method requires testing the surface emissivity of the object in advance and taking multiple pictures for fusion, which makes it difficult to implement.

[0004] It can be seen that there is currently a lack of effective means to reconstruct the surface morphology of complex reflective objects such as parts. The main methods are to increase the complexity of structured light or the number of cameras, or to fuse different lighting intensities and multiple imaging images. The proposed solutions are not only complex and costly, but also significantly increase the computational time, making it difficult to meet the needs of mass production in the manufacturing industry. In addition, the results of part extraction are prone to incomplete contour extraction or noise interference, and the integrity and reliability of structured light scanning results are not high. Summary of the invention

[0005] The purpose of the present invention is to set a suitable threshold based on the reflective state of the auxiliary light source to achieve both the integrity and anti-interference ability of part contour extraction and to provide a scanning structured light center contour extraction method suitable for objects with uneven reflectiveness.

[0006] The purpose of the present invention can be achieved by the following technical solutions:

[0007] A method for extracting the center contour of a scanning structured light suitable for an object with uneven reflectivity, the method comprising:

[0008] S1. Place a color camera above the workpiece to be measured, and tilt the structured laser source, calibrate the parameters, and arrange an LED light source at the same or similar angle on one side of the structured laser source. The difference between the wavelength of the structured light emitted by the structured laser source and the wavelength of the LED light emitted by the LED light source exceeds a certain threshold.

[0009] S2, start the structured laser source and the LED light source, and then trigger the camera to take pictures to obtain a color image of the workpiece surface;

[0010] S3, extracting the RGB channels of the color image, wherein among the three channels, the structured light has the highest brightness in one channel a, and the grayscale image in channel a is used as the structured light image, and the LED light has the highest brightness in channel b, and the grayscale image in channel b is used as the LED light image;

[0011] S4, dividing the structured light image and the LED light image into different micro-areas, calculating the average grayscale value of the LED light image in each micro-area of ​​the LED light image, and multiplying the average grayscale value of each micro-area by the adjustment coefficient as the contour extraction threshold of the micro-area corresponding to the structured light image;

[0012] S5. Extract the central contour of each micro-area of ​​the structured light image based on the contour extraction threshold, connect the obtained micro-area contours and perform morphological processing to obtain a contour extraction result.

[0013] Furthermore, there is a nonlinear relationship between the average gray value and the adjustment coefficient.

[0014] Furthermore, the expression for the nonlinear relationship between the average gray value and the adjustment coefficient is:

[0015]

[0016] Among them, x represents the average gray value, and f represents the adjustment coefficient.

[0017] Furthermore, the same or similar angle specifically means that the angle difference between the structural laser angle and the LED light source angle is within 10 degrees.

[0018] Furthermore, the micro-area is determined based on the uneven degree of reflection of the object and the time consumption of calculation.

[0019] Furthermore, the micro-region is set as a single pixel.

[0020] Furthermore, the channel a and channel b are different color channels.

[0021] Furthermore, the structured light is red laser, and the LED light is blue LED light.

[0022] Furthermore, the structured light is blue laser, and the LED light is red LED light.

[0023] Furthermore, there is an overlapping area between the illumination area of ​​the LED light and the structured light, and the LED light source is a strip light source.

[0024] Compared with the prior art, the present invention has the following beneficial effects:

[0025] The present invention sets a reasonable extraction threshold based on the reflective state of the auxiliary light source. The threshold is designed to be the average grayscale value of each micro-area multiplied by the adjustment coefficient. The reflective state of the workpiece surface is obtained by using LED light. Different contour extraction thresholds are set according to the difference in reflective state, which effectively avoids incomplete contour extraction or noise interference caused by a single threshold, and can take into account both the integrity and anti-interference ability of contour extraction. In addition, the present invention uses the RGB channel of the color camera to simultaneously acquire the LED light image and the structured light image, avoiding the increased cost and algorithm overhead caused by binocular camera shooting; it has good tolerance for the brightness difference of the structured light fringes caused by factors such as material differences, structural changes, and surface contamination, and effectively improves the integrity and reliability of the structured light scanning results. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] Figure 1 is a flow chart of the present invention;

[0027] Figure 2 is a grayscale image of the red LED light of the present invention;

[0028] Figure 3 is a grayscale image of the blue structured light of the present invention;

[0029] Figure 4 It is a schematic diagram of the micro-region threshold value of the present invention;

[0030] Figure 5 The structured light image and the center contour point coordinate image of the present invention;

[0031] Figure 6 It is a schematic diagram of the device of the present invention;

[0032] Figure 7is a graph showing the relationship between the adjustment parameters and the grayscale average value of the present invention;

[0033] In the figure, 1 is a structured light source, 2 is an LED light source, 3 is a color camera, 4 is a lens, and 5 is an object to be measured. DETAILED DESCRIPTION

[0034] The present invention is described in detail below in conjunction with the accompanying drawings and specific embodiments. This embodiment is implemented based on the technical solution of the present invention, and provides a detailed implementation method and specific operation process, but the protection scope of the present invention is not limited to the following embodiments.

[0035] The present invention proposes a method for extracting the center contour of a scanning structured light suitable for objects with uneven reflection. The causes of uneven reflection include complex morphology, heterogeneous materials, surface pollution, etc. Non-uniform reflection causes large fluctuations in the brightness of the structured light image, making it difficult to determine a suitable extraction threshold, which can easily lead to local loss of the center contour and data loss. The present invention uses an auxiliary LED light source with an angle similar to that of the structured laser. There is a significant difference in the wavelength of the auxiliary light source and the structured laser. The imaging is carried out in the same RGB color camera, and the auxiliary light image and the structured light image are separated by RGB channel extraction. By utilizing the similarity of the reflection conditions of the two light sources, the center extraction threshold of the structured light image is adjusted in different regions according to the brightness of the auxiliary light source image, which effectively improves the success rate of the structured light center point extraction and obtains relatively complete three-dimensional morphological data of the object surface.

[0036] The method of the present invention is simple in device and adds a reference LED light source on the basis of the traditional laser triangulation method. It does not require complex structured light and does not need to adjust the scanning path. It uses the similar reflective characteristics of the two light sources to achieve regional setting of the structured light extraction threshold. The minimum area can reach the pixel level, which can effectively improve the adaptability of the detection system and has high measurement accuracy and good stability. It has good application prospects in the field of three-dimensional shape detection of objects.

[0037] The flow chart of the method of the present invention is as follows Figure 1 As shown, the present invention comprises the following steps:

[0038] S1. Place a color camera above the workpiece to be measured, and tilt the structured laser source, calibrate the parameters, and arrange an LED light source at the same or similar angle on one side of the structured laser source. The difference between the wavelength of the structured light emitted by the structured laser source and the wavelength of the LED light emitted by the LED light source exceeds a certain threshold.

[0039] S2, start the structured laser source and the LED light source, and then trigger the camera to take pictures to obtain a color image of the workpiece surface;

[0040] S3, extracting the RGB channels of the color image, wherein among the three channels, the structured light has the highest brightness in one channel a, and the grayscale image in channel a is used as the structured light image, and the LED light has the highest brightness in channel b, and the grayscale image in channel b is used as the LED light image;

[0041] S4, dividing the structured light image and the LED light image into different micro-areas, calculating the average grayscale value of the LED light image in each micro-area of ​​the LED light image, and multiplying the average grayscale value of each micro-area by the adjustment coefficient as the contour extraction threshold of the micro-area corresponding to the structured light image;

[0042] S5. Extract the central contour of each micro-area of ​​the structured light image based on the contour extraction threshold, connect the obtained micro-area contours and perform morphological processing to obtain a contour extraction result.

[0043] In S1 of the present invention, a device for contour extraction is provided, the device being as follows: Figure 6 As shown. The device includes: a structured light source 1, an LED light source 2, a color camera 3, a lens 4 and an object to be measured 5. The structured laser is placed at an angle, and the spatial position relationship between the camera and the structured laser remains unchanged. The relevant parameters are obtained after calibration; an LED light source with the same or similar angle is arranged near the structured laser. The wavelength difference between the laser and the LED light source needs to be large. The LED light source is arranged near the structured light. The LED light source can be located in front of or behind the structured light. The angle of the LED light source is the same or similar to that of the structured laser (with a deviation within 10 degrees), and it is ensured that the LED light illumination area and the laser have an overlap area; the LED light source adopts a bar shape, and a divergence angle of no more than 15 degrees is allowed. The wavelengths of the LED light source and the structured laser are both in the visible light range. The wavelength of the LED light source should be significantly different from that of the structured laser. A blue laser can be matched with a red LED light source, or a red laser can be matched with a blue LED light source. The color camera is started after the two light sources are lit. During scanning, the LED light source and the structured light are triggered synchronously, that is, both light sources are lit when the camera is shooting.

[0044] The color image obtained by the camera is divided into RGB channels, and the grayscale images of the color channels of the structured light and LED light are extracted respectively. The two grayscale images are divided into micro-areas using the same division method. The size of the micro-area can be set according to the surface state of the object and the calculation time. The minimum micro-area size can be a single pixel, and the micro-area usually covers the entire image. In the obtained RGB image, the structured laser and LED light are located in different color channels respectively. The set LED light source does not affect the positional relationship between the camera and the structured laser, and the set LED light source does not participate in the calibration. After extracting the central contour of the structured laser, the calibration parameters obtained in step 1 can be used to calculate the three-dimensional morphology of the object surface.

[0045] In S4, micro-area division refers to the image segmentation window. The micro-area division of the structured laser grayscale image and the LED light grayscale image is exactly the same. The average grayscale of the LED light image is calculated in the micro-area, and after coefficient adjustment, it is used as the extraction threshold of the corresponding micro-area of ​​the structured light image, that is, the micro-area is the basic unit for threshold setting, and the threshold of each pixel in the micro-area is the same; the micro-area size setting can be selected according to the uneven degree of reflection of the object, the calculation time, etc., and the minimum size of the micro-area is a single pixel.

[0046] The adjustment coefficient is the conversion relationship between the LED light grayscale image and the structural laser image; since the incident angles of the two light sources are roughly the same, the degree of reflection at the same position of the object is similar, and there is a certain correlation between the light and dark fluctuations of the two images; in the same micro-area, the average grayscale value of the LED light image is calculated. The higher the grayscale value, the stronger the reflection of the micro-area, and the lower the grayscale value, the weaker the reflection of the micro-area; in the strong reflection area, the threshold of laser contour extraction is higher, and in the weak reflection area, the threshold of laser contour extraction is lower. The adjustment coefficient has a nonlinear correlation with the average grayscale value of the LED light image, and can be set using a piecewise function based on expert experience, that is, it can be set manually by experts based on the brightness difference of the two light sources, or it can be determined using machine learning methods.

[0047] In the present invention, the value of the adjustment coefficient is generally between 0 and 3, and a larger coefficient value is used in a region with a lower grayscale value; as the grayscale value increases, the coefficient gradually decreases; when the grayscale value increases to close to 255, in order to avoid environmental interference, the coefficient is appropriately increased. The relationship between the adjustment coefficient and the grayscale value obtained by specific fitting is:

[0048]

[0049] The mapping curve is set with gray value as the horizontal axis and coefficient as the vertical axis. It is preset in the algorithm program. When processing the image, the coefficient can be read according to the measured gray value. For different test environments, the curve morphology is slightly different. The relationship between the adjustment parameter and the gray average value is shown in the figure below. Figure 4 shown.

[0050] In S4, the central contour is extracted in each micro-area of ​​the structured light grayscale image, and the threshold is the grayscale mean of the LED image × the adjustment coefficient; after the micro-area contour extraction is completed, the contours are connected and morphological processing is performed.

[0051] Compared with the prior art, the method of the present invention has the following beneficial effects: the present invention utilizes LED light to obtain the reflective state of the workpiece surface, sets different contour extraction thresholds according to the difference in reflective state, and effectively avoids incomplete contour extraction or noise interference caused by a single threshold; utilizes the RGB channel of a color camera to simultaneously acquire LED light images and structured light images, and avoids the increased cost and algorithm overhead caused by binocular camera shooting; has good tolerance for the brightness difference of structured light stripes caused by factors such as material differences, structural changes, and surface contamination, and effectively improves the integrity and reliability of structured light scanning results.

[0052] In the actual experiment, the object to be tested is a pure copper metal part. There are small planes and concave areas in different directions on the surface of the part, and the reflection difference is large. The color camera is located directly above the workpiece. The spatial position of the structured light and the camera is calibrated. The three-dimensional morphology of the workpiece surface can be calculated through the center contour of the structured light. Blue structured light and strip red LED light are used for illumination, and the incident angle of the two light sources is 50 degrees.

[0053] The grayscale image of the red LED light obtained in the experiment is as follows: Figure 2 As shown, the grayscale image of the blue structured light is as follows Figure 3 The brightness of the structured light stripes is inconsistent, and there is noise interference around the local stripes. The method proposed in this invention is used to extract the contour, and the schematic diagram of the micro-area threshold is shown in Figure 7 The obtained structured light image and the coordinates of the center contour point are shown as Figure 5 As shown, it can be seen that the structured light contour is complete, and neither high reflection nor low reflection causes the loss of contour points.

[0054] The preferred specific embodiments of the present invention are described in detail above. It should be understood that a person skilled in the art can make many modifications and changes based on the concept of the present invention without creative work. Therefore, any technical solution that can be obtained by a person skilled in the art through logical analysis, reasoning or limited experiments based on the concept of the present invention on the basis of the prior art should be within the scope of protection determined by the claims.

Claims

1. A method for extracting the center contour of a scanning structured light suitable for an object with uneven reflectivity, characterized in that: Methods include: S1. Place a color camera above the workpiece to be measured, and tilt the structured laser source, calibrate the parameters, and arrange an LED light source at the same or similar angle on one side of the structured laser source. The difference between the wavelength of the structured light emitted by the structured laser source and the wavelength of the LED light emitted by the LED light source exceeds a certain threshold. S2, start the structured laser source and the LED light source, and then trigger the camera to shoot, and obtain a color image of the workpiece surface; S3, extracting the RGB channels of the color image, wherein among the three channels, the structured light has the highest brightness in one channel a, and the grayscale image in channel a is used as the structured light image, and the LED light has the highest brightness in channel b, and the grayscale image in channel b is used as the LED light image; S4, dividing the structured light image and the LED light image into different micro-areas, calculating the average grayscale value of the LED light image in each micro-area of ​​the LED light image, and multiplying the average grayscale value of each micro-area by the adjustment coefficient as the contour extraction threshold of the micro-area corresponding to the structured light image; S5. Extract the central contour of each micro-area of ​​the structured light image based on the contour extraction threshold, connect the obtained micro-area contours and perform morphological processing to obtain a contour extraction result.

2. The method for extracting the center contour of a scanning structured light suitable for an object with uneven reflectivity according to claim 1, characterized in that: There is a nonlinear relationship between the average gray value and the adjustment coefficient.

3. The method for extracting the center contour of scanning structured light suitable for objects with uneven reflectivity according to claim 2, characterized in that: The expression for the nonlinear relationship between the average gray value and the adjustment coefficient is: Among them, x represents the average gray value, and f represents the adjustment coefficient.

4. The method for extracting the center contour of scanning structured light applicable to an object with uneven reflectivity according to claim 1, characterized in that: The same or similar angle specifically means that the angle difference between the structural laser angle and the LED light source angle is within 10 degrees.

5. The method for extracting the center contour of scanning structured light applicable to an object with uneven reflectivity according to claim 1, characterized in that: The micro-area is determined based on the unevenness of the object's reflection and the time consumption of calculation.

6. The method for extracting the center contour of scanning structured light applicable to an object with uneven reflectivity according to claim 5, characterized in that: The micro-region is set as a single pixel.

7. The method for extracting the center contour of scanning structured light applicable to an object with uneven reflectivity according to claim 1, characterized in that: The channel a and channel b are different color channels.

8. The method for extracting the center contour of scanning structured light applicable to an object with uneven reflectivity according to claim 7, characterized in that: The structured light is red laser and the LED light is blue LED light.

9. The method for extracting the center contour of scanning structured light applicable to an object with uneven reflectivity according to claim 7, characterized in that: The structured light is blue laser and the LED light is red LED light.

10. The method for extracting the center contour of scanning structured light applicable to an object with uneven reflectivity according to claim 1, characterized in that: There is an overlap area between the illumination area of ​​the LED light and the structured light, and the LED light source is a strip light source.

Citation Information

Cited By

  • Complex surface structured light contour extraction method, electronic equipment and storage medium

    CN119516210A