A monocular single-frequency binocular structured light dynamic three-dimensional reconstruction method
By adopting a binocular structured light dynamic 3D reconstruction method based on single-frame single-frequency, the problem of inconsistent phase unfolding of multiple isolated objects in traditional methods is solved, and efficient 3D reconstruction of multiple isolated objects is achieved, which is suitable for dynamic object measurement.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-01-09
- Publication Date
- 2026-05-15
AI Technical Summary
Traditional mass-guided phase unwrapping methods based on single-frequency fringes suffer from inconsistent phase unwrapping between the left and right views when performing phase unwrapping on multiple isolated objects, making it impossible to effectively reconstruct the 3D of multiple isolated objects.
A binocular structured light dynamic 3D reconstruction method based on single-frame single-frequency is adopted. By constructing a binocular structured light vision system, calibrating camera parameters using a checkerboard calibration board, projecting grating fringe images and performing epipolar correction, using Hilbert transform to obtain the wrap phase, performing phase filtering and stereo matching in different regions, and combining regional multi-view phase unfolding and stereo matching algorithms, the initial point of phase unfolding is established to generate a dense point cloud map.
It enables high-quality 3D reconstruction of multiple isolated objects by acquiring only one single-frequency grating fringe image, improving the consistency and efficiency of phase unfolding, and is suitable for 3D reconstruction of dynamic objects.
Smart Images

Figure CN116129033B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of optical three-dimensional measurement technology, specifically a method for dynamic three-dimensional reconstruction based on single-frame single-frequency binocular structured light. Background Technology
[0002] In the field of optical 3D measurement, structured light 3D measurement methods have been widely applied in defect detection, cultural relic protection, robot vision, and many other fields due to their high precision, full-field coverage, and non-contact nature. Binocular fringe structured light 3D measurement, as a widely used optical 3D measurement method, uses two cameras to acquire images of the object under test from different perspectives, and uses fringe structured light information to assist in the high-precision, dense point cloud 3D reconstruction. In binocular fringe structured light projection 3D reconstruction methods, the method based on unfolded phase and sub-pixel disparity matching to convert to depth is widely used in industrial inspection due to its high precision and good robustness. A multi-frequency grating fringe image is projected onto the surface of the object under test by a projector. Modulated by the height information of the object's surface, the fringe image projected onto the surface of the object under test undergoes deformation. After the camera acquires the deformed fringe image, its unfolded phase is calculated, and the depth information of the object under test is obtained through disparity matching and depth conversion.
[0003] For phase unwrapping of complex objects such as isolated objects and objects with discontinuous depth, multiple frequency acquisition methods are usually required, such as the multi-frequency heterodyne time phase unwrapping method (Pe S, Hug and So Z. Fast three-step phase-shifting algorithm[J]. Appl. Opt, 2006, 45: 5086-5091.); and phase unwrapping methods with a single frequency and an auxiliary image, such as single-frequency fringe series prediction by embedding speckle, and composite encoding of single-frequency fringe and Gray code phase (Wu Z, Guo W, Li Y, et al. High-speed and high-efficiency three-dimensional shape measurement based on Gray-coded light[J]. Photonics Research, 2020, 8(6): 819-829.). Single-frequency phase unwrapping without auxiliary images requires less acquisition time and is more suitable for measuring dynamic objects. For example, although the traditional spatial quality-oriented phase unwrapping method only requires a single frequency phase, it can only achieve phase unwrapping and 3D reconstruction of a single object in stereo vision and cannot be used for phase unwrapping and 3D reconstruction of multiple isolated objects.
[0004] Traditional mass-guided phase unwrapping methods based on single-frequency fringes do not require additional auxiliary image acquisition, but they suffer from inconsistencies in phase unwrapping between the left and right views when performing phase unwrapping on multiple isolated objects. To address this issue, this invention proposes a binocular structured light dynamic 3D reconstruction method based on a single-frame, single-frequency image. Summary of the Invention
[0005] In view of this, the present invention aims to propose a binocular structured light dynamic 3D reconstruction method based on single-frame single-frequency imaging, suitable for high-precision dynamic measurement, and solves the problem of inconsistent phase unfolding of isolated objects in the left and right views when using the mass-guided phase unfolding method to unfold multiple isolated objects. The flowchart of the invention is as follows. Figure 1 As shown.
[0006] To achieve the above objectives, this invention proposes a binocular structured light dynamic 3D reconstruction method based on single-frame single-frequency imaging, comprising the following steps:
[0007] S1: Construct a binocular structured light vision system, including two cameras and one projector;
[0008] The two cameras and the projector are placed horizontally at a certain angle so that the two cameras have more of a shared field of view, and the projector is placed between the two cameras.
[0009] S2: Calibrate the binocular vision system to obtain the intrinsic and extrinsic parameters of the two binocular cameras;
[0010] The binocular imaging system is calibrated using a checkerboard calibration tool. The checkerboard calibration tool is moved and rotated multiple times within the common imaging area of the binocular cameras to maximize its position within the common imaging area. The acquired calibration tool images are used to calibrate the binocular cameras and obtain the intrinsic and extrinsic parameters of the left and right cameras.
[0011] S3: Project a grating fringe image onto the object being measured, trigger the camera to acquire the image, and perform epipolar correction;
[0012] A grating fringe image is projected onto the object under test using a projector. A hard-triggered binocular camera then acquires a distorted fringe image modulated by the object. The light intensity distribution of the acquired grating fringe image is represented as:
[0013]
[0014] Where I (x,y) For a camera to capture the light intensity of a fringe pattern at a certain pixel (x, y), I′ (x,y) and I″ (x,y) These represent the background light intensity and the modulated light intensity of the pixel, respectively. Let f be the phase at that point, and f be the carrier frequency.
[0015] Based on the intrinsic and extrinsic parameters of the binocular camera obtained from camera calibration, epipolar correction is performed on the acquired grating fringe images to ensure that corresponding points in the left and right fringe patterns are on the same horizontal line.
[0016] S4: Use Hilbert transform to obtain the wrapping phase and perform phase filtering;
[0017] The collected stripes are decomposed to extract stripe information Fr L 、Fr R and background information Bg L Bg R The Hilbert transform is used to extract the real and imaginary parts of the fringe pattern, and the wrap phase at each point of the measured object is obtained. The wrap phase is:
[0018]
[0019] Where imV and imT are the imaginary and real parts of the signal obtained by performing a Hilbert transform on a single fringe pattern, respectively. The enclosed phase is then determined. Then, a modulation filter is used to remove redundant noise, the phase value of the non-object region is set to zero, and a binary phase Bw corresponding to the wrapped phase is generated.
[0020] S5: Calculate the region and edge information of each isolated object in the phase wrapper of the right camera;
[0021] After filtering in step S4, the binary phase Bw of the corresponding right camera is binarized, setting the object region to 1 and the non-object region to 0. (See attached image) Figure 2 As shown, the binarized Bw is traversed to find the set of pixel coordinates of all points around the edge of each isolated object, segmenting the regions of each isolated object. Finally, sets with fewer coordinate points are removed to eliminate noise that was not filtered out by the wrapping phase modulation filter. Based on the coordinates of each set point, the top, bottom, left, and right pixel coordinates of the region where each isolated object is located are obtained, which are the edge coordinates of the region where each isolated object is located.
[0022] S6: Calculate the region and edge information of each isolated object in the phase wrapper of the left camera;
[0023] The coordinates of each point on the edge of each isolated object in the corresponding right camera wrapper phase obtained in step S5 are obtained through the left and right background images Bg. L and Bg R The disparity value is calculated based on a stereo matching algorithm. The coordinates of each point on the edge of the isolated object in the corresponding right camera view and the coordinates of the region edge of each isolated object in the left camera view are then obtained from the calculated disparity value and the coordinates of the isolated object's edge in the right camera view. The disparity matching cost (SSD) is:
[0024]
[0025] Where I l I r These are the background images Bg for the corresponding left and right views. L Bg R x and y are the edge coordinates of each isolated object in the right camera view. The disparity value is the value corresponding to the minimum matching cost SSD(x, y, d). (2m+1)×(2n+1) is the size of the matching cost aggregation window.
[0026] S7: Mass-guided phase unfolding based on the initial point of the multi-view corresponding to the region;
[0027] Step S6 yields the coordinates of the edges of each isolated object in the corresponding left and right views. (See attached image.) Figure 3 As shown, to ensure high applicability and accuracy of the system, this invention uses a regional stereo phase unfolding method related to the left and right views. For each isolated object region, the coordinates of the leftmost edge of the middle row of the region containing each isolated object in the right view are selected. Starting from the x-axis, traverse the wrapped phase map from left to right. Find the point (x, y) where the first wrapped phase value jump occurs within the wrapped phase of the right view. R ), and point The coordinate offset is d′. Using this corresponding point as a reference, a phase stabilization point shifted one pixel to the right is selected as the initial point (x, y) for the quality-guided phase unfolding of the right view. R +1). Left view with Starting from this point, similarly find the initial point (x, y) for the mass-guided phase expansion of the left view. L +1). The initial point discrimination condition for phase expansion of the left and right views is shown in the following equation:
[0028]
[0029] in, Wrap the phase in the left view (x, y) L The wrapping phase value of point ) Wrap the phase in the left view (x, y) R The wrapping phase value of point (x, y) is determined when the above condition is satisfied. L +1) and point (x, y) R +1) are the initial points for phase expansion in the left and right views respectively.
[0030] In step S5, phase unfolding is performed within the region containing each isolated object using the mass-guided phase unfolding method, starting from the initial phase unfolding point of the corresponding left and right views. The unfolded phases of each isolated object are then merged into a single complete unfolded phase map, as shown in the attached diagram. Figure 4 As shown, the phase unfolding of the entire view is completed.
[0031] S8: Stereo matching is used to obtain subpixel parallax and convert it into depth information and world 3D coordinates to generate a dense point cloud map of the object, thus completing the 3D reconstruction of the object.
[0032] The unfolded phase maps corresponding to the left and right cameras obtained in step S7 are divided into regions based on the isolated object regions obtained in step S6. The SSD stereo matching algorithm is used to perform disparity matching on the unfolded phase maps of the left and right cameras. When performing disparity matching in each region, the disparity range of adjacent points to be matched is constrained based on the disparity value obtained from the previous matching point according to the unfolded phase characteristics. This reduces the disparity matching range of the points to be matched to the neighborhood of the disparity value of the previous matching point, thereby reducing the disparity matching range and improving the disparity matching efficiency.
[0033] To further improve accuracy, a quadratic curve subpixel interpolation method is used to convert integer-pixel disparity data into subpixel disparity data, thereby further improving disparity accuracy. The subpixel disparity is calculated as D:
[0034]
[0035] Where D and d represent the sub-pixel and integer disparity of point p, respectively. d′, d′-1, and d′+1 are the positions with the minimum SSD stereo matching cost corresponding to point p, and their left and right adjacent positions, respectively. C SSD (p, d′), C SSD (p, d′-1) and C SSD (p, d′+1) represent the SSD stereo matching costs corresponding to point p at positions d′, d′-1, and d′+1, respectively.
[0036] After obtaining the sub-pixel disparity of each isolated region, they are merged into a complete disparity map. Based on the intrinsic parameters of the binocular camera obtained from the camera calibration in step S2, the depth information of each point is obtained through the depth transformation formula z = fb / D (where f is the focal length of the camera, b is the baseline length of the camera, and D is the obtained sub-pixel disparity). Combined with the extrinsic parameters of the camera obtained from the calibration in step S2, the coordinate information of each point is transformed from the pixel coordinate system to the world coordinate system and its corresponding point cloud information is generated.
[0037] This invention also proposes a binocular structured light dynamic 3D reconstruction device based on single-frame single-frequency imaging, specifically comprising:
[0038] The vision system module is used to build a binocular striped structured light vision system, which includes two cameras and a projector;
[0039] The calibration module calibrates the binocular vision system to obtain the intrinsic and extrinsic parameters of the two cameras;
[0040] The stripe projection acquisition module is used to project a grating stripe image onto the object being measured and trigger the binocular camera to acquire it.
[0041] The epipolar correction module is used to perform epipolar correction on the stripe image based on the intrinsic and extrinsic parameters of the binocular camera.
[0042] The phase unpacking module is used for phase unpacking of left and right fringe patterns using a Hilbert transform and a region-based corresponding point stereo mass-guided method.
[0043] The stereo matching module is used to perform stereo matching on the left and right unfolded phases and obtain the disparity of the matching points corresponding to the left and right unfolded phases.
[0044] The depth information conversion module is used to combine the intrinsic and extrinsic parameters calibrated by the binocular camera and convert parallax into depth information using the parallax principle.
[0045] The 3D reconstruction module is used to generate a dense point cloud map of an object based on its 3D spatial coordinates, thus completing the 3D reconstruction of the object.
[0046] The present invention also proposes a terminal, the terminal comprising one or more processors; a storage device for storing one or more programs; when the one or more programs are executed by the one or more processors, the one or more processors implement the above-described binocular camera 3D reconstruction method based on a single stripe.
[0047] The present invention also proposes a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described method for three-dimensional reconstruction using a binocular camera based on a single stripe.
[0048] Compared with existing technologies, the binocular structured light dynamic 3D reconstruction method based on single-frame single-frequency imaging of the present invention has the following advantages:
[0049] (1) This invention only needs to acquire one single-frequency grating stripe image to complete the high-quality three-dimensional reconstruction of multiple isolated objects, and can be used for the three-dimensional reconstruction of dynamic objects;
[0050] (2) The present invention uses a regional phase unfolding method to perform phase unfolding on the region where the object under test is located. Compared with the traditional mass-guided phase unfolding method based on single-stripes, it ensures the consistency of the binocular left and right unfolding phases of multiple isolated objects and effectively reduces the phase unfolding time.
[0051] (3) This invention uses two methods to reduce stereo matching time. First, it matches disparity only for the region where an isolated object is located each time, reducing the matching area range; second, it constrains the disparity range to be matched for the next matching point based on the disparity of the previous matching point, reducing the disparity matching range and improving disparity matching efficiency. Attached Figure Description
[0052] The accompanying drawings, which form part of this invention, are used to provide a further understanding of the invention. The illustrative embodiments of the invention and their descriptions are used to explain the invention and do not constitute an undue limitation of the invention. In the drawings:
[0053] Figure 1 This is a flowchart of a binocular structured light dynamic three-dimensional reconstruction method based on single-frame single-frequency imaging according to the present invention;
[0054] Figure 2 This is a diagram showing the edge shape of the object being measured in this invention.
[0055] Figure 3 This is a matching diagram of the initial point of the wrapping phase in this invention;
[0056] Figure 4 This is a phase diagram for the present invention;
[0057] Figure 5 This is a camera pose diagram of the imaging system of the present invention;
[0058] Figure 6 This is a schematic diagram illustrating the calibration reprojection error of the imaging system of the present invention;
[0059] Figure 7 This is a schematic diagram of the system structure of the present invention;
[0060] Figure 8 This is a schematic diagram of the system flow of the present invention. Detailed Implementation
[0061] It should be noted that, unless otherwise specified, the embodiments and features described in the present invention can be combined with each other.
[0062] In the description of this invention, it should be understood that the terms "center," "longitudinal," "lateral," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," and "outer," etc., indicating orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. Furthermore, the terms "first," "second," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined with "first," "second," etc., may explicitly or implicitly include one or more of that feature. In the description of this invention, unless otherwise stated, "a plurality of" means two or more.
[0063] In the description of this invention, it should be noted that, unless otherwise explicitly specified and limited, the terms "installed," "connected," "linked," and "complete" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal communication between two components. The object may not be complete, but including completeness is the preferred implementation method. For those skilled in the art, the specific meaning of the above terms in this invention can be understood through the specific circumstances.
[0064] The present invention will now be described in detail with reference to the accompanying drawings and embodiments.
[0065] To better understand the above technical solutions, the following will provide a detailed explanation of the technical solutions in conjunction with the accompanying drawings and the preferred embodiments.
[0066] This invention proposes a dynamic three-dimensional reconstruction method based on single-frame single-frequency binocular structured light. The invention will be described in more detail below with reference to the accompanying drawings and specific embodiments.
[0067] In this embodiment, a MetaBird simulated bird is used as the measurement object, including the following steps:
[0068] Step 1: Binocular camera calibration:
[0069] This invention uses a checkerboard calibration board with 8×11 corner points and 20mm side length as a calibration tool to calibrate a binocular system. This invention employs the Zhang Zhengyou calibration method for stereo calibration of the binocular vision system, acquiring 30 sets of checkerboard images in various regions within the shared field of view of the binocular cameras. The camera pose diagram is attached. Figure 5 As shown in the attached figure, the calibration reprojection error is as follows. Figure 6 As shown.
[0070] Step 2, Polar Correction and Phase Unfolding:
[0071] This invention proposes a region-based quality-guided phase unfolding method to obtain the unfolded phase of the left and right views. A grating fringe image with a wavelength of 16 nm is projected onto the object under test using a projector, as shown in the attached figure. Figure 7 As shown, the binocular camera is triggered to acquire the modulated grating stripe image of the object under test, and the acquired stripe image is epipolar corrected according to the camera intrinsic and extrinsic parameters obtained in step one, so that the corresponding points are all on the same horizontal line.
[0072] The acquired fringe pattern is decomposed to separate the fringe and background information. The resulting fringe information is then processed using the Hilbert transform method to obtain the wrapping phase. The obtained wrapping phase is filtered, setting the wrapping phase value of non-object regions within the wrapping phase to zero. Then, a quality-guided method based on the initial point of each isolated object region is used for phase unfolding. Each time an isolated object region is unfolded, corresponding points on the left and right wrapping phase edges are established through background image disparity matching. Based on the phase step characteristics of the wrapping phase, corresponding initial points for phase unfolding are established, and phase unfolding is performed using the quality-guided method starting from these initial points.
[0073] Step 3, Subpixel Parallax Matching:
[0074] Disparity matching obtains the disparity information of an object between two views by minimizing the absolute phase difference along the epipolar line. To obtain more accurate depth information, this invention uses quadratic curve subpixel interpolation to achieve subpixel disparity calculation.
[0075] To improve disparity matching efficiency, this invention uses an improved SSD algorithm for disparity matching. Specifically, it includes the following:
[0076] Automatically select the matching range and perform parallax matching in the region where each isolated object is located by detecting the edge coordinates of each isolated object, thereby reducing invalid region matching.
[0077] An adaptive constraint is applied to the disparity range. Based on the disparity value of the previous matching point, the disparity range of adjacent points to be matched is constrained, reducing the disparity range to be matched to the area around the disparity value of the previous matching point. This reduces meaningless matching and significantly shortens the disparity matching time.
[0078] Step 4: Acquire depth information and reconstruct the point cloud:
[0079] In step three, the disparity corresponding to each point in the left and right unfolded phase of the object under test is obtained. Based on the camera intrinsic parameters obtained in step one and the depth conversion formula z = fb / D, the matched disparity is converted into the depth information of the object under test, where f is the focal length of the camera, b is the distance between the optical centers of the two virtual cameras, and D is the sub-pixel disparity information matched in step three. After obtaining the depth value z of the corresponding point in the image, the coordinate information of each point is converted from the pixel coordinate system to the world coordinate system by combining the camera extrinsic parameters obtained in step one. The dense point cloud information of the object is then reconstructed, and the three-dimensional reconstruction of the object is completed.
[0080] The point cloud image reconstructed by the virtual binocular striped structured light 3D reconstruction technology proposed in this invention is shown in the attached figure. Figure 8 As shown.
[0081] This invention also proposes a binocular structured light dynamic 3D reconstruction device based on single-frame single-frequency imaging, specifically comprising:
[0082] The vision system module is used to build a binocular striped structured light vision system, which includes two cameras and a projector;
[0083] The calibration module calibrates the binocular vision system to obtain the intrinsic and extrinsic parameters of the two cameras;
[0084] The stripe projection acquisition module is used to project a grating stripe image onto the object being measured and trigger the binocular camera to acquire it.
[0085] The epipolar correction module is used to perform epipolar correction on the stripe image based on the intrinsic and extrinsic parameters of the binocular camera.
[0086] The phase unpacking module is used for phase unpacking of left and right fringe patterns using a Hilbert transform and a region-based corresponding point stereo mass-guided method.
[0087] The stereo matching module is used to perform stereo matching on the left and right unfolded phases and obtain the disparity of the matching points corresponding to the left and right unfolded phases.
[0088] The depth information conversion module is used to combine the intrinsic and extrinsic parameters calibrated by the binocular camera and convert parallax into depth information using the parallax principle; the 3D reconstruction module is used to generate a dense point cloud map of the object based on its 3D spatial coordinates to complete the 3D reconstruction of the object.
[0089] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for dynamic 3D reconstruction based on single-frame, single-frequency binocular structured light, characterized in that: Includes the following steps: S1: Construct a binocular vision system, including two cameras and a projector; S2: Calibrate the binocular vision system to obtain the intrinsic and extrinsic parameters of the two binocular cameras; S3: Project a grating fringe image onto the object being measured, trigger the camera to acquire the image, and perform epipolar correction; S4: Use Hilbert transform to obtain the wrapping phase and perform phase filtering; S5: Calculate the region and edge information of each isolated object in the phase wrapper of the right camera; S6: Calculate the region and edge information of each isolated object in the phase wrapper of the left camera; S7: Mass-guided phase unfolding based on the initial point of the multi-view corresponding to the region; S8: Stereo matching is used to obtain subpixel disparity and convert it into depth information and world 3D coordinates to generate a dense point cloud map of the object and complete the 3D reconstruction of the object. In step S3, the grating stripe image projected onto the surface of the object under test has a wavelength of 16. The light intensity distribution of the stripe image after hard trigger acquisition and modulation is represented as follows: Where I (x,y) For a given pixel (x, y), the camera captures the fringe pattern light intensity, I′ (x,y) and I″ (x,y) These represent the background light intensity and the modulated light intensity of the pixel, respectively. Here, f is the principal phase value at that point, and f is the carrier frequency. In step S4, the stripe information Fr is extracted from the corrected grating stripe image obtained in step S3 through image decomposition. L 、Fr R and background information Bg L Bg R The Hilbert transform is used to extract the real and imaginary parts of the fringe pattern, and the wrap phase at each point of the measured object is obtained. The wrap phase is: Where imV and imT are the imaginary and real parts of the Hilbert transform obtained from a single fringe pattern, respectively; the wrapping phase is then calculated. Then, a modulation filter is used to remove redundant noise, the phase value of the non-object region is set to zero, and a binary phase Bw corresponding to the wrapped phase is generated.
2. The method for dynamic three-dimensional reconstruction based on single-frame single-frequency binocular structured light according to claim 1, characterized in that: In step S5, the binary phase Bw of the right camera corresponding to the filtering in step S4 is binarized, setting the object region to 1 and the non-object region to 0. The binarized Bw is traversed to find the set of pixel coordinates of each point around the edge of each isolated object, and finally the set with fewer coordinate points is removed to remove noise that was not filtered out by the phase modulation filter. Based on the coordinates of each set point, the top, bottom, left, and right pixel coordinates of the region where each isolated object is located are obtained, that is, the edge coordinates of the region where each isolated object is located.
3. The method for dynamic three-dimensional reconstruction based on single-frame single-frequency binocular structured light according to claim 1, characterized in that: In step S6, the coordinates of each point on the edge of each isolated object in the corresponding right camera wrap-around phase obtained in step S5 are compared with the left and right background images Bg. L and Bg R The disparity value of each edge point is calculated using the SSD-based stereo matching algorithm. The coordinates of each edge point of the corresponding isolated object in the left camera view and the edge coordinates of the region where each isolated object is located are obtained from the calculated disparity values and the edge coordinates of the isolated object's edge in the right camera view, using the corresponding coordinates of the isolated object's edge in the right camera view. The disparity matching cost (SSD) is: Where I l I r These are the background images Bg for the corresponding left and right views. L Bg R x and y are the edge coordinates of each isolated object in the right camera view. The disparity value is the value corresponding to the minimum matching cost SSD(x, y, d). (2m+1)×(2n+1) is the size of the matching cost aggregation window.
4. The method for dynamic three-dimensional reconstruction based on single-frame single-frequency binocular structured light according to claim 1, characterized in that: In step S7, the edge coordinates of each isolated object in the left and right views are obtained through step S6. Taking the leftmost row of edge coordinates of each isolated object in the right view as the starting point, the right view's wrapping phase is traversed to the right along the same row to find the point where the first wrapping phase value jumps within the right view's wrapping phase. The stable point that shifts one pixel to the right of this point is selected as the initial point for the corresponding right view's quality-guided phase unfolding. Similarly, taking the corresponding point of the right view's phase unfolding initial point corresponding to the left view's wrapping phase as the starting point, the corresponding left view's phase unfolding initial point is found through traversal. These two points are two corresponding points within the left and right views, thus ensuring that the unfolded phase values of each point in the left and right views correspond to each other. In step S5, phase unfolding is performed in the region where each isolated object is located, starting from the phase unfolding initial point of the corresponding left and right views. The unfolded phase of each isolated object is then merged into a complete unfolded phase map to complete the phase unfolding of the entire view.
5. The method for dynamic three-dimensional reconstruction based on single-frame single-frequency binocular structured light according to claim 1, characterized in that: In step S8, the unfolded phase maps corresponding to the left and right cameras obtained in step S7 are divided into regions based on the isolated object regions obtained in step S6. The SSD stereo matching algorithm is used to perform disparity matching on the unfolded phase maps of the left and right cameras. When performing disparity matching in each region, the disparity range of adjacent points to be matched is constrained based on the disparity value obtained from the previous matching point according to the unfolded phase characteristics. The disparity matching range of the points to be matched is reduced to the vicinity of the disparity value of the previous matching point, thus reducing the disparity matching range. To further improve accuracy, a quadratic curve subpixel interpolation method is used to convert integer-pixel disparity data into subpixel disparity data, thereby further improving disparity accuracy; the subpixel disparity D is obtained as: Where D and d are the sub-pixel and integer disparity of point p, respectively; d′, d′-1, and d′+1 are the positions with the minimum SSD stereo matching cost corresponding to point p, and the left and right adjacent positions, respectively; C SSD (p, d′), C SSD (p, d′-1) and C SSD (p, d′+1) represent the SSD stereo matching costs corresponding to point p at positions d′, d′-1, and d′+1, respectively. After obtaining the sub-pixel disparity of each isolated region, they are merged into a complete disparity map. Based on the intrinsic parameters of the binocular camera obtained from the camera calibration in step S2, the depth information of each point is obtained through the depth transformation formula z = fb / D (where f is the focal length of the camera, b is the baseline length of the camera, and D is the obtained sub-pixel disparity). Combined with the extrinsic parameters of the camera obtained from the calibration in step S2, the coordinate information of each point is transformed from the pixel coordinate system to the world coordinate system and its corresponding point cloud information is generated.
6. A binocular structured light dynamic 3D reconstruction system based on single-frame single-frequency imaging, used to execute the binocular structured light dynamic 3D reconstruction method based on single-frame single-frequency imaging as described in any one of claims 1-5, characterized in that, include: The vision system module is used to build a binocular striped structured light vision system, which includes two cameras and a projector; The calibration module calibrates the binocular vision system to obtain the intrinsic and extrinsic parameters of the two cameras; The stripe projection acquisition module is used to project a grating stripe image onto the object being measured and trigger the binocular camera to acquire it. The epipolar correction module is used to perform epipolar correction on the stripe image based on the intrinsic and extrinsic parameters of the binocular camera. The phase unpacking module is used for phase unpacking of left and right fringe patterns using a Hilbert transform and a region-based corresponding point stereo mass-guided method. The stereo matching module is used to perform stereo matching on the left and right unfolded phases and obtain the disparity of the matching points corresponding to the left and right unfolded phases. The depth information conversion module is used to combine the intrinsic and extrinsic parameters calibrated by the binocular camera and convert parallax into depth information using the parallax principle. The 3D reconstruction module is used to generate a dense point cloud map of an object based on its 3D spatial coordinates, thus completing the 3D reconstruction of the object.
7. A terminal, characterized in that: The terminal includes one or more processors; a storage device for storing one or more programs; when the one or more programs are executed by the one or more processors, the one or more processors implement the binocular structured light dynamic three-dimensional reconstruction method based on single-frame single-frequency as described in any one of claims 1-5.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When executed by the processor, the program implements the binocular structured light dynamic 3D reconstruction method based on single-frame single-frequency as described in any of claims 1-5.