A method and system for obtaining depth value based on dynamic binarization algorithm

By using dynamic binarization algorithm in depth cameras, the 8-bit grayscale image is converted into 1-bit image, which solves the problem of information redundancy and increase in depth value calculation in the prior art, and achieves more efficient hardware resource utilization and better depth map quality.

CN114092539BActive Publication Date: 2025-03-07NANJING UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111393145.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-23
Publication Date
2025-03-07
Estimated Expiration
2041-11-23

Smart Images

  • Figure CN114092539B_ABST
    Figure CN114092539B_ABST
Patent Text Reader

Abstract

The present application relates to the field of depth camera recognition, and in particular to a method and system for obtaining depth values ​​based on a dynamic binarization algorithm, obtaining an 8-bit grayscale image corresponding to a reference image and a point to be tested, converting the reference image and the 8-bit grayscale image corresponding to the point to be tested into a 1-bit image through a local dynamic binarization model, and obtaining a corresponding 1-bit binarization value, obtaining matching cost values ​​of different disparities of the point to be tested through a matching cost model, selecting the minimum matching cost value as the preliminary disparity of the point to be tested; performing denoising and smoothing on the preliminary disparity to obtain the disparity of the point to be tested; and mapping the disparity of the point to be tested to the depth value of the point to be tested. The present application provides a method and system for obtaining depth values ​​based on a dynamic binarization algorithm, which can reduce the amount of calculation in the depth algorithm, thereby reducing the demand for the number of logic gates, and improving the area efficiency and power efficiency of the depth algorithm accelerator while providing a high-quality depth map.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of depth camera recognition, and in particular to a method and system for obtaining depth values ​​based on a dynamic binarization algorithm. Background Art

[0002] With the development of disruptive technologies such as machine vision and autonomous driving, more and more applications are using depth cameras for object recognition, behavior recognition, and scene modeling. Depth cameras can detect the depth of field of the shooting space through the camera, and have the characteristics of high resolution and high precision. It can be said that depth cameras are the eyes of terminals and robots. The data obtained by the depth camera can accurately know the distance of each point in the image from the camera. With the coordinates of the point in the 2D image, the three-dimensional spatial coordinates of each point in the image can be obtained. The three-dimensional coordinates can restore the real scene and realize applications such as scene modeling.

[0003] As a type of depth camera, structured light cameras usually include infrared random dot matrix projectors and thermal infrared cameras. The infrared random dot matrix projector uses an invisible infrared laser of a specific wavelength as a light source. The light it emits is projected onto an object after a certain coding process, and forms a random dot matrix with certain structural characteristics. The thermal infrared camera then collects the reflected random dot matrix, and finally uses a certain algorithm to calculate the distortion of the returned coded pattern to obtain the position and depth information of the object.

[0004] Among them, the random dot matrix itself is a binary information. In the prior art, what is obtained from the infrared camera is an 8-bit grayscale image. The 8-bit grayscale image has information redundancy. The calculation of the matching cost directly based on 8-bit will cause unnecessary increase in the amount of calculation. Therefore, under the same throughput requirement, the analysis and processing hardware in the structured light camera is proportional to the amount of calculation, which will lead to an increase in the area of ​​the required hardware and an increase in power consumption. Summary of the invention

[0005] In order to simplify the calculation of depth values, thereby reducing hardware area and lowering power consumption, the present application provides a depth value acquisition method and system based on a dynamic binarization algorithm.

[0006] In a first aspect of the present application, a method for obtaining a depth value based on a dynamic binarization algorithm is provided, comprising:

[0007] A reference image and an infrared random dot matrix image of the object to be measured are obtained, and any point of the infrared random dot matrix image is selected as the point to be measured. The reference image is an infrared random dot matrix image on a plane at a certain distance from the structured light camera.

[0008] The reference image and the 8-bit grayscale image corresponding to the point to be measured are obtained, and the reference image and the 8-bit grayscale image corresponding to the point to be measured are converted into 1-bit images through a local dynamic binarization model, and corresponding 1-bit binarization values ​​are obtained.

[0009] According to the 1-bit binary value, the matching cost values ​​of different disparities of the test point are obtained through a matching cost model.

[0010] According to the matching cost values ​​of different parallaxes of the point to be measured, the minimum matching cost value is selected as the preliminary parallax of the point to be measured.

[0011] According to the preliminary disparity, the preliminary disparity is subjected to denoising and smoothing to obtain the disparity of the point to be measured.

[0012] According to the disparity of the point to be measured, the disparity of the point to be measured is mapped to a depth value of the point to be measured.

[0013] Optionally, the local dynamic binarization model is:

[0014]

[0015] W is a window centered on p, p n is a pixel value in W, N is the number of pixels in W, p is an 8-bit grayscale value, and q is a 1-bit binary value.

[0016] Optionally, the matching cost model is:

[0017]

[0018] C d is the matching cost of the disparity, q n is the pixel of the corresponding window in the 1-bit image of the point to be tested, q′ (n,d) is the pixel of the corresponding window in the 1-bit image of the reference image.

[0019] Optionally, in the step of denoising and smoothing the preliminary disparity to obtain the disparity of the point to be measured, sub-pixel estimation, speckle removal and a median filter are used to denoise and smooth the preliminary disparity.

[0020] Optionally, in the step of mapping the disparity of the point to be measured to the depth value of the point to be measured, triangulation is adopted to map the disparity to the depth value using a triangular relationship.

[0021] A second aspect of the present application provides a depth value acquisition system based on a dynamic binarization algorithm, comprising: an image acquisition module, an image binarization module, a matching module, a screening module, a post-processing module and a mapping module.

[0022] The image acquisition module is used to acquire a reference image and an infrared random dot matrix image of the object to be measured, and select any point of the infrared random dot matrix image as a point to be measured.

[0023] The image binarization module is used to obtain the 8-bit grayscale images corresponding to the reference image and the points to be tested, and convert the 8-bit grayscale images corresponding to the reference image and the points to be tested into 1-bit images through a local dynamic binarization model, and obtain corresponding 1-bit binarization values.

[0024] The matching module is used to obtain matching cost values ​​of different parallaxes of the test point through a matching cost model according to the 1-bit binary value.

[0025] The screening module is used to select the minimum matching cost value as the preliminary disparity of the point to be measured according to the matching cost values ​​of different disparities of the point to be measured.

[0026] The post-processing module is used to perform noise elimination and smoothing on the preliminary disparity according to the preliminary disparity to obtain the disparity of the point to be measured.

[0027] The mapping module is used to map the disparity of the point to be measured into a depth value of the point to be measured according to the disparity of the point to be measured.

[0028] Optionally, the local dynamic binarization model is:

[0029]

[0030] W is a window centered on p, p n is a pixel value in W, N is the number of pixels in W, p is an 8-bit grayscale value, and q is a 1-bit binary value.

[0031] Optionally, the matching cost model is:

[0032]

[0033] C d is the matching cost of the disparity, q n is the pixel of the corresponding window in the 1-bit image of the point to be tested, q′ (n,d) is the pixel of the corresponding window in the 1-bit image of the reference image.

[0034] Optionally, in the step of denoising and smoothing the preliminary disparity to obtain the disparity of the point to be measured, sub-pixel estimation, speckle removal and a median filter are used to denoise and smooth the preliminary disparity.

[0035] Optionally, in the step of mapping the disparity of the point to be measured to the depth value of the point to be measured, triangulation is adopted to map the disparity to the depth value using a triangular relationship.

[0036] It can be seen from the above technical scheme that the present application provides a method and system for obtaining depth values ​​based on a dynamic binarization algorithm, by obtaining a reference image and an infrared random dot matrix image of the object to be measured, and selecting any point of the infrared random dot matrix image as the point to be measured, obtaining the 8-bit grayscale image corresponding to the reference image and the point to be measured, and converting the reference image and the 8-bit grayscale image corresponding to the point to be measured into a 1-bit image through a local dynamic binarization model, and obtaining the corresponding 1-bit binarization value, and obtaining the matching cost value of different parallaxes of the point to be measured through a matching cost model, and selecting the minimum matching cost value as the preliminary parallax of the point to be measured; performing denoising and smoothing on the preliminary parallax to obtain the parallax of the point to be measured; and mapping the parallax of the point to be measured to the depth value of the point to be measured. The present application provides a method and system for obtaining depth values ​​based on a dynamic binarization algorithm, which can reduce the amount of calculation in the depth algorithm, thereby reducing the demand for the number of logic gates, and improving the area efficiency and power efficiency of the depth algorithm accelerator while providing a high-quality depth map. BRIEF DESCRIPTION OF THE DRAWINGS

[0037] In order to more clearly illustrate the technical solution of the present application, the drawings required for use in the embodiments are briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0038] Figure 1 A flowchart of a depth value acquisition method based on a dynamic binarization algorithm provided in an embodiment of the present application;

[0039] Figure 2 A schematic diagram of converting an infrared grayscale image into a binary infrared image provided in an embodiment of the present application;

[0040] Figure 3 A depth map generated based on a dynamic binarization algorithm provided in an embodiment of the present application;

[0041] Figure 4 Depth map generated by the existing absolute distance sum algorithm;

[0042] Figure 5 Depth map generated by the absolute distance sum algorithm for existing infrared image enhancement;

[0043] Figure 6 Depth maps generated for existing census conversion algorithms;

[0044] Figure 7A specific calculation implementation diagram for triangulation mapping depth values;

[0045] Figure 8 A line chart showing the performance comparison between the embodiment of the present application and other existing solutions;

[0046] Fig. 9 An architectural diagram of a depth value acquisition system based on a dynamic binarization algorithm provided in an embodiment of the present application. DETAILED DESCRIPTION

[0047] The following embodiments are described in detail, and examples thereof are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementations described in the following embodiments do not represent all implementations consistent with the present application. They are only examples of systems and methods consistent with some aspects of the present application as detailed in the claims.

[0048] See also Figure 1 , which is a flowchart of a depth value acquisition method based on a dynamic binarization algorithm provided in an embodiment of the present application.

[0049] In a first aspect of an embodiment of the present application, a method for obtaining a depth value based on a dynamic binarization algorithm is provided, comprising:

[0050] S1, obtaining a reference image and an infrared random dot matrix image of the object to be measured, and selecting any point of the infrared random dot matrix image as a point to be measured, wherein the reference image is an infrared random dot matrix image on a plane at a certain distance from a structured light camera.

[0051] In an embodiment of the present application, a structured light camera is used to obtain the depth value of the object to be measured. The infrared random dot matrix projector and the infrared camera in the structured light camera are used together to provide information of the random dot matrix reflected from the surface of the object. In the captured image, parallax will occur at positions with different depths from the reference image.

[0052] It should be noted that the specific steps of obtaining the reference image are: photographing a plane at a fixed distance (such as 1m) from the camera, obtaining an infrared random dot matrix image of the reference plane, and storing the photographed reference image inside the camera for subsequent parallax calculation.

[0053] S2, obtaining the 8-bit grayscale images corresponding to the reference image and the points to be measured, converting the reference image and the 8-bit grayscale images corresponding to the points to be measured into 1-bit images through a local dynamic binarization model, and obtaining corresponding 1-bit binarization values.

[0054] like Figure 2 As shown, it is a schematic diagram of converting an infrared grayscale image into a binary infrared image provided by an embodiment of the present application.

[0055] Wherein, the local dynamic binarization model is:

[0056]

[0057] W is a window centered on p (e.g., a 5 pixel x 5 pixel window). For a 5x5 window, W is 25, and p n is a pixel value in W, N is the number of pixels in W, p is an 8-bit grayscale value, and q is a 1-bit binary value.

[0058] S3, obtaining matching cost values ​​of different disparities of the test point through a matching cost model according to the 1-bit binary value.

[0059] Among them, the matching cost under different disparities is calculated through the window-based matching cost algorithm. The cost calculation is based on the binarized image, and the matching cost value of a certain range of disparities of a certain pixel is calculated. In the actual calculation, the binarized pixels inside the entire window are taken as a sequence, and the Hamming distance is used to evaluate the cost. The matching cost model is:

[0060]

[0061] C d is the matching cost of the disparity, q n is the pixel of the corresponding window in the 1-bit image of the point to be tested, q′ (n,d) is the pixel of the corresponding window in the 1-bit image of the reference image.

[0062] S4, selecting a minimum matching cost value according to the matching cost values ​​of different parallaxes of the point to be measured as a preliminary parallax of the point to be measured.

[0063] Among them, when selecting the minimum matching cost value, the following model is used:

[0064] d est =argmin(C d )

[0065] Among them, d est is the initial parallax of the point to be measured.

[0066] S5, performing noise elimination and smoothing on the preliminary disparity according to the preliminary disparity to obtain the disparity of the point to be measured.

[0067] Wherein, in the step of performing denoising and smoothing on the preliminary disparity to obtain the disparity of the point to be measured, sub-pixel estimation, speckle removal and a median filter are used to perform denoising and smoothing on the preliminary disparity.

[0068] Sub-pixel estimation uses a parabola fitting-based method to smooth the disparity using the cost value of the adjacent disparity. The formula is as follows:

[0069]

[0070] Among them, C(d) and C(d ±n ) is the matching cost on disparity d and d±n.

[0071] Speckle removal is to remove isolated small spots in the image by counting the number of surrounding pixels with large disparity values ​​​​from the central pixel. If the number exceeds a threshold, the central pixel is regarded as a spot and replaced with the nearest non-speckle pixel value.

[0072] A median filter, using a 3x3 window, is used to further improve smoothness.

[0073] S6, mapping the disparity of the point to be measured into a depth value of the point to be measured according to the disparity of the point to be measured.

[0074] In the step of mapping the disparity of the point to be measured to the depth value of the point to be measured, a triangulation method is used to map the disparity to the depth value using a triangular relationship.

[0075] like Figure 7 The figure shows a specific calculation implementation diagram of the depth value mapped by triangulation method.

[0076] In the figure, Z0 is the reference plane distance, Z is the object plane distance (ie, the depth value in the embodiment of the present application), f is the focal length of the infrared camera, d is the parallax, b is the baseline distance, and the formula for obtaining the depth value is specifically:

[0077]

[0078] In order to better verify the beneficial effects of the embodiments of the present application, the following will be described through specific embodiments:

[0079] First, a qualitative analysis is performed to compare the depth map generated by the dynamic binarization algorithm provided in the embodiment of the present application with the depth maps generated by the three algorithms in the prior art. Figure 3 As shown in FIG. 1 , a depth map generated based on a dynamic binarization algorithm is provided in an embodiment of the present application. Figure 4 As shown in FIG. 1 , the depth map generated by the existing Sum of Absolute Distance (SAD) algorithm is shown in FIG. Figure 5 As shown in FIG. 1 , the depth map generated by the existing infrared image enhanced absolute distance sum algorithm Enhanced Sum of Absolute Distance (Enhanced SAD) is shown in FIG. Figure 6As shown, a depth map is generated by the existing census transform algorithm Census Transform (CT).

[0080] Among them, black pixels represent the parts where the measurement error is greater than 100 mm. Figure 3 , Figure 4 , Figure 5 and Figure 6 It can be seen that the depth map generated based on the 1-bit dynamic binarization algorithm provided in the embodiment of the present application has an area of ​​the part with an error greater than 100 mm that is significantly smaller than other solutions.

[0081] Then, quantitative analysis was performed, such as Figure 8 As shown, it is a line graph comparing the performance of the embodiment of the present application with other existing solutions. Based on 70 scenes, the advantages of the solution of the embodiment of the present application compared with other solutions under the same window size are quantitatively evaluated with respect to several indicators. Among them, the performance indicators include the bad pixel percentage (Bad Pixel Percentage), the average absolute error (Average Absolute Error) and the root mean square error (Root-mean-square Error) under different thresholds. The horizontal axis of the coordinate is the window size (Window Size), and the signs of different shapes represent different algorithms. The smaller the values ​​of all indicators, the better the performance, and the more advantageous the algorithm. When the window size is greater than 13x13, the solution of the embodiment of the present application is more advantageous than other cutting-edge solutions in various indicators.

[0082] Finally, based on the solution of the embodiment of the present application, the area and power of the structured light camera hardware accelerator are evaluated. The evaluation of the area and power of the structured light depth algorithm accelerator based on DB (dynamic binarization algorithm involving the solution provided by the present application), SAD, Enhanced SAD and CT is realized through the SMIC 55nm CMOS process. A 17x17 matching window is used, the frequency is 133MHz, and the frame rate is 432.94 frames per second. The area efficiency and power efficiency are shown in Table 1, which is a comparison table of the area and power efficiency of the accelerator.

[0083] Table 1 - Comparison of area and power efficiency of accelerators

[0084]

[0085] As shown in Table 1, the logic gates of the cost calculation module of the DB-based accelerator are reduced by 79.7%-86.7% compared with other methods. For the entire structured light depth algorithm accelerator, compared with accelerators based on other methods, the area efficiency is improved by 235%-367%, and the power efficiency is improved by 35%-94%.

[0086] It can be seen from the above technical scheme that the embodiment of the present application provides a method for obtaining depth values ​​based on a dynamic binarization algorithm, by obtaining a reference image and an infrared random dot matrix image of the object to be measured, and selecting any point of the infrared random dot matrix image as the point to be measured, obtaining the 8-bit grayscale image corresponding to the reference image and the point to be measured, and converting the reference image and the 8-bit grayscale image corresponding to the point to be measured into a 1-bit image through a local dynamic binarization model, and obtaining the corresponding 1-bit binarization value, and obtaining the matching cost value of different parallaxes of the point to be measured through a matching cost model, and selecting the minimum matching cost value as the preliminary parallax of the point to be measured; performing denoising and smoothing on the preliminary parallax to obtain the parallax of the point to be measured; and mapping the parallax of the point to be measured to the depth value of the point to be measured. The embodiment of the present application provides a method for obtaining depth values ​​based on a dynamic binarization algorithm, which can reduce the amount of calculation in the depth algorithm, thereby reducing the demand for the number of logic gates, and improving the area efficiency and power efficiency of the depth algorithm accelerator while providing a high-quality depth map.

[0087] See also Fig. 9 , which is an architectural diagram of a depth value acquisition system based on a dynamic binarization algorithm provided in an embodiment of the present application.

[0088] A second aspect of an embodiment of the present application provides a depth value acquisition system based on a dynamic binarization algorithm, including: an image acquisition module, an image binarization module, a matching module, a screening module, a post-processing module and a mapping module.

[0089] S01, the image acquisition module is used to acquire a reference image and an infrared random dot matrix image of the object to be measured, and select any point of the infrared random dot matrix image as a point to be measured.

[0090] S02, the image binarization module is used to obtain the 8-bit grayscale image corresponding to the reference image and the point to be tested, and convert the 8-bit grayscale image corresponding to the reference image and the point to be tested into a 1-bit image through a local dynamic binarization model, and obtain the corresponding 1-bit binarization value.

[0091] S03, the matching module is used to obtain matching cost values ​​of different disparities of the test point through a matching cost model according to the 1-bit binary value.

[0092] S04, the screening module is used to select the minimum matching cost value as the preliminary disparity of the point to be measured according to the matching cost values ​​of different disparities of the point to be measured.

[0093] S05, the post-processing module is used to perform noise elimination and smoothing on the preliminary disparity according to the preliminary disparity to obtain the disparity of the point to be measured.

[0094] S06, the mapping module is used to map the disparity of the point to be measured into a depth value of the point to be measured according to the disparity of the point to be measured.

[0095] The reference image and infrared random dot matrix image of the object to be measured are input into the acquisition module, and any point of the infrared random dot matrix image is selected as the point to be measured; the acquisition module transmits the reference image and the point to be measured to the image binarization module, the image binarization module obtains the 8-bit grayscale image corresponding to the reference image and the point to be measured, and converts the reference image and the 8-bit grayscale image corresponding to the point to be measured into a 1-bit image through a local dynamic binarization model, and obtains the corresponding 1-bit binarization value; the image binarization module transmits the 1-bit binarization value to the matching module, and the matching module, based on the 1-bit binarization value, The matching cost values ​​of different parallaxes of the point to be measured are obtained by matching the cost model; the matching module transmits the matching cost values ​​of different parallaxes of the point to be measured to the screening module, and the screening module selects the minimum matching cost value as the preliminary disparity of the point to be measured according to the matching cost values ​​of different parallaxes of the point to be measured; the screening module transmits the preliminary disparity to the post-processing module, and the post-processing module performs denoising and smoothing on the preliminary disparity according to the preliminary disparity to obtain the disparity of the point to be measured, and the post-processing module transmits the disparity of the point to be measured to the mapping module, and the mapping module maps the disparity of the point to be measured to the depth value of the point to be measured according to the disparity of the point to be measured.

[0096] It can be seen from the above technical scheme that the embodiment of the present application provides a method and system for obtaining depth values ​​based on a dynamic binarization algorithm, by obtaining a reference image and an infrared random dot matrix image of the object to be measured, and selecting any point of the infrared random dot matrix image as the point to be measured, obtaining the 8-bit grayscale image corresponding to the reference image and the point to be measured, and converting the reference image and the 8-bit grayscale image corresponding to the point to be measured into a 1-bit image through a local dynamic binarization model, and obtaining the corresponding 1-bit binarization value, and obtaining the matching cost value of different parallaxes of the point to be measured through a matching cost model, and selecting the minimum matching cost value as the preliminary parallax of the point to be measured; performing denoising and smoothing on the preliminary parallax to obtain the parallax of the point to be measured; and mapping the parallax of the point to be measured to the depth value of the point to be measured. The embodiment of the present application provides a method and system for obtaining depth values ​​based on a dynamic binarization algorithm, which can reduce the amount of calculation in the depth algorithm, thereby reducing the demand for the number of logic gates, and improving the area efficiency and power efficiency of the depth algorithm accelerator while providing a high-quality depth map.

[0097] Similar parts between the embodiments provided in this application can be referenced to each other. The specific implementation methods provided above are only a few examples under the general concept of this application and do not constitute a limitation on the protection scope of this application. For those skilled in the art, any other implementation methods expanded based on the scheme of this application without creative work belong to the protection scope of this application.

Claims

1. A depth value acquisition method based on a dynamic binarization algorithm, characterized in that: include: Obtain a reference image and an infrared random dot matrix image of the object to be measured, and select any point of the infrared random dot matrix image as the point to be measured, wherein the reference image is an infrared random dot matrix image on a plane at a certain distance from the structured light camera; Obtaining the 8-bit grayscale images corresponding to the reference image and the point to be measured, converting the reference image and the 8-bit grayscale images corresponding to the point to be measured into 1-bit images through a local dynamic binarization model, and obtaining corresponding 1-bit binarization values; According to the 1-bit binary value, a matching cost value of different disparities of the test point is obtained through a matching cost model; According to the matching cost values ​​of different parallaxes of the point to be measured, a minimum matching cost value is selected as the preliminary parallax of the point to be measured; According to the preliminary disparity, denoising and smoothing the preliminary disparity is performed to obtain the disparity of the point to be measured; According to the disparity of the point to be measured, mapping the disparity of the point to be measured into a depth value of the point to be measured; The local dynamic binarization model is: W is a window centered on p, p n is a pixel value in W, N is the number of pixels in W, p is an 8-bit grayscale value, and q is a 1-bit binary value; The matching cost model is: C d is the matching cost of the disparity, q n is the pixel of the corresponding window in the 1-bit image of the point to be tested, q' (n,d) is the pixel of the corresponding window in the 1-bit image of the reference image.

2. The depth value acquisition method based on the dynamic binarization algorithm according to claim 1 is characterized in that: In the step of performing denoising and smoothing on the preliminary disparity to obtain the disparity of the point to be measured, sub-pixel estimation, speckle removal and a median filter are used to perform denoising and smoothing on the preliminary disparity.

3. The depth value acquisition method based on the dynamic binarization algorithm according to claim 1 is characterized in that: In the step of mapping the disparity of the point to be measured to the depth value of the point to be measured, a triangulation method is used to map the disparity to the depth value using a triangular relationship.

4. A depth value acquisition system based on a dynamic binarization algorithm, characterized in that: The depth value acquisition system based on the dynamic binarization algorithm is used to execute the depth value acquisition method based on the dynamic binarization algorithm according to any one of claims 1 to 3, comprising: an image acquisition module, an image binarization module, a matching module, a screening module, a post-processing module and a mapping module; The image acquisition module is used to acquire a reference image and an infrared random dot matrix image of the object to be measured, and select any point of the infrared random dot matrix image as a point to be measured; The image binarization module is used to obtain the 8-bit grayscale images corresponding to the reference image and the points to be measured, convert the reference image and the 8-bit grayscale images corresponding to the points to be measured into 1-bit images through a local dynamic binarization model, and obtain corresponding 1-bit binarization values; The matching module is used to obtain matching cost values ​​of different disparities of the test point through a matching cost model according to the 1-bit binary value; The screening module is used to select the minimum matching cost value as the preliminary disparity of the point to be measured according to the matching cost values ​​of different disparities of the point to be measured; The post-processing module is used to perform noise elimination and smoothing on the preliminary disparity according to the preliminary disparity to obtain the disparity of the point to be measured; The mapping module is used to map the disparity of the point to be measured into a depth value of the point to be measured according to the disparity of the point to be measured.

5. A depth value acquisition system based on a dynamic binarization algorithm according to claim 4, characterized in that: The local dynamic binarization model is: W is a window centered on p, p n is a pixel value in W, N is the number of pixels in W, p is an 8-bit grayscale value, and q is a 1-bit binary value.

6. A depth value acquisition system based on a dynamic binarization algorithm according to claim 4, characterized in that: The matching cost model is: C d is the matching cost of the disparity, q n is the pixel of the corresponding window in the 1-bit image of the point to be tested, q' (n,d) is the pixel of the corresponding window in the 1-bit image of the reference image.

7. A depth value acquisition system based on a dynamic binarization algorithm according to claim 4, characterized in that: In the step of performing denoising and smoothing on the preliminary disparity to obtain the disparity of the point to be measured, sub-pixel estimation, speckle removal and a median filter are used to perform denoising and smoothing on the preliminary disparity.

8. The depth value acquisition system based on the dynamic binarization algorithm according to claim 4, characterized in that: In the step of mapping the disparity of the point to be measured to the depth value of the point to be measured, a triangulation method is used to map the disparity to the depth value using a triangular relationship.

Citation Information

Patent Citations

  • A hybrid depth estimation method based on light field data

    CN109360235A

  • Depth image generation method and device

    CN112750157A