Scanning Control Method, Scanning Control Device, Scanning Control System, and Storage Medium

By using a light source projection module in a three-dimensional scanning device to project light of different wavelengths and calibrate the image acquisition component, the problem that long-wavelength light is susceptible to environmental interference is solved, and the three-dimensional reconstruction accuracy is improved.

CN119496857BActive Publication Date: 2025-05-27SCANTECH (HANGZHOU) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510045103.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-01-10
Publication Date
2025-05-27
Estimated Expiration
2045-01-10

AI Technical Summary

Technical Problem

Long-wavelength light is susceptible to natural environment interference, affecting the accuracy of three-dimensional reconstruction.

Method used

By using a light source projection module in a three-dimensional scanning device to project the first and second light rays and obtain calibration images based on these light rays, calibration of the internal parameter matrix and distortion parameters of the image acquisition component is performed.

Benefits of technology

The calibration accuracy of the image acquisition component under long wavelength light conditions is improved, and the three-dimensional reconstruction accuracy of the three-dimensional scanning equipment is ensured.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119496857B_ABST
    Figure CN119496857B_ABST
Patent Text Reader

Abstract

The present application discloses a scanning control method, a scanning control device, a scanning control system, and a computer-readable storage medium, belonging to the technical field of three-dimensional scanning. The scanning control method according to the embodiments of the present application is applied to a three-dimensional scanning device. The scanning control method includes: obtaining a first calibration image corresponding to a first light ray based on a light source projection module and an image acquisition component; obtaining a second calibration image corresponding to a second light ray based on the light source projection module and the image acquisition component; performing a first calibration on the image acquisition component based on the first calibration image to determine a first internal parameter matrix and a first distortion parameter of the image acquisition component; performing a second calibration on the image acquisition component based on the first internal parameter matrix, the first distortion parameter, and the second calibration image to determine a second internal parameter matrix and a second distortion parameter of the image acquisition component. In this way, the calibration accuracy of the image acquisition component under long-wavelength light ray conditions is improved, and the three-dimensional reconstruction accuracy of the three-dimensional scanning device is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of three-dimensional scanning technology, and particularly relates to a scanning control method, a scanning control device, a scanning control system, and a computer-readable storage medium. Background Art

[0002] A three-dimensional scanning device is a device that can capture the shape and appearance of an object or scene in the real world and reconstruct it into a digital three-dimensional model, and has a wide range of applications in multiple fields, such as manufacturing, architecture, medical treatment, cultural heritage protection, and animation production. Currently, for a three-dimensional scanning device that uses long-wavelength light (such as infrared laser, etc.) for scanning, the long-wavelength light is easily interfered by the natural environment, which has an adverse impact on three-dimensional reconstruction. Summary of the Invention

[0003] Embodiments of the present application provide a scanning control method, a scanning control device, a scanning control system, and a computer-readable storage medium to solve at least one of the above-mentioned technical problems.

[0004] The scanning control method of the embodiments of the present application is applied to a three-dimensional scanning device, the three-dimensional scanning device includes an image acquisition component and a light source projection module, the light source projection module is used to project a first light ray and a second light ray, and the wavelength of the first light ray is less than the wavelength of the second light ray. The scanning control method includes:

[0005] Obtaining a first calibration image corresponding to the first light ray based on the light source projection module and the image acquisition component;

[0006] Obtaining a second calibration image corresponding to the second light ray based on the light source projection module and the image acquisition component;

[0007] Performing a first calibration on the image acquisition component based on the first calibration image to determine a first internal parameter matrix and first distortion parameters of the image acquisition component;

[0008] Performing a second calibration on the image acquisition component based on the first internal parameter matrix, the first distortion parameters, and the second calibration image to determine a second internal parameter matrix and second distortion parameters of the image acquisition component.

[0009] In some embodiments, the obtaining a first calibration image corresponding to the first light ray based on the light source projection module and the image acquisition component includes:

[0010] Controlling the light source projection module to project the first light ray onto a first calibration board located at a first predetermined distance;

[0011] Performing image acquisition on the first calibration board through the image acquisition component to obtain the first calibration image.

[0012] In some embodiments, obtaining a second calibration image corresponding to the second light ray based on the light source projection module and the image acquisition component includes:

[0013] Controlling the light source projection module to project the second light ray onto a second calibration plate located at a second predetermined distance;

[0014] Performing image acquisition on the second calibration plate through the image acquisition component to obtain the second calibration image;

[0015] Wherein, the second predetermined distance is greater than the first predetermined distance.

[0016] In some embodiments, second calibrating the image acquisition component based on the first internal parameter matrix, the first distortion parameter, and the second calibration image to determine a second internal parameter matrix and a second distortion parameter of the image acquisition component includes:

[0017] Calculating an iterative internal parameter matrix according to the first internal parameter matrix, the first distortion parameter, and the second calibration image;

[0018] Calculating an iterative distortion parameter according to the iterative internal parameter matrix and the second calibration image;

[0019] Performing iterative calculation on the iterative internal parameter matrix and the iterative distortion parameter to obtain a second internal parameter matrix and a second distortion parameter.

[0020] In some embodiments, performing iterative calculation on the iterative internal parameter matrix and the iterative distortion parameter to obtain a second internal parameter matrix and a second distortion parameter includes:

[0021] Iteratively updating the iterative internal parameter matrix according to the iterative distortion parameter, the first internal parameter matrix, and the second calibration image;

[0022] Iteratively updating the iterative distortion parameter according to the iterative internal parameter matrix and the second calibration image, and returning to the step of iteratively updating the iterative internal parameter matrix according to the iterative distortion parameter, the first internal parameter matrix, and the second calibration image;

[0023] When a preset condition is reached, stop iteratively updating the iterative internal parameter matrix and the iterative distortion parameter;

[0024] Determining the second internal parameter matrix according to the iterative internal parameter matrix of the last iteration, and determining the second distortion parameter according to the iterative distortion parameter of the last iteration.

[0025] In some embodiments, the scanning control method further includes:

[0026] Based on the light source projection module and the image acquisition component after the first calibration, scan a first object to be scanned at a first scanning distance, and detect a target area corresponding to the first object to be scanned in each frame of image;

[0027] Based on the light source projection module and the image acquisition component after the second calibration, scan a second object to be scanned at a second scanning distance, and detect a target area corresponding to the second object to be scanned in each frame of image;

[0028] Wherein, the second scanning distance is greater than the first scanning distance.

[0029] In some embodiments, the image acquisition component includes an image sensor, and the scanning control method further includes:

[0030] During the process of scanning the first object to be scanned at the first scanning distance based on the light source projection module and the image acquisition component after the first calibration, and detecting the target area corresponding to the first object to be scanned in each frame of image, control the brightness of the first light projected by the light source projection module to be a first brightness, and control the exposure time of the image sensor to be a first exposure time;

[0031] During the process of scanning the second object to be scanned at the second scanning distance based on the light source projection module and the image acquisition component after the second calibration, and detecting the target area corresponding to the second object to be scanned in each frame of image, control the brightness of the second light projected by the light source projection module to be a second brightness, and control the exposure time of the image sensor to be a second exposure time;

[0032] Wherein, the second brightness is greater than the first brightness, and the second exposure time is less than the first exposure time.

[0033] In some embodiments, the process of scanning the second object to be scanned at the second scanning distance based on the light source projection module and the image acquisition component after the second calibration, and detecting the target area corresponding to the second object to be scanned in each frame of image, includes:

[0034] Control the light source projection module to project the second light to the second object to be scanned at the second scanning distance;

[0035] Acquire multiple frames of images to be processed by performing image acquisition on the second object to be scanned through the image acquisition component after the second calibration;

[0036] Extract and match the target region from multiple frames of the to-be-processed images to obtain the target region corresponding to the second object to be scanned.

[0037] In some embodiments, the extracting and matching the target region from multiple frames of the to-be-processed images to obtain the target region corresponding to the second object to be scanned includes:

[0038] Set a first mask region according to the target region extracted and matched from the previous frame of the to-be-processed image;

[0039] Determine a second mask region of the current frame of the to-be-processed image according to the first mask region;

[0040] Set a judgment threshold for the current frame of the to-be-processed image according to the second mask region;

[0041] Extract and match the target region from the current frame of the to-be-processed image according to the judgment threshold to obtain the target region corresponding to the second object to be scanned.

[0042] In some embodiments, the determining the second mask region of the current frame of the to-be-processed image according to the first mask region includes:

[0043] Determine the diffusion ratio of the first mask region according to the acquisition frame rate of the image acquisition component;

[0044] Perform diffusion processing on the first mask region according to the diffusion ratio to obtain a diffusion region;

[0045] Determine the second mask region in the current frame of the to-be-processed image according to the diffusion region.

[0046] In some embodiments, the setting the judgment threshold for the current frame of the to-be-processed image according to the second mask region includes:

[0047] For the region corresponding to the second mask region in the current frame of the to-be-processed image, set the judgment threshold to a first judgment threshold;

[0048] For the region outside the second mask region in the current frame of the to-be-processed image, set the judgment threshold to a second judgment threshold;

[0049] Wherein, the second judgment threshold is greater than the first judgment threshold.

[0050] The scanning control device according to the embodiments of the present application is applied to a three-dimensional scanning device, which includes an image acquisition component and a light source projection module. The light source projection module is used to project a first light ray and a second light ray, and the wavelength of the first light ray is less than that of the second light ray. The scanning control device includes:

[0051] A first acquisition module, configured to acquire a first calibration image corresponding to the first light ray based on the light source projection module and the image acquisition component;

[0052] A second acquisition module, configured to acquire a second calibration image corresponding to the second light ray based on the light source projection module and the image acquisition component;

[0053] A first calibration module, configured to perform a first calibration on the image acquisition component based on the first calibration image, and determine a first internal parameter matrix and first distortion parameters of the image acquisition component;

[0054] A second calibration module, configured to perform a second calibration on the image acquisition component based on the first internal parameter matrix, the first distortion parameters, and the second calibration image, and determine a second internal parameter matrix and second distortion parameters of the image acquisition component.

[0055] The scanning control system according to the embodiments of the present application, the scanning control system includes one or more processors and a memory, and the memory stores a computer program. When the computer program is executed by the processor, the scanning control method according to any of the above embodiments is implemented.

[0056] The computer-readable storage medium according to the embodiments of the present application, on which a computer program is stored. When the program is executed by a processor, the scanning control method according to any of the above embodiments is implemented.

[0057] In the scanning control method, scanning control device, scanning control system, and computer-readable storage medium according to the embodiments of the present application, a first calibration is performed on the image acquisition component based on the first calibration image to obtain a relatively accurate first internal parameter matrix and first distortion parameters, and then a second calibration is performed on the image acquisition component with reference to the first internal parameter matrix and first distortion parameters to determine the second internal parameter matrix and second distortion parameters corresponding to the second light ray of the image acquisition component. In this way, the calibration accuracy of the image acquisition component under long-wavelength light conditions is improved, and the three-dimensional reconstruction accuracy of the three-dimensional scanning device is ensured.

[0058] The additional aspects and advantages of the embodiments of the present application will be partially given in the following description, partially become obvious from the following description, or be understood through the practice of the embodiments of the present application. Description of the Drawings

[0059] The above and / or additional aspects and advantages of the present application will become apparent and be readily understood from the description of the embodiments in conjunction with the following drawings, wherein:

[0060] Figure 1 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0061] Figure 2 is a schematic diagram of modules of a three-dimensional scanning device according to some embodiments of the present application;

[0062] Figure 3 is a schematic diagram of modules of an image acquisition component according to some embodiments of the present application;

[0063] Figure 4 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0064] Figure 5 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0065] Figure 6 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0066] Figure 7 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0067] Figure 8 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0068] Figure 9 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0069] Figure 10 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0070] Figure 11 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0071] Figure 12 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0072] Figure 13 is a schematic flowchart of a scanning control method according to some embodiments of the present application;

[0073] Figure 14 is a schematic diagram of modules of a scanning control device according to some embodiments of the present application;

[0074] Figure 15 is a schematic diagram of modules of a scanning control device according to some embodiments of the present application;

[0075] Figure 16 is a schematic diagram of modules of a scanning control system according to some embodiments of the present application;

[0076] Figure 17 is a schematic diagram of the connection state between a computer-readable storage medium and a processor according to some embodiments of the present application. Specific Embodiments

[0077] The following further describes the embodiments of the present application with reference to the accompanying drawings. The same or similar reference numerals in the drawings denote the same or similar elements or elements having the same or similar functions throughout. In addition, the embodiments of the present application described below with reference to the accompanying drawings are exemplary and are only used to explain the embodiments of the present application, and should not be construed as a limitation to the present application.

[0078] Please refer to Figures 1 to 3 , an embodiment of the present application provides a scanning control method, which is applied to a three-dimensional scanning device 100. The three-dimensional scanning device 100 includes an image acquisition component 10 and a light source projection module 20. The light source projection module 20 is used to project a first light ray and a second light ray, and the wavelength of the first light ray is less than the wavelength of the second light ray. The scanning control method includes:

[0079] 010: Obtain a first calibration image corresponding to the first light ray based on the light source projection module 20 and the image acquisition component 10;

[0080] 020: Obtain a second calibration image corresponding to the second light ray based on the light source projection module 20 and the image acquisition component 10;

[0081] 030: Perform a first calibration on the image acquisition component 10 based on the first calibration image to determine a first internal parameter matrix and first distortion parameters of the image acquisition component 10;

[0082] 040: Perform a second calibration on the image acquisition component 10 based on the first internal parameter matrix, the first distortion parameters, and the second calibration image to determine a second internal parameter matrix and second distortion parameters of the image acquisition component 10.

[0083] In the scanning control method of the embodiment of the present application, a first calibration is performed on the image acquisition component 10 based on the first calibration image to obtain a first internal parameter matrix and first distortion parameters with relatively high accuracy, and then a second calibration is performed on the image acquisition component 10 with reference to the first internal parameter matrix and the first distortion parameters to determine a second internal parameter matrix and second distortion parameters of the image acquisition component 10 corresponding to the second light ray. In this way, the calibration accuracy of the image acquisition component 10 under the condition of long-wavelength light rays is improved, and the three-dimensional reconstruction accuracy of the three-dimensional scanning device 100 is ensured.

[0084] Specifically, the image acquisition component 10 includes a lens 11. Calibrating the image acquisition component 10 is equivalent to calibrating the lens 11. The image acquisition component 10 is used to acquire images. The 3D scanning device 100 may include one or more image acquisition components 10. For example, when the 3D scanning device 100 performs ranging based on the Time of Flight (TOF) method, the 3D scanning device 100 may include one image acquisition component 10; when the 3D scanning device 100 performs ranging based on the triangulation method, the 3D scanning device 100 may include two image acquisition components 10.

[0085] The light source projection module 20 is used to project a first light ray and a second light ray. The light source projection module 20 may include only one projection unit for projecting both the first light ray and the second light ray. Alternatively, the light source projection module 20 may include a first projection unit and a second projection unit. The first projection unit is used to project the first light ray, and the second projection unit is used to project the second light ray.

[0086] The first light ray and the second light ray may be lasers or any other light rays that can be used for 3D scanning. The wavelength of the first light ray is less than the wavelength of the second light ray. In one example, the first light ray is a blue laser or a laser with a wavelength less than that of blue light, and the second light ray is a red laser or a laser with a wavelength greater than that of red light. In the embodiments of the present application, the first light ray is taken as a blue laser and the second light ray is taken as an infrared laser for illustration.

[0087] Based on the light source projection module 20 and the image acquisition component 10, a first calibration image corresponding to the first light ray and a second calibration image corresponding to the second light ray are obtained. Based on the first calibration image, any calibration algorithm can be used to perform the first calibration on the image acquisition component 10, and the first internal parameter matrix and the first distortion parameter corresponding to the first light ray of the image acquisition component 10 can be determined. The calibration algorithm is, for example, the Zhang Zhengyou calibration method.

[0088] After that, based on the first internal parameter matrix, the first distortion parameter, and the second calibration image, the second calibration of the image acquisition component 10 can be performed to determine the second internal parameter matrix and the second distortion parameter corresponding to the second light ray of the image acquisition component 10.

[0089] The internal parameter matrix is shown as follows:

[0090]

[0091] where 、 、 、 are the internal parameters to be solved.

[0092] For the distortion parameters, any representation form can be adopted. For example, in the open source computer vision library (OpenCV), the distortion parameters include k1, k2, k3, p1, and p2, where k1, k2, and k3 are radial distortion parameters, and p1 and p2 are tangential distortion parameters. Alternatively, in other representation forms, the distortion parameters include k1, k2, k3, k4, k5, k6, p1, p2, b1, and b2, where k4, k5, and k6 are higher-order radial distortion parameters, and b1 and b2 are thin prism distortion coefficients.

[0093] It should be noted that when the three-dimensional scanning device 100 includes an image acquisition component 10, after the first calibration and the second calibration are performed on the image acquisition component 10, the three-dimensional scanning device 100 can perform subsequent scanning and three-dimensional reconstruction operations. When the three-dimensional scanning device 100 includes two image acquisition components 10, the first calibration and the second calibration need to be performed on each image acquisition component 10 respectively. After the two image acquisition components 10 are respectively calibrated, binocular calibration is performed on the two image acquisition components 10 to obtain parameters such as the external parameter matrix and the baseline distance between the two image acquisition components 10, and then subsequent scanning and three-dimensional reconstruction operations are performed.

[0094] It can be understood that for the three-dimensional reconstruction algorithm, accurately calibrating the image acquisition component 10 is a prerequisite for high-precision reconstruction. It has been found through research that compared with short-wavelength light, long-wavelength light has less concentrated energy and is more susceptible to interference from the natural environment; compared with the first calibration image corresponding to the second light, the second calibration image corresponding to the second light has more noise. If the second calibration is directly performed on the image acquisition component 10 based on the second calibration image, the accuracy of the obtained second internal parameter matrix and second distortion parameters is poor.

[0095] In the embodiment of the present application, first, the first calibration is performed on the image acquisition component 10 based on the first calibration image to obtain a first internal parameter matrix and first distortion parameters with higher accuracy. Then, based on the first internal parameter matrix, the first distortion parameters, and the second calibration image, the second calibration is performed on the image acquisition component 10, that is, referring to the first calibration result of the image acquisition component 10, the second calibration result corresponding to the image acquisition component 10 and the second light is calculated. In this way, an accurate second internal parameter matrix and second distortion parameters can be calculated, ensuring the three-dimensional reconstruction accuracy of the three-dimensional scanning device 100.

[0096] Please refer to Figure 2 and Figure 4 , in some embodiments, obtaining the first calibration image (i.e., 010) corresponding to the first light based on the light source projection module 20 and the image acquisition component 10 includes:

[0097] 011: Control the light source projection module 20 to project the first light ray onto the first calibration board located at the first predetermined distance;

[0098] 012: Use the image acquisition component 10 to perform image acquisition on the first calibration board to obtain the first calibration image.

[0099] Specifically, the first calibration board can be any calibration board without limitation here. For example, the first calibration board can be a checkerboard calibration board, a circular grid calibration board, etc. The distance between the first calibration board and the image acquisition component 10 is the first predetermined distance. In one example, the first predetermined distance is less than 400 mm, and the first predetermined distance can be 100 mm, 150 mm, 200 mm, 250 mm, 300 mm, or any value less than 400 mm. The first predetermined distance can be specifically determined according to the wavelength of the first light ray to ensure the clarity of the first calibration image.

[0100] Control the light source projection module 20 to project the first light ray onto the first calibration board located at the first predetermined distance, and use the image acquisition component 10 to perform image acquisition on the first calibration board, then the first calibration image can be obtained. The number of the first calibration images is multiple. Based on the multiple first calibration images, use any calibration algorithm to perform the first calibration on the image acquisition component 10, and the first internal parameter matrix and the first distortion parameter of the image acquisition component 10 can be determined.

[0101] It can be understood that the acquisition distance of the first calibration image is relatively close, the noise of the first calibration board in the first calibration image is small, the repeatability is good, the calibration accuracy is high, and the accuracy of the first internal parameter matrix and the first distortion parameter obtained by calibration is high.

[0102] Please refer to Figure 2 and Figure 5 , in some embodiments, obtaining the second calibration image (i.e., 020) corresponding to the second light ray based on the light source projection module 20 and the image acquisition component 10 includes:

[0103] 021: Control the light source projection module 20 to project the second light ray onto the second calibration board located at the second predetermined distance;

[0104] 022: Use the image acquisition component 10 to perform image acquisition on the second calibration board to obtain the second calibration image;

[0105] Among them, the second predetermined distance is greater than the first predetermined distance.

[0106] Specifically, the second calibration board can be any calibration board, which is not limited here. For example, the first calibration board can be a checkerboard calibration board, a circular grid calibration board, etc. The first calibration board can be the same as or different from the first calibration board. The distance between the second calibration board and the image acquisition component 10 is the second predetermined distance, and the second predetermined distance is greater than the first predetermined distance. In one example, the second predetermined distance is greater than 600 mm, and the second predetermined distance can be 650 mm, 700 mm, 750 mm, 800 mm or any value greater than 600 mm. The second predetermined distance can be specifically determined according to the wavelength of the second light to ensure the clarity of the second calibration image.

[0107] Control the light source projection module 20 to project the second light onto the second calibration board located at the second predetermined distance, and perform image acquisition on the second calibration board through the image acquisition component 10, then the second calibration image can be obtained. The number of the second calibration images is multiple.

[0108] It should be noted that the wavelength of the first light is greater than the wavelength of the second light. For the same image acquisition component 10, the longer the wavelength, the farther the focus. The first light is more suitable for the scanning condition at a relatively short distance, and the second light is more suitable for the scanning condition at a relatively long distance.

[0109] It can be understood that the calibration of the image acquisition component 10 should coincide with the distance range during actual use to ensure that the image acquisition component 10 accurately captures and records image information within a certain distance range. That is to say, when the image acquisition component 10 performs scanning under the condition of the first light, close-range calibration is required, and when the image acquisition component 10 performs scanning under the condition of the second light, long-range calibration is required. The above first calibration is also the close-range calibration, and the second calibration is also the long-range calibration.

[0110] Therefore, based on the image acquisition component 10 and the light source projection module 20, image acquisition is performed on the first calibration board located at the first predetermined distance, and based on the image acquisition component 10 and the light source projection module 20, image acquisition is performed on the second calibration board located at the second predetermined distance, and the second predetermined distance is greater than the first predetermined distance. The value range of the first predetermined distance is also the range of close-range calibration, and the value range of the second predetermined distance is also the range of long-range calibration.

[0111] Please refer to Figure 2 and Figure 6 , in some embodiments, based on the first internal parameter matrix, the first distortion parameter and the second calibration image, the second calibration of the image acquisition component 10 is performed to determine the second internal parameter matrix and the second distortion parameter (i.e., 040) of the image acquisition component 10, including:

[0112] 041: Calculate the iterative internal parameter matrix according to the first internal parameter matrix, the first distortion parameter and the second calibration image;

[0113] 042: Calculate the iterative distortion parameters based on the iterative intrinsic matrix and the second calibration image;

[0114] 043: Perform iterative calculations on the iterative intrinsic matrix and the iterative distortion parameters to obtain the second intrinsic matrix and the second distortion parameters.

[0115] Specifically, when the image acquisition component 10 performs the second calibration, it acquires an image of the second calibration board located at the second predetermined distance to obtain the second calibration image. At this time, the noise of the second calibration board in the second calibration image is relatively large, and the repeatability of the multiple acquired second calibration images is poor. That is, the features of the same second calibration board in multiple second calibration images are different, resulting in poor calibration accuracy.

[0116] Therefore, the second calibration of the image acquisition component 10 is performed based on the first calibration result of the image acquisition component 10. To , , , represent the intrinsic parameters to be solved in the first intrinsic matrix, and to , , , represent the intrinsic parameters to be solved in the second intrinsic matrix. Since both the first calibration and the second calibration are performed on the same lens 11 of the same image acquisition component 10, the intrinsic parameters , in the first intrinsic matrix and the intrinsic parameters , in the second intrinsic matrix satisfy the following relational expressions:

[0117]

[0118] When calculating the second intrinsic matrix and the second distortion parameters, use the first distortion parameter as the initial value of the second distortion parameter, and calculate the second intrinsic matrix based on the first distortion parameter and the second calibration image. During the calculation process, use the ratio of the intrinsic parameters , to constrain the intrinsic parameters , , so that the calculated intrinsic parameters , satisfy , calculate the intrinsic parameters , , , to determine the corresponding iterative intrinsic matrix. At this time, there is a large error in the iterative intrinsic matrix, and iteration is still required to determine the second intrinsic matrix.

[0119] After determining the iterative intrinsic parameter matrix, based on the iterative intrinsic parameter matrix, the iterative distortion parameters are calculated in combination with the second calibration image. At this time, there are also large errors in the iterative distortion parameters, and iteration is also required to determine the second distortion parameters. By performing iterative calculations on the iterative intrinsic parameter matrix and the iterative distortion parameters, the second intrinsic parameter matrix and the second distortion parameters can be obtained. Compared with directly calculating the second intrinsic parameter matrix and the second distortion parameters based on the second calibration image, more accurate second intrinsic parameter matrix and second distortion parameters can be calculated through the guidance and constraint of the first intrinsic parameter matrix and the first distortion parameters.

[0120] In the related art, the calibration plate is imaged at a short distance under a long-wavelength laser by the lens 11 to obtain a calibration image, and short-distance calibration is performed. The intrinsic parameter matrix and distortion parameters obtained from the short-distance calibration are used as the constraints and initial values for the long-distance calibration when the lens 11 cooperates with the long-wavelength laser. Since the image acquisition component 10 is focused at a relatively long distance, the calibration image obtained from the short-distance acquisition is relatively blurred, and the short-distance calibration accuracy is poor, resulting in poor long-distance calibration accuracy.

[0121] In the embodiments of the present application, based on the image acquisition component 10 and the light source projection module 20, the first calibration plate is imaged at a first predetermined distance to obtain a first calibration image with high accuracy. First calibration is performed to obtain a first intrinsic parameter matrix and a first distortion parameter with high accuracy. Then, based on the first intrinsic parameter matrix and the first distortion parameter, the second calibration of the image acquisition component 10 is performed to guide and constrain the calculation process of the second intrinsic parameter matrix and the second distortion parameter. In this way, the second intrinsic parameter matrix and the second distortion parameter can be stably calculated, and the second calibration accuracy of the image acquisition component 10 can be improved.

[0122] Please refer to Figure 2 and Figure 7 , in some embodiments, performing iterative calculations on the iterative intrinsic parameter matrix and the iterative distortion parameters to obtain the second intrinsic parameter matrix and the second distortion parameters (i.e., 043) includes:

[0123] 0431: Iteratively update the iterative intrinsic parameter matrix according to the iterative distortion parameters, the first intrinsic parameter matrix, and the second calibration image;

[0124] 0432: Iteratively update the iterative distortion parameters according to the iterative intrinsic parameter matrix and the second calibration image, and return to the step of iteratively updating the iterative intrinsic parameter matrix according to the iterative distortion parameters, the first intrinsic parameter matrix, and the second calibration image;

[0125] 0433: When a preset condition is reached, stop the iterative update of the iterative intrinsic parameter matrix and the iterative distortion parameters;

[0126] 0434: Determine the second internal parameter matrix based on the internal parameter matrix within the last iteration, and determine the second distortion parameter based on the distortion parameter within the last iteration.

[0127] Specifically, after determining the iterative distortion parameter, calculate based on the iterative distortion parameter and the second calibration image, and during the calculation, constrain the internal parameters 、 in the second internal parameter matrix according to the ratio of the internal parameters 、 to obtain a new iterative internal parameter matrix, and replace the previously calculated iterative parameter matrix with the new iterative parameter matrix.

[0128] After that, based on the latest iterative internal parameter matrix and the second calibration image, calculate a new iterative distortion parameter, and replace the previously calculated iterative distortion parameter with the new iterative distortion parameter; then return to the step of iteratively updating the iterative internal parameter matrix according to the iterative distortion parameter, the first internal parameter matrix, and the second calibration image, and continuously iteratively update the iterative internal parameter matrix and the iterative distortion parameter until a preset condition is reached.

[0129] The preset condition is the convergence of the error between the iterative internal parameter matrix and the iterative distortion parameter, and the specific condition can be determined according to the calibration method adopted. For example, in some calibration methods, the reprojection error is calculated, so the convergence of the reprojection error can be used as the preset condition. The reprojection error refers to the difference between the three-dimensional world coordinates projected onto the image plane through the camera model (including the internal parameter matrix and the distortion parameter) and the actually observed pixel coordinates.

[0130] When the preset condition is reached, stop the iterative update of the iterative internal parameter matrix and the iterative distortion parameter, and use the iterative internal parameter matrix of the last iteration as the second internal parameter matrix, and use the iterative distortion parameter of the last iteration as the second distortion parameter. In this way, accurately calculate the precise second internal parameter matrix and the second distortion parameter stably.

[0131] Please refer to Figure 2 and Figure 8 , in some embodiments, the scanning control method further includes:

[0132] 050: Scan the first object to be scanned at the first scanning distance based on the light source projection module 20 and the image acquisition component 10 after the first calibration, and detect the target area corresponding to the first object to be scanned in each frame of the image;

[0133] 060: Scan the second object to be scanned at the second scanning distance based on the light source projection module 20 and the image acquisition component 10 after the second calibration, and detect the target area corresponding to the second object to be scanned in each frame of the image;

[0134] Among them, the second scanning distance is greater than the first scanning distance.

[0135] Specifically, after the calibration of the image acquisition component 10 is completed, the three-dimensional scanning device 100 can be used to scan the object to be scanned. When the image acquisition component 10 scans under the first light condition, the first object to be scanned is located at the first scanning distance, and the first object to be scanned is scanned based on the light source projection module 20 and the image acquisition component 10. During the scanning process, the first object to be scanned can be kept stationary, and the three-dimensional scanning device 100 can be controlled to rotate around the first object to be scanned; alternatively, the three-dimensional scanning device 100 can be kept stationary, and the first object to be scanned can be controlled to rotate around its own central axis.

[0136] During the above rotation process, the distance between the first scanned object and the three-dimensional scanning device 100 is controlled to remain the first scanning distance. Through scanning, multiple frames of images can be obtained, and the multiple frames of images are detected to determine the target area corresponding to the first object to be scanned in each frame of image. Based on the target area and the calibration, the first internal parameter matrix and the first distortion parameter can be obtained, and the three-dimensional reconstruction of the first object to be scanned can be performed.

[0137] When the image acquisition component 10 scans under the second light condition, the second object to be scanned is located at the second scanning distance, and the second object to be scanned is scanned based on the light source projection module 20 and the image acquisition component 10. During the scanning process, the second object to be scanned can be kept stationary, and the three-dimensional scanning device 100 can be controlled to rotate around the second object to be scanned; alternatively, the three-dimensional scanning device 100 can be kept stationary, and the second object to be scanned can be controlled to rotate around its own central axis.

[0138] During the above rotation process, the distance between the second scanned object and the three-dimensional scanning device 100 is controlled to remain the second scanning distance. Through scanning, multiple frames of images can be obtained, and the multiple frames of images are detected to determine the target area corresponding to the second object to be scanned in each frame of image. Based on the target area and the calibration, the second internal parameter matrix and the second distortion parameter can be obtained, and the three-dimensional reconstruction of the second object to be scanned can be performed.

[0139] The second scanning distance is greater than the first scanning distance. The first scanning distance can be the same as the first predetermined distance in the foregoing embodiments. For example, the first scanning distance can be set to less than 400 mm. The second scanning distance can be the same as the second predetermined distance in the foregoing embodiments. For example, the second scanning distance can be set to greater than 600 mm. The first object to be scanned and the second object to be scanned can be the same or different.

[0140] In the related art, the scanning device only scans through a blue laser. The wavelength of the blue light is short and the focusing is close. When the object to be scanned is far from the scanning device, the scanning clarity is low.

[0141] In the embodiments of the present application, the light source projection module 20 can project a first light ray and a second light ray, and the wavelength of the first light ray is less than that of the second light ray; the image acquisition component 10 after the first calibration can be used for three-dimensional scanning at a short distance under the condition of the first light ray, and the image acquisition component 10 after the second calibration can be used for three-dimensional scanning at a long distance under the condition of the second light ray. In this way, the three-dimensional scanning device 100 can achieve three-dimensional scanning at a long distance, and the scanning clarity and scanning accuracy are relatively high, so that the three-dimensional scanning device 100 can be applied to different scanning working conditions.

[0142] Please refer to Figure 2 、 Figure 3 and Figure 9 , in some embodiments, the image acquisition component 10 includes an image sensor 12. The scanning control method further includes:

[0143] During the process of scanning a first object to be scanned located at a first scanning distance based on the light source projection module 20 and the image acquisition component 10 after the first calibration, and detecting the target area (i.e., 050) corresponding to the first object to be scanned in each frame of image,

[0144] 051: Control the brightness of the first light ray projected by the light source projection module 20 to be a first brightness, and control the exposure time of the image sensor 12 to be a first exposure time;

[0145] During the process of scanning a second object to be scanned located at a second scanning distance based on the light source projection module 20 and the image acquisition component 10 after the second calibration, and detecting the target area (i.e., 060) corresponding to the second object to be scanned in each frame of image,

[0146] 061: Control the brightness of the second light ray projected by the light source projection module 20 to be a second brightness, and control the exposure time of the image sensor 12 to be a second exposure time;

[0147] Wherein, the second brightness is greater than the first brightness, and the second exposure time is less than the first exposure time.

[0148] Specifically, the image acquisition component 10 includes an image sensor 12, and the image sensor 12 is used to convert the optical signal captured by the lens 11 into an electrical signal to form an image. During the process of scanning a first object to be scanned located at a first scanning distance based on the light source projection module 20 and the image acquisition component 10 after the first calibration, and detecting the target area corresponding to the first object to be scanned in each frame of image, the light source projection module 20 projects the first light ray with the first brightness, and the exposure time of the image sensor 12 is set to the first exposure time.

[0149] When scanning a second object to be scanned at a second scanning distance based on the light source projection module 20 and the image acquisition component 10 after the second calibration, and detecting the target area corresponding to the second object to be scanned in each frame of image, the light source projection module 20 projects a second light ray with a second brightness, and the exposure time of the image sensor 12 is set to a second exposure time.

[0150] The second brightness is greater than the first brightness, and the second exposure time is less than the first exposure time. That is to say, compared with the close-range scanning based on the light source projection module 20 and the image acquisition component 10, when performing long-range scanning based on the light source projection module 20 and the image acquisition component 10, the brightness of the light ray projected by the light source projection module 20 can be appropriately increased, and the exposure time of the image sensor 12 can be reduced.

[0151] Since the wavelength of the second light ray projected by the light source projection module 20 is greater than that of the first light ray, the energy of the second light ray is less concentrated and is easily interfered by the natural environment. Increasing the brightness of the second light ray enables the image sensor 12 to receive more optical signals within the same time; reducing the exposure time of the image sensor 12 enables the image sensor 12 to collect optical signals in a shorter time, reducing the influence of ambient light on imaging. In this way, the background brightness can be reduced, the foreground brightness can be increased, highlighting the imaging of the second light ray in the image, which is beneficial to reducing the interference of the background and ambient light.

[0152] Please refer to Figure 2 and Figure 10 , in some embodiments, when scanning a second object to be scanned at a second scanning distance based on the light source projection module 20 and the image acquisition component 10 after the second calibration, and detecting the target area (i.e., 060) corresponding to the second object to be scanned in each frame of image, it includes:

[0153] 062: Controlling the light source projection module 20 to project a second light ray onto the second object to be scanned at the second scanning distance;

[0154] 063: Acquiring multiple frames of images to be processed by performing image acquisition on the second object to be scanned through the image acquisition component 10 after the second calibration;

[0155] 064: Extracting and matching the target area from multiple frames of images to be processed to obtain the target area corresponding to the second object to be scanned.

[0156] Specifically, when scanning a second object to be scanned at a second scanning distance, the light source projection module 20 is controlled to project a second light beam onto the second object to be scanned. The image acquisition component 10 after the second calibration is used to acquire images of the second object to be scanned, obtaining multiple consecutive frames of images to be processed. The target regions of the multiple frames of images to be processed are respectively extracted and matched to determine the target regions corresponding to the second object to be scanned in each frame of the image to be processed, so as to perform three-dimensional reconstruction of the second object to be scanned based on the target regions.

[0157] Please refer to Figure 2 and Figure 11 , in some embodiments, extracting and matching the target regions of multiple frames of images to be processed to obtain the target regions corresponding to the second object to be scanned (i.e., 064) includes:

[0158] 0641: Setting a first mask region according to the target region extracted and matched in the previous frame of the image to be processed;

[0159] 0642: Determining a second mask region of the current frame of the image to be processed according to the first mask region;

[0160] 0643: Setting a judgment threshold for the current frame of the image to be processed according to the second mask region;

[0161] 0644: Extracting and matching the target regions of the current frame of the image to be processed according to the judgment threshold to obtain the target regions corresponding to the second object to be scanned.

[0162] Specifically, taking the second light beam as an infrared laser, the second light beam is projected onto the second object to be scanned, forming a light spot or light strip with an obvious brightness difference on the surface of the second object to be scanned. The brightness difference is manifested as a change in the gray value in the image to be processed. For the first frame of the image to be processed, calculate the gradient and determine the region with an obvious change in gray value in the image to be processed according to the judgment threshold. For example, when the gradient is greater than the judgment threshold, it indicates that the gray change is obvious; when the gradient is less than or equal to the judgment threshold, it indicates that the gray change is not obvious. Extract the region with an obvious gray change and mark it as the initial region. For the extracted initial region, perform preliminary three-dimensional reconstruction and match it with the laser plane to determine whether the initial region is the target region. The initial region located on the laser plane is the target region.

[0163] After determining the target region in the first frame of the image to be processed, the first mask region can be set according to the target region. According to the first mask region, as prior information, the second mask region can be determined in the second frame of the image to be processed. In the second frame of the image to be processed, set the judgment threshold according to the second mask region. Different judgment thresholds can be set for the region corresponding to the second mask region and the region outside the second mask region.

[0164] Calculate the gradient of the second frame of the image to be processed. For the area corresponding to the second mask area and the area outside the second mask area, according to different set judgment thresholds, extract and match the target area respectively to obtain the target area corresponding to the second object to be scanned. For the target area in the second frame of the image to be processed, a new first mask area can be determined. According to the new first mask area, determine the second mask area in the third frame of the image to be processed, and set the judgment threshold of the third frame of the image to be processed according to the second mask area, so as to extract and match the target area of the third frame of the image to be processed.

[0165] And so on, set the first mask area according to the target area extracted and matched in the (N - 1)-th frame of the image to be processed, and determine the second mask area of the N-th frame of the image to be processed according to the first mask area. Set the judgment threshold of the N-th frame of the image to be processed according to the second mask area, and extract and match the target area of the N-th frame of the image to be processed according to the judgment threshold to obtain the target area corresponding to the second object to be scanned, so as to complete the detection of multiple frames of the image to be processed and determine the target area corresponding to the second object to be scanned in each frame of the image.

[0166] In the related art, during the infrared scanning process, it is extremely vulnerable to external environmental interference, and there is a large amount of energy in the infrared band in natural ambient light. Even by using a filter to only allow infrared laser of a fixed band to pass through, the influence of ambient light cannot be avoided.

[0167] In the embodiments of the present application, the target area extracted and matched from the previous frame of the image to be processed provides prior information for the current frame of the image to be processed, and the prior information is used to extract and match the target area of the current frame of the image to be processed. In this way, the interference of the background and ambient light can be further reduced by using the prior information, the accuracy of the obtained target area is improved, and thus the three-dimensional reconstruction accuracy is improved.

[0168] Please refer to Figure 2 and Figure 12 , in some embodiments, determining the second mask area (i.e., 0642) of the current frame of the image to be processed according to the first mask area includes:

[0169] 06421: Determine the diffusion ratio of the first mask area according to the acquisition frame rate of the image acquisition component 10;

[0170] 06422: Perform diffusion processing on the first mask area according to the diffusion ratio to obtain a diffusion area;

[0171] 06423: Determine the second mask area in the current frame of the image to be processed according to the diffusion area.

[0172] Specifically, the acquisition frame rate represents the number of frames of images acquired by the image acquisition component 10 per second. According to the acquisition frame rate of the image acquisition component 10, the diffusion ratio of the first mask region is determined. The larger the acquisition frame rate, the larger the diffusion ratio; the smaller the acquisition frame rate, the smaller the diffusion ratio. The first mask region is diffusely processed according to the diffusion ratio. For example, if the diffusion ratio is 10%, the area of the first mask region is increased by 10%. After obtaining the diffusion region, according to the position of the first mask region in the previous frame of the image to be processed, the diffusion region is set at the corresponding position in the current frame of the image to be processed, and the second mask region is obtained.

[0173] It can be understood that multiple frames of images to be processed are continuous, and the position change of the second object to be scanned in two consecutive frames of images to be processed is small, and the target region in the previous frame of the image to be processed overlaps at least partially with the target region in the current frame of the image to be processed; therefore, the second mask region can be determined based on the first mask region in the current frame of the image to be processed. To ensure that the second mask region can better cover the target region, the first mask region can be diffusely processed to a certain extent, and then the second mask region is determined in the current frame of the image to be processed. In this way, better prior information can be provided for the extraction and matching of the target region of the current frame of the image to be processed.

[0174] Please refer to Figure 2 and Figure 13 , in some embodiments, setting the judgment threshold (i.e., 0643) of the current frame of the image to be processed according to the second mask region includes:

[0175] 06431: For the region corresponding to the second mask region in the current frame of the image to be processed, set the judgment threshold to the first judgment threshold;

[0176] 06432: For the region outside the second mask region in the current frame of the image to be processed, set the judgment threshold to the second judgment threshold;

[0177] wherein, the second judgment threshold is greater than the first judgment threshold.

[0178] Specifically, in the current frame of the image to be processed, for the region corresponding to the second mask region and the region outside the second mask region, the first judgment threshold and the second judgment threshold are respectively set, and the second judgment threshold is greater than the first judgment threshold.

[0179] For the region corresponding to the second mask region in the current frame of the image to be processed, the possibility of this region being the target region is relatively high, and relatively subtle gradient changes may be the target region. Therefore, the judgment threshold is set to the smaller first judgment threshold.

[0180] For the area outside the second mask area in the image to be processed in the current frame, the possibility of this area being the target area is relatively small. Only obvious gradient changes may be the target area. Therefore, the judgment threshold is set to a relatively large second judgment threshold.

[0181] In this way, it is beneficial to eliminate the background in the image to be processed in the current frame and reduce the interference of the background and ambient light.

[0182] Please refer to Figure 2 and Figure 14 In addition, an embodiment of the present application further provides a scanning control device 200, which is applied to a three-dimensional scanning device 100. The three-dimensional scanning device 100 includes an image acquisition component 10 and a light source projection module 20. The light source projection module 20 is configured to project a first light ray and a second light ray, and the wavelength of the first light ray is less than the wavelength of the second light ray. The scanning control device 200 includes a first acquisition module 210, a second acquisition module 220, a first calibration module 230, and a second calibration module 240. The first acquisition module 210 is configured to acquire a first calibration image corresponding to the first light ray based on the light source projection module 20 and the image acquisition component 10. The second acquisition module 220 is configured to acquire a second calibration image corresponding to the second light ray based on the light source projection module 20 and the image acquisition component 10. The first calibration module 230 is configured to perform a first calibration on the image acquisition component 10 based on the first calibration image to determine a first internal parameter matrix and a first distortion parameter of the image acquisition component 10. The second calibration module 240 is configured to perform a second calibration on the image acquisition component 10 based on the first internal parameter matrix, the first distortion parameter, and the second calibration image to determine a second internal parameter matrix and a second distortion parameter of the image acquisition component 10.

[0183] In some embodiments, the first acquisition module 210 is specifically configured to control the light source projection module 20 to project the first light ray onto a first calibration plate located at a first predetermined distance; and perform image acquisition on the first calibration plate through the image acquisition component 10 to obtain the first calibration image.

[0184] In some embodiments, the second acquisition module 220 is specifically configured to control the light source projection module 20 to project the second light ray onto a second calibration plate located at a second predetermined distance; perform image acquisition on the second calibration plate through the image acquisition component 10 to obtain the second calibration image; wherein, the second predetermined distance is greater than the first predetermined distance.

[0185] In some embodiments, the second calibration module 240 is specifically configured to calculate an iterative internal parameter matrix based on the first internal parameter matrix, the first distortion parameter, and the second calibration image; calculate an iterative distortion parameter based on the iterative internal parameter matrix and the second calibration image; perform iterative calculation on the iterative internal parameter matrix and the iterative distortion parameter to obtain the second internal parameter matrix and the second distortion parameter.

[0186] In some embodiments, the second calibration module 240 is specifically configured to iteratively update the iterative intrinsic matrix according to the iterative distortion parameters, the first intrinsic matrix, and the second calibration image; iteratively update the iterative distortion parameters according to the iterative intrinsic matrix and the second calibration image, and return the step of iteratively updating the iterative intrinsic matrix according to the iterative distortion parameters, the first intrinsic matrix, and the second calibration image; when a preset condition is reached, stop the iterative update of the iterative intrinsic matrix and the iterative distortion parameters; determine the second intrinsic matrix according to the iterative intrinsic matrix of the last iteration, and determine the second distortion parameter according to the iterative distortion parameters of the last iteration.

[0187] Please refer to Figure 2 and Figure 15 , in some embodiments, the scanning control device 200 further includes a scanning detection module 250. The scanning detection module 250 is configured to scan a first object to be scanned at a first scanning distance based on the light source projection module 20 and the image acquisition component 10 after the first calibration, and detect a target area corresponding to the first object to be scanned in each frame of image; scan a second object to be scanned at a second scanning distance based on the light source projection module 20 and the image acquisition component 10 after the second calibration, and detect a target area corresponding to the second object to be scanned in each frame of image; wherein, the second scanning distance is greater than the first scanning distance.

[0188] In some embodiments, the image acquisition component 10 includes an image sensor 12. In the process of scanning a first object to be scanned at a first scanning distance based on the light source projection module 20 and the calibrated image acquisition component 10, and detecting a target area corresponding to the first object to be scanned in each frame of image, the scanning detection module 250 is further configured to control the brightness of the first light projected by the light source projection module 20 to be a first brightness, and control the exposure time of the image sensor 12 to be a first exposure time. In the process of scanning a second object to be scanned at a second scanning distance based on the light source projection module 20 and the calibrated image acquisition component 10, and detecting a target area corresponding to the second object to be scanned in each frame of image, the scanning detection module 250 is further configured to control the brightness of the second light projected by the light source projection module 20 to be a second brightness, and control the exposure time of the image sensor 12 to be a second exposure time; wherein, the second brightness is greater than the first brightness, and the second exposure time is less than the first exposure time.

[0189] In some embodiments, the scanning detection module 250 is specifically configured to control the light source projection module 20 to project a second light beam onto a second object to be scanned at a second scanning distance; perform image acquisition on the second object to be scanned through the image acquisition component 10 after the second calibration to obtain multiple frames of images to be processed; extract and match the target areas of the multiple frames of images to be processed to obtain a target area corresponding to the second object to be scanned.

[0190] In some embodiments, the scanning detection module 250 is specifically configured to set a first mask region according to the target region extracted and matched from the previous frame of the image to be processed; determine a second mask region of the current frame of the image to be processed according to the first mask region; set a judgment threshold for the current frame of the image to be processed according to the second mask region; and extract and match the target region of the current frame of the image to be processed according to the judgment threshold to obtain the target region corresponding to the second object to be scanned.

[0191] In some embodiments, the scanning detection module 250 is specifically configured to determine the diffusion ratio of the first mask region according to the acquisition frame rate of the image acquisition component 10; perform diffusion processing on the first mask region according to the diffusion ratio to obtain a diffusion region; and determine the second mask region in the current frame of the image to be processed according to the diffusion region.

[0192] In some embodiments, the scanning detection module 250 is specifically configured to set the judgment threshold to a first judgment threshold for the region corresponding to the second mask region in the current frame of the image to be processed; and set the judgment threshold to a second judgment threshold for the region outside the second mask region in the current frame of the image to be processed; wherein the second judgment threshold is greater than the first judgment threshold.

[0193] It should be noted that the above explanations of the scanning control method in the foregoing embodiments are equally applicable to the scanning control device 200 of the embodiments of the present application, and will not be elaborated herein.

[0194] Please refer to Figure 16 , the embodiments of the present application further provide a scanning control system 300. The scanning control system 300 includes one or more processors 310 and a memory 320. When the computer program stored in the memory 320 is executed by the processor 310, the scanning control method of any of the above embodiments is implemented.

[0195] For example, when the computer program is executed by the processor 310, the following scanning control method is implemented:

[0196] 010: Obtain a first calibration image corresponding to the first light ray based on the light source projection module 20 and the image acquisition component 10;

[0197] 020: Obtain a second calibration image corresponding to the second light ray based on the light source projection module 20 and the image acquisition component 10;

[0198] 030: Perform first calibration on the image acquisition component 10 based on the first calibration image to determine the first internal parameter matrix and the first distortion parameter of the image acquisition component 10;

[0199] 040: Perform a second calibration on the image acquisition component 10 based on the first internal parameter matrix, the first distortion parameter, and the second calibration image to determine the second internal parameter matrix and the second distortion parameter of the image acquisition component 10.

[0200] For another example, when the computer program is executed by the processor 310, the following scanning control method is implemented:

[0201] 011: Control the light source projection module 20 to project a first light ray onto a first calibration plate located at a first predetermined distance;

[0202] 012: Acquire an image of the first calibration plate through the image acquisition component 10 to obtain a first calibration image.

[0203] It should be noted that the explanations of the scanning control method and the scanning control device 200 in the foregoing embodiments are equally applicable to the scanning control system 300 of the embodiments of the present application, and will not be elaborated herein.

[0204] Please refer to Figure 17 , the embodiments of the present application further provide a computer-readable storage medium 400, on which a computer program 410 is stored. When the program is executed by the processor 420, the scanning control method of any of the foregoing embodiments is implemented.

[0205] For example, when the computer program 410 is executed by the processor 420, the following scanning control method is implemented:

[0206] 010: Obtain a first calibration image corresponding to the first light ray based on the light source projection module 20 and the image acquisition component 10;

[0207] 020: Obtain a second calibration image corresponding to the second light ray based on the light source projection module 20 and the image acquisition component 10;

[0208] 030: Perform a first calibration on the image acquisition component 10 based on the first calibration image to determine the first internal parameter matrix and the first distortion parameter of the image acquisition component 10;

[0209] 040: Perform a second calibration on the image acquisition component 10 based on the first internal parameter matrix, the first distortion parameter, and the second calibration image to determine the second internal parameter matrix and the second distortion parameter of the image acquisition component 10.

[0210] For another example, when the computer program 410 is executed by the processor 420, the following scanning control method is implemented:

[0211] 011: Control the light source projection module 20 to project a first light ray onto a first calibration plate located at a first predetermined distance;

[0212] 012: The first calibration image is obtained by collecting an image of the first calibration board through the image acquisition component 10.

[0213] It should be noted that the explanations of the scanning control method and the scanning control device 200 in the foregoing embodiments are equally applicable to the computer-readable storage medium 400 of the embodiments of the present application, and will not be elaborated herein.

[0214] In summary, in the scanning control method, the scanning control device 200, the scanning control system 300, and the computer-readable storage medium 400 of the embodiments of the present application, the image acquisition component 10 is first calibrated based on the first calibration image to obtain a first internal parameter matrix and first distortion parameters with relatively high precision, and then the image acquisition component 10 is secondarily calibrated with reference to the first internal parameter matrix and the first distortion parameters to determine a second internal parameter matrix and second distortion parameters corresponding to the image acquisition component 10 and the second light ray. In this way, the calibration accuracy of the image acquisition component 10 under long-wavelength light conditions is improved, and the 3D reconstruction accuracy of the 3D scanning device 100 is ensured.

[0215] In the description of this specification, the descriptions with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples", etc. mean that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in any one or more embodiments or examples in a suitable manner. In addition, without contradiction, those skilled in the art can combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples.

[0216] Any process or method description in the flowchart or described in other ways herein can be understood as representing a module, segment, or part of the code including one or more executable instructions for implementing a specific logical function or process, and the scope of the preferred embodiments of the present application includes additional implementations, where the functions can be executed in a substantially simultaneous manner or in a reverse order according to the involved functions, rather than in the order shown or discussed, which should be understood by those skilled in the art of the embodiments of the present application.

[0217] The logic and / or steps represented in the flowchart or otherwise described herein can be considered, for example, a definitional sequence of executable instructions for implementing a logical function, and can be embodied specifically in any computer-readable storage medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, a system including a processor, or other systems that can fetch and execute instructions from the instruction execution system, apparatus, or device. For the purposes of this specification, a computer-readable storage medium can be any device that can contain, store, communicate, propagate, or transport a program for use by or in connection with the instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of the computer-readable storage medium include the following: an electrical connection portion having one or more wirings (electronic device), a portable computer diskette (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable storage medium can even be paper or other suitable medium on which the program can be printed, as the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpretation, or otherwise processing as appropriate, and then storing it in a computer memory.

[0218] It should be understood that various parts of the present application can be implemented by hardware, software, firmware, or a combination thereof. In the above-described embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or a combination of the following techniques well known in the art can be used: discrete logic circuits having logic gate circuits for implementing logical functions on data signals, application specific integrated circuits having appropriate combinational logic gate circuits, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.

[0219] Those of ordinary skill in the art can understand that all or part of the steps carried out in the methods of the above embodiments can be completed by instructing relevant hardware through a program, and the program can be stored in a computer-readable storage medium. When the program is executed, it includes one or a combination of the steps of the method embodiments. In addition, in each of the embodiments of the present application, each functional unit can be integrated in a processing module, or each unit can exist physically alone, or two or more units can be integrated in a module. The above integrated module can be implemented in the form of hardware or in the form of a software functional module. When the above integrated module is implemented in the form of a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. The storage medium mentioned above can be a read-only memory, a magnetic disk, an optical disk, etc.

[0220] Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and should not be construed as limiting the present application. Those of ordinary skill in the art can make changes, modifications, substitutions, and variations to the above embodiments within the scope of the present application, and the scope of the present application is defined by the claims and their equivalents.

Claims

1. A scanning control method, characterized in that: Applied to a three-dimensional scanning device, the three-dimensional scanning device includes an image acquisition component and a light source projection module, the light source projection module is used to project a first light and a second light, the wavelength of the first light is smaller than the wavelength of the second light, and the scanning control method includes: Acquire a first calibration image corresponding to the first light based on the light source projection module and the image acquisition component; Acquire a second calibration image corresponding to the second light based on the light source projection module and the image acquisition component; Performing a first calibration on the image acquisition component based on the first calibration image to determine a first intrinsic parameter matrix and a first distortion parameter of the image acquisition component; Performing a second calibration on the image acquisition component based on the first intrinsic parameter matrix, the first distortion parameter, and the second calibration image to determine a second intrinsic parameter matrix and a second distortion parameter of the image acquisition component; The performing a second calibration on the image acquisition component based on the first intrinsic parameter matrix, the first distortion parameter and the second calibration image to determine a second intrinsic parameter matrix and a second distortion parameter of the image acquisition component includes: Calculating an iterative intrinsic parameter matrix according to the first intrinsic parameter matrix, the first distortion parameter and the second calibration image; Calculating iterative distortion parameters according to the iterative intrinsic parameter matrix and the second calibration image; The iterative internal parameter matrix and the iterative distortion parameter are iteratively calculated to obtain a second internal parameter matrix and a second distortion parameter.

2. The scanning control method according to claim 1, characterized in that: The acquiring a first calibration image corresponding to the first light based on the light source projection module and the image acquisition component includes: Controlling the light source projection module to project the first light to a first calibration plate located at a first predetermined distance; The image acquisition component is used to acquire an image of the first calibration plate to obtain the first calibration image.

3. The scanning control method according to claim 2, characterized in that: The acquiring a second calibration image corresponding to the second light based on the light source projection module and the image acquisition component includes: Controlling the light source projection module to project the second light to a second calibration plate located at a second predetermined distance; Capturing the image of the second calibration plate by the image acquisition component to obtain the second calibration image; Wherein, the second predetermined distance is greater than the first predetermined distance.

4. The scanning control method according to claim 1, characterized in that: The iterative calculation of the iterative internal parameter matrix and the iterative distortion parameter to obtain a second internal parameter matrix and a second distortion parameter includes: Iteratively updating the iterative intrinsic parameter matrix according to the iterative distortion parameter, the first intrinsic parameter matrix and the second calibration image; Iteratively updating the iterative distortion parameters according to the iterative intrinsic parameter matrix and the second calibration image, and returning to the step of iteratively updating the iterative intrinsic parameter matrix according to the iterative distortion parameters, the first intrinsic parameter matrix and the second calibration image; When a preset condition is reached, stopping the iterative update of the iterative internal parameter matrix and the iterative distortion parameter; A second internal parameter matrix is ​​determined according to the iterative internal parameter matrix of the last iteration, and a second distortion parameter is determined according to the iterative distortion parameter of the last iteration.

5. The scanning control method according to claim 1, characterized in that: The scanning control method further includes: Scanning a first object to be scanned located at a first scanning distance based on the light source projection module and the image acquisition component after the first calibration, and detecting a target area corresponding to the first object to be scanned in each frame of the image; Scanning a second object to be scanned located at a second scanning distance based on the light source projection module and the image acquisition component after the second calibration, and detecting a target area corresponding to the second object to be scanned in each frame of the image; Wherein, the second scanning distance is greater than the first scanning distance.

6. The scanning control method according to claim 5, characterized in that: The image acquisition component includes an image sensor, and the scanning control method further includes: In the process of scanning the first object to be scanned at the first scanning distance based on the light source projection module and the image acquisition component after the first calibration, and detecting the target area corresponding to the first object to be scanned in each frame of the image, the brightness of the first light projected by the light source projection module is controlled to be the first brightness, and the photosensitivity time of the image sensor is controlled to be the first photosensitivity time; In the process of scanning the second object to be scanned at the second scanning distance based on the light source projection module and the image acquisition component after the second calibration, and detecting the target area corresponding to the second object to be scanned in each frame of the image, the brightness of the second light projected by the light source projection module is controlled to be the second brightness, and the photosensitivity time of the image sensor is controlled to be the second photosensitivity time; Among them, the second brightness is greater than the first brightness, and the second photosensitivity time is shorter than the first photosensitivity time.

7. The scanning control method according to claim 5, characterized in that: The method of scanning a second object to be scanned located at a second scanning distance based on the light source projection module and the image acquisition component after the second calibration, and detecting a target area corresponding to the second object to be scanned in each frame of the image, includes: Controlling the light source projection module to project the second light to the second object to be scanned at the second scanning distance; Capturing images of the second object to be scanned by the image acquisition component after the second calibration to obtain a plurality of frames of images to be processed; The target area is extracted and matched on multiple frames of the to-be-processed images to obtain the target area corresponding to the second to-be-scanned object.

8. The scanning control method according to claim 7, characterized in that: The step of extracting and matching the target area from the plurality of frames of the images to be processed to obtain the target area corresponding to the second object to be scanned includes: Setting a first mask area according to the target area extracted and matched in the image to be processed in the previous frame; Determining a second mask area of ​​the image to be processed in the current frame according to the first mask area; Setting a judgment threshold of the image to be processed in the current frame according to the second mask area; The target area is extracted and matched for the image to be processed in the current frame according to the judgment threshold to obtain the target area corresponding to the second object to be scanned.

9. The scanning control method according to claim 8, characterized in that: The step of determining a second mask area of ​​the image to be processed in the current frame according to the first mask area includes: Determining a diffusion ratio of the first mask area according to an acquisition frame rate of the image acquisition component; Performing diffusion processing on the first mask area according to the diffusion ratio to obtain a diffusion area; According to the diffusion area, the second mask area is determined in the image to be processed in the current frame.

10. The scanning control method according to claim 8, characterized in that: The step of setting a judgment threshold of the image to be processed in the current frame according to the second mask area includes: For an area corresponding to the second mask area in the image to be processed in the current frame, setting the judgment threshold to a first judgment threshold; For an area outside the second mask area in the image to be processed in the current frame, setting the judgment threshold to a second judgment threshold; The second judgment threshold is greater than the first judgment threshold.

11. A scanning control device, characterized in that: Applied to a three-dimensional scanning device, the three-dimensional scanning device includes an image acquisition component and a light source projection module, the light source projection module is used to project a first light and a second light, the wavelength of the first light is smaller than the wavelength of the second light, and the scanning control device includes: A first acquisition module, used for acquiring a first calibration image corresponding to the first light based on the light source projection module and the image acquisition component; A second acquisition module, used for acquiring a second calibration image corresponding to the second light based on the light source projection module and the image acquisition component; A first calibration module, configured to perform a first calibration on the image acquisition component based on the first calibration image, and determine a first intrinsic parameter matrix and a first distortion parameter of the image acquisition component; A second calibration module, configured to perform a second calibration on the image acquisition component based on the first intrinsic parameter matrix, the first distortion parameter and the second calibration image, and determine a second intrinsic parameter matrix and a second distortion parameter of the image acquisition component; Wherein, the second calibration module is specifically used for: Calculating an iterative intrinsic parameter matrix according to the first intrinsic parameter matrix, the first distortion parameter and the second calibration image; Calculating iterative distortion parameters according to the iterative intrinsic parameter matrix and the second calibration image; The iterative internal parameter matrix and the iterative distortion parameter are iteratively calculated to obtain a second internal parameter matrix and a second distortion parameter.

12. A scanning control system, characterized in that: The scanning control system includes one or more processors and a memory, wherein the memory stores a computer program, and when the computer program is executed by the processor, the scanning control method according to any one of claims 1 to 10 is implemented.

13. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the scanning control method described in any one of claims 1 to 10 is implemented.

Citation Information

Patent Citations

  • Equipment calibration method for multi-source data fusion and related device

    CN113034615A

  • Infrared light image and visible light image alignment method and device and electronic equipment

    CN115953325A