An improved four-step phase-shifting unwrapping method based on wavelet transform

By adopting wavelet transformation and improving the four-step phase shift dewrapping method in structured light measurement technology, the phase error problem is solved and the accuracy of three-dimensional reconstruction is significantly improved.

CN115205145BActive Publication Date: 2025-06-27CHANGZHOU UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210820100.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-13
Publication Date
2025-06-27
Estimated Expiration
2042-07-13

AI Technical Summary

Technical Problem

In the existing structured light measurement technology, due to camera shake and random noise during camera shooting, the grating stripe pattern is non-sinearized, and phase errors are introduced, affecting the accuracy of three-dimensional reconstruction.

Method used

The improved four-step phase shift de-packing method based on wavelet transformation is adopted, and the wavelet transformation is used to denoise through Wiener filtering and bilateral filtering, and the high-frequency and low-frequency processing is performed using wavelet transformation. The packaging phase is solved through the four-step phase shift de-packing formula, and finally the packaging phase accuracy is improved through the fusion formula.

Benefits of technology

It greatly reduces the impact of noise on the wrapping phase, improves the accuracy of structured light systems, and provides a more accurate foundation for three-dimensional reconstruction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115205145B_ABST
    Figure CN115205145B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of image processing, and in particular to an improved four-step phase-shifting phase unwrapping method based on wavelet transform, which includes generating fringe patterns with different phases at the same frequency by using the phase-shifting formula to generate camera fringe patterns; denoising the camera fringe patterns by using the Wiener filtering algorithm and the bilateral filtering algorithm respectively; performing high-frequency and low-frequency processing on the two denoised camera fringe patterns by using wavelet transform; dividing the fringe patterns with different phases after wavelet processing into four groups, and using the N-step phase-shifting phase unwrapping formula and the phase-shifting formula to obtain the four-step phase-shifting wrapped phase; and fusing the four groups of four-step phase-shifting wrapped phases through a fusion formula. The present invention solves the problem of phase error caused by the non-sinusoidalization of grating fringes and random noise in the phase-shifting grating fringe pattern obtained by camera shooting in structured light. The method of the present invention has simple equipment and low cost, and greatly improves the accuracy of the structured light system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of image processing, and in particular to an improved four-step phase-shifting unwrapping method based on wavelet transform. Background Art

[0002] Structured light measurement technology is a method of three-dimensional measurement technology. It mainly uses a projection device to project different types of structured light onto the object to be measured, and captures the structured light image that is deformed by the modulation of the surface of the object to be measured. The height of the object to be measured placed is different, and the degree of phase change of the grating also varies accordingly. The three-dimensional shape information of the object surface is carried in the phase change of the two-dimensional plane deformation fringes. Therefore, by obtaining the phase change value, the height of the object at the corresponding point can be obtained, and thus the contour shape of the three-dimensional object can be obtained. However, when calculating the principal value of the phase, due to camera jitter and the addition of random noise during image capture by the camera, the images we obtain are noisy. Then these noisy fringe images will have a certain impact on the wrapped phase.

[0003] The phase-shifting algorithm is a commonly used digital grating projection measurement method. The grating fringe pattern with a sinusoidal distribution is projected by a DLP projector, and it will be affected by many factors such as the modulation of the surface of the object to be measured and the ambient light intensity, resulting in the CCD camera not having good sinusoidality for the captured grating fringe pattern. This non-sinusoidality will introduce errors into the phase information obtained by the phase-shifting algorithm.

[0004] The existing technologies mainly project a relatively large number of grating fringe patterns. There is data indicating that when the number of fringe patterns is more than 6, the error caused by non-linearity is small enough to be negligible; Huang proposed a double three-step phase-shifting algorithm that can significantly reduce the phase error. By projecting two groups of 3 sinusoidal grating fringe patterns, the initial phase between the two groups of fringe patterns is designed to be 60° different. The three-step phase-shifting algorithm is executed twice to obtain two principal value phase diagrams. After the principal value phase diagrams are unwrapped, the unwrapped phase diagrams are obtained. By fusing the two obtained unwrapped phase diagrams, the phase information required for measurement can be obtained; however, although the above methods can compensate for some phase errors, the accuracy is not high. Summary of the Invention

[0005] Aiming at the deficiencies of the existing algorithms, the present invention solves the problem of phase error caused by the non-sinusoidality of the phase-shifting grating fringe pattern obtained by camera shooting in structured light and random noise. The method of the present invention has simple equipment and low cost, and greatly improves the accuracy of the structured light system.

[0006] The technical solution adopted by the present invention is: an improved four-step phase-shifting unwrapping method based on wavelet transform includes the following steps:

[0007] S1. Generate fringe patterns with different phases at the same frequency using the phase-shift formula, project the fringe patterns through a DLP projector, and then capture the projected fringe patterns with an industrial camera to generate a camera fringe pattern;

[0008] Further, the phase-shift formula is:

[0009]

[0010] where A represents the background light intensity, B represents the modulation intensity, represents the phase value, represents the phase-shift value, f represents the phase-shift frequency, f = 1 / T, T represents the period, x represents the pixel coordinate in the encoding direction, and N is the number of steps of phase shift;

[0011] S2. Denoise the camera fringe pattern using the Wiener filtering algorithm and the bilateral filtering algorithm respectively to obtain the camera fringe pattern after Wiener filtering and the camera fringe pattern after bilateral filtering;

[0012] The Wiener filtering algorithm is a frequency-domain image processing algorithm that can reduce image noise and eliminate image blurring caused by camera shake during image denoising;

[0013] The bilateral filtering algorithm smooths the image and reduces noise while retaining the boundary information of the grating fringe pattern;

[0014] S3. Perform high-frequency and low-frequency processing on the two denoised camera fringe patterns using wavelet transform, and fuse the processed high-frequency and low-frequency components using inverse wavelet transform to obtain a fused camera fringe pattern;

[0015] Further, the wavelet transform uses the sym4 wavelet basis function to perform three-layer wavelet decomposition on the camera fringe pattern after Wiener filtering and the camera fringe pattern after bilateral filtering respectively to obtain the corresponding three-layer low-frequency components and high-frequency components;

[0016] Further, compare the three-layer high-frequency components of the wavelet-decomposed Wiener-filtered camera fringe pattern with the three-layer high-frequency components of the wavelet-decomposed bilateral-filtered camera fringe pattern respectively, and select the component with the larger absolute value for each layer to obtain the fused three-layer high-frequency components;

[0017] Further, calculate the arithmetic mean of the three-layer low-frequency components of the wavelet-decomposed Wiener-filtered camera fringe pattern and the three-layer low-frequency components of the wavelet-decomposed bilateral-filtered camera fringe pattern respectively to obtain the fused three-layer low-frequency components;

[0018] Reconstruct the fused three-layer low-frequency components and the fused three-layer high-frequency components using inverse wavelet transform to obtain the fringe pattern after wavelet processing;

[0019] S4. Divide the fringe patterns with different phases after wavelet processing into four groups, and use the N-step phase-shift unwrapping formula and the phase-shift formula to obtain the four-step phase-shift wrapped phases; fuse the four groups of four-step phase-shift wrapped phases through the fusion formula.

[0020] Further, the N-step phase-shift unwrapping formula is:

[0021]

[0022] where N is the number of steps of phase shift, I k is the phase-shift formula, k = 0, 1, 2... N - 1;

[0023] The four-step phase-shift unwrapping phase formula is:

[0024]

[0025] where I0 - I3 are the four-step phase-shift encodings.

[0026] Further, the fusion of the four groups of N-step phase-shift wrapped phases is to fuse the second group of wrapped phases with the first group of wrapped phases; fuse the result after fusion with the third group of wrapped phases; fuse the result after fusion with the fourth group of wrapped phases to obtain the total wrapped phase;

[0027] The fusion formula is as follows:

[0028]

[0029]

[0030]

[0031] where, is the phase difference between the second group and the first group, is the phase difference between the third group and the first group; is the phase difference between the fourth group and the first group; is the first group of wrapped phases; is the second group of wrapped phases, is the third group of wrapped phases, is the fourth group of wrapped phases, is the fused wrapped phase of the first group and the second group, is the fused third group of wrapped phases, is the total wrapped phase.

[0032] Advantages of the present invention:

[0033] 1. By denoising the grating fringe pattern, the influence of noise on the solution of the wrapped phase can be greatly reduced. Then, by improving the four-step phase-shift compensation algorithm, the accuracy of the wrapped phase can be further improved, thus laying an accuracy foundation for subsequent 3D reconstruction. Description of the Drawings

[0034] Figure 1 is the basic flowchart of the fringe pattern phase-shift compensation algorithm for the structured light of the present invention;

[0035] Figure 2 is 16 grating fringe patterns with a frequency of 1 / 70 generated by the computer of the present invention;

[0036] Figure 3 is the grating fringe pattern obtained by photographing with a CCD camera of the present invention;

[0037] Figure 4 is the image after image fusion using wavelet transform of the present invention and contains two denoised images;

[0038] Figure 5 is the wrapped phase map obtained by the improved four-step phase-shift unwrapping method of the present invention;

[0039] Figure 6 is the wrapped phase map obtained by the traditional four-step phase-shift unwrapping method of the present invention. Detailed Embodiment

[0040] The present invention will be further described below with reference to the drawings and embodiments. This figure is a simplified schematic diagram, which only illustrates the basic structure of the present invention in a schematic manner. Therefore, it only shows the components related to the present invention.

[0041] As Figure 1 shown, an improved four-step phase-shift unwrapping method based on wavelet transform includes the following steps:

[0042] S1. Use the phase-shift formula to generate fringe patterns with different phases at the same frequency using a computer program, project the fringe patterns through a DLP projector, and then photograph the projected fringe patterns with an industrial camera to generate a camera fringe pattern;

[0043] Generate phase-shifted fringe patterns. Assuming the number of phase-shift steps is 16, the phase-shift formula for generating the fringes is as shown in Equation (1). The grating fringe pattern uses 16-step phase shift, and the step size for each movement is π / 8, so that sixteen pictures will be generated;

[0044] The phase-shift formula is:

[0045]

[0046] Generate a set of sixteen-step phase-shifted images with a resolution of 1280*720 according to formula (1), where A represents the background light intensity of 130, B represents the modulation intensity of 90, represents the phase value, represents the phase shift value, f represents the phase shift frequency of 1 / 70, x represents the pixel coordinate in the coding direction, that is, the gray level distribution of the grating image is 0-255, as Figure 2 shown;

[0047] Project the above grating image onto a standard white flat plate by a DLP projector and synchronously shoot it with a CCD camera. The obtained grating image is as Figure 3 shown, Figure 3 Compared with Figure 2 it can be seen that there is noise in the camera image, making the image blurred and uneven.

[0048] S2. Denoise the camera fringe pattern by Wiener filtering algorithm and bilateral filtering algorithm respectively to obtain the camera fringe pattern after Wiener filtering and the camera fringe pattern after bilateral filtering;

[0049] S3. Use wavelet transform to perform high-frequency and low-frequency processing on the camera fringe pattern denoised by Wiener filtering and bilateral filtering, and use inverse wavelet transform to fuse the processed high-frequency and low-frequency components to obtain the fused camera fringe pattern; Figure 4 is the camera fringe pattern after image fusion based on Wiener filtering, bilateral filtering and wavelet transform;

[0050] Furthermore, the wavelet transform uses the sym4 wavelet basis function to perform three-layer wavelet decomposition on the camera fringe pattern after Wiener filtering and the camera fringe pattern after bilateral filtering respectively to obtain the corresponding three-layer low-frequency components and high-frequency components;

[0051] Compare the three-layer high-frequency components of the wavelet-decomposed Wiener-filtered camera fringe pattern with the three-layer high-frequency components of the wavelet-decomposed bilateral-filtered camera fringe pattern, and take the component with the larger absolute value for each layer to obtain the fused three-layer high-frequency components;

[0052] For example: the nine high-frequency components of the three layers of the wavelet-decomposed Wiener-filtered camera fringe pattern, the three high-frequency components of the first layer are The nine high-frequency components of the three layers of the wavelet-decomposed bilateral-filtered camera fringe pattern, the three high-frequency components of the first layer are Then the three fused high-frequency components of the first layer are And so on to calculate the three high-frequency components of the second layer and the three high-frequency components of the third layer;

[0053] Calculate the arithmetic mean of the three-layer low-frequency components of the wavelet-decomposed Wiener-filtered camera fringe pattern and the three-layer low-frequency components of the wavelet-decomposed bilateral-filtered camera fringe pattern respectively to obtain the fused three-layer low-frequency components;

[0054] For example, the three-layer one low-frequency component of the Wiener-filtered camera fringe pattern by wavelet decomposition is [0.8], and the three-layer one low-frequency component of the bilateral-filtered camera fringe pattern by wavelet decomposition is [0.4]. The fused three-layer one low-frequency component is [0.6].

[0055] Use the inverse wavelet transform to reconstruct the fused three-layer low-frequency component and the fused three-layer high-frequency component to obtain the fringe pattern after wavelet processing.

[0056] S4. Divide the fringe patterns with different phases after wavelet processing into four groups, and use the N-step phase-shift unwrapping formula and the phase-shift formula to calculate the four-step phase-shift wrapped phase; fuse the four groups of four-step phase-shift wrapped phases through the fusion formula.

[0057] Divide the sixteen phase-shift grating pictures processed in step S3 into 4 groups, that is, 1, 5, 9, 13 are the first group, 2, 6, 10, 14 are the second group, 3, 7, 11, 15 are the third group, and 4, 8, 12, 16 are the fourth group.

[0058] According to the N-step phase-shift unwrapping formula (2) and the phase-shift formula (1), obtain the formula (3) for solving the wrapped phase by four-step phase-shift. Use the formula (3) to solve the wrapped phase of the 4 groups of grating fringe images, and a total of 4 groups of wrapped phases are obtained.

[0059]

[0060]

[0061] Directly fuse the 4 groups of wrapped phases. Taking the wrapped phase of the first group as the reference, the phase difference between the second group and the first group The phase difference between the third group and the first group The phase difference between the fourth group and the first group Its fusion formulas are (4), (5), (6). According to the fusion formula, the correct wrapped phase is obtained Here, the wrapped phase of the first group is denoted as The wrapped phase of the second group is denoted as The wrapped phase of the third group is denoted as The wrapped phase of the fourth group is denoted as The fused wrapped phase of the first group and the second group is denoted as Then fuse the wrapped phase of the third group and denote it as Finally, fuse the wrapped phase of the fourth group to obtain the total wrapped phase, denoted as

[0062]

[0063]

[0064]

[0065] Among them, is the phase difference between the second group and the first group, is the phase difference between the third group and the first group; is the phase difference between the fourth group and the first group; is the wrapped phase of the first group; is the wrapped phase of the second group, is the wrapped phase of the third group, is the wrapped phase of the fourth group, is the fused wrapped phase of the first group and the second group, is the fused wrapped phase of the third group, is the total wrapped phase.

[0066] Experimental results:

[0067] As Figure 5 shown, the wrapped phase diagram obtained by the improved four-step phase-shifting unwrapping method of the method of the present invention;

[0068] Figure 6 is the wrapped phase directly obtained by using the traditional four-step phase-shifting unwrapping method. Through the comparison between Figure 5 and Figure 6 , it can be seen that for the traditional four-step phase-shifting unwrapping method without wavelet processing of the fringe pattern, Figure 6 the obtained wrapped phase contains obvious burrs, mainly affected by noise and non-linearity. The wrapped phase Figure 5 solved by the method of the present invention, the phase curve has been significantly improved, and the wrapped phase value curve is smoother, laying a foundation for the accuracy of 3D reconstruction.

[0069] Taking the ideal embodiments based on the present invention as an inspiration, through the above description, relevant staff can completely make various changes and modifications within the scope not deviating from the technical idea of this invention. The technical scope of this invention is not limited to the content in the specification, and its technical scope must be determined according to the scope of the claims.

Claims

1. An improved four-step phase-shifting phase unwrapping method based on wavelet transform, characterized in that, It includes the following steps: S1. Generate fringe patterns with different phases at the same frequency by using the phase shift formula, project the fringe patterns through a DLP projector, and then capture the projected fringe patterns by an industrial camera to generate a camera fringe pattern; S2. Denoise the camera fringe pattern by using the Wiener filtering algorithm and the bilateral filtering algorithm respectively to obtain the camera fringe pattern after Wiener filtering and the camera fringe pattern after bilateral filtering; S3. Use wavelet transform to perform high-frequency and low-frequency processing on the two denoised camera fringe patterns, and use inverse wavelet transform to fuse the processed high-frequency and low-frequency components to obtain a fused camera fringe pattern; S4. Divide the fringe patterns with different phases after wavelet processing into four groups, and use the N-step phase shift unwrapping formula and the phase shift formula to calculate the four-step phase shift wrapped phase; Fuse the four groups of four-step phase shift wrapped phases through the fusion formula; The four-step phase shift unwrapping phase formula is: ; Among them, I 0 - I 3 is four-step phase-shift encoding; The fusion formula is: ; ; ; wherein, is the phase difference between the second group and the first group, is the phase difference between the third group and the first group; is the phase difference between the fourth group and the first group; is the wrapped phase of the first group; is the wrapped phase of the second group, is the wrapped phase of the third group, is the wrapped phase of the fourth group, is the fused wrapped phase of the first group and the second group, is the fused wrapped phase of the third group, is the total wrapped phase.

2. The improved four-step phase-shifting unwrapping method based on wavelet transform according to claim 1, wherein The phase shift formula is: ; Among them, A represents the background light intensity, B represents the modulation intensity, represents the phase value, represents the phase shift value, f represents the phase shift frequency, x represents the pixel coordinates in the coding direction, N is the number of steps of phase shift.

3. The improved four-step phase-shifting unwrapping method based on wavelet transform according to claim 1, characterized in that The wavelet transform is to perform three-layer wavelet decomposition on the camera fringe pattern after Wiener filtering and the camera fringe pattern after bilateral filtering by using the sym4 wavelet basis function respectively to obtain the corresponding three-layer low-frequency components and high-frequency components.

4. The improved four-step phase-shifting unwrapping method based on wavelet transform according to claim 3, wherein, It also includes: Compare the three-layer high-frequency components of the wavelet-decomposed Wiener filtering camera fringe pattern with the three-layer high-frequency components of the wavelet-decomposed bilateral filtering camera fringe pattern respectively, and take the component with the larger absolute value for each layer to obtain the fused three-layer high-frequency components.

5. The improved four-step phase-shifting phase unwrapping method based on wavelet transform according to claim 3, wherein, It also includes: Calculate the arithmetic mean of the three-layer low-frequency components of the wavelet-decomposed Wiener filtering camera fringe pattern and the three-layer low-frequency components of the wavelet-decomposed bilateral filtering camera fringe pattern respectively to obtain the fused three-layer low-frequency components.

Citation Information

Patent Citations

  • Heterodyne three-frequency unequal range phase displacement solution phase method

    CN104330052A

  • Simultaneous three-dimensional geometry and color texture acquisition using single color camera

    US20100207938A1