Image phase unwrapping method and apparatus

By using an image phase unwrapping method, true zeros and phase transition boundaries are determined through normalization processing, phase average value calculation, and phase change trend judgment. This solves the problems of insufficient computational efficiency and accuracy in existing technologies and enables real-time processing and efficient unwrapping on embedded devices.

CN120970533BActive Publication Date: 2025-12-23ZHEJIANG SHUANGYUAN TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202511503390.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-21
Publication Date
2025-12-23
Estimated Expiration
2045-10-21

AI Technical Summary

Technical Problem

Existing image phase unwrapping methods are insufficient in terms of computational efficiency and accuracy, making it difficult to meet the real-time requirements of industrial online inspection, and their deployment in embedded devices is costly.

Method used

By acquiring the phase image to be unwrapped and normalizing it, calculating the average phase value, judging the phase change trend, determining the true zero point and phase jump boundary, dividing the region and performing phase compensation, adopting column mean statistics and dynamic dual threshold design, combined with sliding window verification and minimum spacing constraint, the computational complexity is reduced and the accuracy is improved.

Benefits of technology

It enables real-time image phase unwrapping processing on embedded devices, reducing computational costs, improving computational efficiency and measurement accuracy, effectively suppressing noise effects and eliminating errors in traditional methods, and is suitable for resource-constrained scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120970533B_ABST
    Figure CN120970533B_ABST
Patent Text Reader

Abstract

The application provides an image phase unwrapping method and device, the method comprising: obtaining a phase image to be unwrapped and performing normalization processing; performing phase average value calculation on the phase image to be unwrapped after normalization processing, and obtaining a column mean value array of phase average values about each column of pixels; performing phase change trend judgment according to the column mean value array, and obtaining a phase change trend judgment result of the phase image to be unwrapped; performing zero point detection and verification according to the column mean value array, and determining a true zero point in the phase image to be unwrapped; determining a phase jump boundary in the phase image to be unwrapped after normalization processing according to the phase change trend judgment result and the true zero point; performing region division on the phase image to be unwrapped after normalization processing according to the phase jump boundary and the true zero point, and performing phase compensation on each region, and obtaining an unwrapped image; and the method can reduce the calculation cost.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of image processing, and in particular to an image phase unwrapping method and device. BACKGROUND

[0002] In the field of optical three-dimensional measurement, phase unwrapping technology is the core link of fringe projection, interferometric measurement and other systems. Its core task is to restore the truncated phase wrapped in the interval [-π, π] to continuous absolute phase, providing basic data for three-dimensional topography reconstruction. Traditional mainstream methods include path tracking method and least squares method. The path tracking method proposed by Goldstein et al. in 1988 (Goldstein R M, et al. Appl. Opt. 1988, 27(5): 734-749) can suppress noise propagation by constructing a quality map to guide the integration path, but it needs to calculate the residual point and plan the integration path pixel by pixel, and the time complexity of the calculation is as high as O(N²), which is difficult to meet the real-time requirements of industrial online detection. More seriously, this method is extremely sensitive to isolated noise, and local residual point misjudgment will cause error to spread along the integration path.

[0003] In order to improve efficiency, Flynn proposed a fast unwrapping method based on fringe modulation in 1997 (Flynn T J. Opt. Eng. 1997, 36(3): 787-799), which directly applies phase compensation by identifying 2π jump boundary. Although this method reduces the calculation amount to O(N), it relies on fixed threshold (such as phase gradient threshold) to determine the jump position. When the surface reflectivity is suddenly changed, the local phase gradient abnormally increases, leading to misjudgment of the jump boundary and causing stepwise error of ±2π integer multiples.

[0004] In recent years, phase unwrapping methods based on deep learning methods have appeared, for example, patent text CN120219205A proposes a real-time holographic phase unwrapping and phase distortion elimination method, system, computer device and storage medium. The method comprises the following steps: acquiring and recording the hologram of the object to be measured; pre-processing the hologram to obtain a wrapped phase map; inputting the wrapped phase map into the HS-TransUNet neural network to obtain a wrapped number map; multiplying the wrapped number map by 2π and superimposing it with the wrapped phase map to obtain an unwrapped phase map; inputting the unwrapped phase map into the HS-TransUNet neural network to obtain a background map; inputting the background map into the HS-ResNet50 neural network to obtain the first six Zernike coefficients; using the first six Zernike coefficients to predict the background distortion data; subtracting the background distortion data from the unwrapped phase map to obtain the real phase of the target object. Although this method can improve noise resistance, it requires training of ten thousand samples and relies on GPU hardware, which has high deployment cost in embedded devices. SUMMARY

[0005] The application provides an image phase unwrapping method and device, which can reduce the calculation cost of image phase unwrapping and improve the calculation efficiency.

[0006] An image phase unwrapping method comprises the following steps.

[0007] An unwrapped phase image is obtained and normalized.

[0008] The normalized unwrapped phase image is subjected to phase average value calculation to obtain a column mean value array of phase average values of each column of pixels.

[0009] Phase change trend judgment is performed according to the column mean value array to obtain a phase change trend judgment result of the unwrapped phase image.

[0010] Zero point detection and verification are performed according to the column mean value array to determine a true zero point in the unwrapped phase image.

[0011] A phase jump boundary in the normalized unwrapped phase image is determined according to the phase change trend judgment result and the true zero point.

[0012] The normalized unwrapped phase image is subjected to region division according to the phase jump boundary and the true zero point, and phase compensation is performed on each region to obtain an unwrapped image.

[0013] An image phase unwrapping device comprises the following.

[0014] An image acquisition module is configured to obtain an unwrapped phase image and perform normalization.

[0015] A phase calculation module is configured to perform phase average value calculation on the normalized unwrapped phase image to obtain a column mean value array of phase average values of each column of pixels.

[0016] A trend judgment module is configured to perform phase change trend judgment according to the column mean value array to obtain a phase change trend judgment result of the unwrapped phase image.

[0017] A zero point determination module is configured to perform zero point detection and verification according to the column mean value array to determine a true zero point in the unwrapped phase image.

[0018] A boundary determination module is configured to determine a phase jump boundary in the normalized unwrapped phase image according to the phase change trend judgment result and the true zero point.

[0019] A compensation module is configured to divide a normalized unwrapped phase image into regions according to the phase jump boundary and the true zero point, and to compensate the phase of each region to obtain an unwrapped image.

[0020] The image phase unwrapping method and device provided by the application have at least the following advantages:

[0021] (1) In terms of calculation efficiency, the traditional two-dimensional pixel processing is reduced to column statistical feature analysis, and the stable area is uniformly processed instead of being iteratively processed, so that the operation paradigm of the unwrapping algorithm is reconstructed, the efficiency is improved, and in addition, the iterative processing involved in the method provided by the application can be calculated in parallel, so that the running time can also be saved, and real-time processing of the algorithm on an embedded device is possible, thereby saving the operation cost.

[0022] (2) In terms of measurement accuracy, the inherent error of the traditional method is solved through a triple innovation mechanism. First, the introduction of column mean value statistics is equivalent to vertical direction low-pass filtering, which effectively suppresses the influence of isolated noise points. Second, the dynamic double threshold value design accurately identifies the true jump event, successfully eliminating the ±2π step error caused by local reflectivity mutation in the traditional method. Finally, the synergistic effect of the sliding window verification and the minimum distance constraint solves the problem of missed detection in low-texture areas.

[0023] (3) The operation is simple and easy to reproduce, and a fully deterministic algorithm design is adopted, all operation modules (including column mean value calculation, zero crossing point detection, boundary positioning and phase compensation) are implemented based on integer operation, avoiding the platform dependency caused by floating point operation, and ensuring the efficient deployment of the algorithm on embedded hardware such as FPGA. This "algorithm-hardware" collaborative optimization feature makes the technology can be directly integrated into the lower machine system, providing a reliable solution for the popularization of phase unwrapping technology in resource-constrained scenarios, thereby reducing production costs. BRIEF DESCRIPTION OF DRAWINGS

[0024] FIG. 1(a) is a schematic diagram of an embodiment of an unwrapped phase image with an upward trend.

[0025] FIG. 1(b) is a schematic diagram of an embodiment of an unwrapped phase image in a downward region.

[0026] Figure 2 FIG. 2 is a schematic diagram of an embodiment of phase variation of a row of pixels in an unwrapped phase image.

[0027] FIG. 3(a) is a schematic diagram of an embodiment of phase variation of a phase image after unwrapping.

[0028] FIG. 3(b) is a schematic diagram of an embodiment of a normalized phase image after unwrapping.

[0029] Figure 4Fig. 5(a) is a schematic diagram of a zero point of the column phase mean according to an embodiment.

[0030] Fig. 5(b) is a schematic diagram of a pseudo zero point of the column phase mean according to an embodiment.

[0031] Fig. 5(b) is a schematic diagram of a pseudo zero point of the column phase mean according to an embodiment.

[0032] Fig. 5(c) is a schematic diagram of a true zero point of the column phase mean according to an embodiment.

[0033] Figures 6(a) to 6(c) Fig. 5(c) is a schematic diagram of a true zero point of the column phase mean according to an embodiment.

[0034] Figure 7 Fig. 5(c) is a schematic diagram of a true zero point of the column phase mean according to an embodiment.

[0035] Figures 8(a) to 8(c) Fig. 5(c) is a schematic diagram of a true zero point of the column phase mean according to an embodiment.

[0036] Figure 9 Fig. 5(c) is a schematic diagram of a true zero point of the column phase mean according to an embodiment. DETAILED DESCRIPTION

[0037] In order to better understand the above technical solutions, the above technical solutions will be described in detail below in combination with the drawings of the specification and specific embodiments.

[0038] The unwrapped phase map is shown in Fig. 1(a) and Fig. 1(b), wherein the phase map shown in Fig. 1(a) should be gradually rising from left to right after unwrapping, because the unwrapped phase gradually rises from -π to π in a complete cycle, and the phase map shown in Fig. 1(b) should be gradually falling from left to right after unwrapping, because the unwrapped phase gradually falls from π to -π in a complete cycle.

[0039] Without considering the phase change caused by the defects of unevenness on the object to be measured, taking the gradually rising phase map as an example, for a certain row of unwrapped phase map, taking the phase value as the vertical coordinate and the column number of pixels as the horizontal coordinate, the following can be obtained Figure 2The shown schematic diagram. It can be seen that, in a cycle, the phase gradually rises from a value close to -π but slightly greater than -π (denoted as -π+ε) to a value close to π but slightly less than π (denoted as π-ε), where ε is a very small positive number. Then due to the characteristics of the tangent function that will mutate at angles of -π or π, the phase will also randomly take values between (-π+ε) and (π-ε) at (π-ε), and then after this short jump, the phase will stabilize at -π+ε, and then enter the next cycle. Finally, after the unwrapping of the row of unwrapped phase diagram, the result shown in Fig. 3(a) can be obtained, and then after the normalization of the unwrapped phase diagram, the result shown in Fig. 3(b) can be obtained, which is the final result required.

[0040] Although for a row of unwrapped phase diagram, the phase value may not necessarily satisfy the Figure 2 exhibited law due to the uneven defects, but the uneven defects are usually a relatively small area compared to the phase diagram, so if the phase mean of the phase diagram is calculated column by column, the column phase mean of the phase diagram is basically as Figure 4 shown. The region where the column phase mean changes from (-π+ε) to (π-ε) is called the stable region, and in this region, for each row of the unwrapped phase diagram, there is no uneven defect, and the phase is stable and rising without jumping. The region where the column phase mean changes from (π-ε) to (-π+ε) is called the jump region, and in this region, for each row of the unwrapped phase diagram, there is no uneven defect, and the phase may jump between (-π+ε) and (π-ε).

[0041] In addition, in this embodiment, the combination of one stable region and one jump region is called one cycle. Since the phase of the phase diagram may not necessarily start from (-π+ε) and may not necessarily end at (-π+ε), the leftmost and rightmost cycles of the image may be incomplete, and this incompleteness may not only be a partial loss of the stable region or the jump region, as Figure 4 shown, the leftmost cycle missing part of the stable region, the rightmost cycle missing part of the stable region, but also the entire loss of the stable region or the jump region, as Figure 4 shown, the rightmost cycle missing the entire jump region, in which case the number of columns occupied by the jump region of the rightmost cycle can be considered as 0.

[0042] For the stable region of the ith cycle, only the phase value in the cycle needs to be added to i*2π when unwrapping the phase diagram; for the jump region of the ith cycle, when unwrapping the phase diagram, the phase value in the cycle needs to be traversed, if the phase value is in the neighborhood of (π-ε), the phase value is added to i*2π, if the phase value is in the neighborhood of (-π+ε), the phase value is added to (i+1)*2π.

[0043] This processing method can obtain accurate unwrapped phase map without the influence of defects, and can greatly save operation time due to the larger stable region without traversing phase values.

[0044] According to the change trend of the column phase mean, if the stable region changes from (-π+ε) to (π-ε), it is considered that the trend is +, that is, the upward trend, and if the stable region changes from (π-ε) to (-π+ε), it is considered that the trend is -, that is, the downward trend. In order to accurately distinguish the stable region and the jump region, the boundary of each stable region and jump region needs to be found. First, find the zero point on the column phase mean, as shown in Fig. 5(a), then compare the change trend in the neighborhood of each zero point with the change trend of the phase map, find the pseudo zero point whose change trend in the neighborhood is opposite to the change trend of the phase map, as shown in Fig. 5(b), eliminate the pseudo zero point, and keep the true zero point, as shown in Fig. 5(c). Compared with the method of finding (π-ε) or (-π+ε) to determine the boundary, the advantage of finding the true zero point is that the true zero point is often located at the center of the stable region and is very stable, and is not affected by the phase jump.

[0045] Between every two adjacent true zero points, there is a jump region, so for the column index (that is, the column number) of each two adjacent true zero points, find the column index of the left boundary of the jump region to the right of the left true zero point, and find the column index of the right boundary of the jump region to the left of the right true zero point, so that if there are a true zero points, a-1 jump regions will be found. The region between the i th true zero point and the left boundary of the i th jump region is called the right side region (including the column index of the i th true zero point, not including the column index of the left boundary of the i th jump region), the region between the left boundary of the i th jump region and the right boundary of the i th jump region is called the jump region (including the column index of the left boundary of the i th jump region, not including the column index of the right boundary of the i th jump region), and the region between the right boundary of the i th jump region and the i+1 th true zero point is called the left side region (including the column index of the right boundary of the i th jump region, not including the column index of the i+1 th true zero point).

[0046] However, the position of the first true zero point of the image has the following three cases, such as Figures 6(a) to 6(c)If each true zero point is found directly, and the left boundary and the right boundary of the jump region are found, and the left boundary column index of the leftmost true zero point is not 0, it is not determined whether the columns between the 0th column and the leftmost true zero point column index belong to the "left region" (as shown in FIG. 6(a)), or belong to the "jump region" and the "left region" (as shown in FIG. 6(b)), or belong to the "right region" and the "jump region" and the "left region" (as shown in FIG. 6(c)). In order to solve this problem, the leftmost zero point column index is first set as 0, and then the found true zero points. Similarly, in order to determine whether the columns between the left boundary column index of the rightmost true zero point and the last column of the image belong to the "right region", or belong to the "right region" and the "jump region", or belong to the "right region" and the "jump region" and the "left region", we set the rightmost zero point column index as the last column index of the image + 1. That is, assuming that the image has M rows and N columns, and the column indexes are 0, 1,..., N-1 respectively, and the found true zero point column indexes are a1, a2, a3, a4 respectively, then the final zero point column indexes used to determine the "left region", the "right region" and the "jump region" are: 0, a1, a2, a3, a4, N. In this way, all regions can be correctly distinguished.

[0047] The above method is also applicable to the case where the trend is - (decreasing trend).

[0048] Specifically, referring to Figure 7 In some embodiments, an image phase unwrapping method is provided, comprising:

[0049] S1, obtaining a to-be-unwrapped phase image and performing normalization processing;

[0050] S2, calculating the phase average value of the normalized to-be-unwrapped phase image to obtain a column mean value array of the phase average value of each column of pixels;

[0051] S3, judging the phase change trend according to the column mean value array to obtain a phase change trend judgment result of the to-be-unwrapped phase image;

[0052] S4, detecting and verifying the zero point according to the column mean value array to determine the true zero point in the to-be-unwrapped phase image;

[0053] S5, determining the phase jump boundary in the normalized to-be-unwrapped phase image according to the phase change trend judgment result and the true zero point;

[0054] S6, dividing the normalized to-be-unwrapped phase image into regions according to the phase jump boundary and the true zero point, and performing phase compensation on each region to obtain an unwrapped image.

[0055] Specifically, in step S1, in order to facilitate implementation on the lower machine, first normalize the to-be-unwrapped phase image phase_unwrapped with a phase value range of (-π, π) to between (-2048, 2048) to obtain a normalized to-be-unwrapped phase image phase_unwrapped2048, and in subsequent processing, replace π with 2048 for operation, that is:

[0056] ; (1)

[0057] wherein phase_unwrapped2048 represents the normalized to-be-unwrapped phase image, and phase_unwrapped represents the original to-be-unwrapped phase image.

[0058] Further, in step S2, the phase average value of the normalized to-be-unwrapped phase image is calculated to obtain a column mean array of the phase average value of each column pixel, including:

[0059] S21, initialize the column mean array;

[0060] S22, calculate the phase average value of each column pixel in the normalized to-be-unwrapped phase image and store it in the column mean array.

[0061] Specifically, the normalized to-be-unwrapped phase image phase_unwrapped2048 is processed by dimension reduction, and the two-dimensional phase data is compressed into one-dimensional statistical features. The column mean array meanOfColArray is initialized to be empty, assuming that the normalized to-be-unwrapped phase image phase_unwrapped2048 has a size of M rows and N columns, for each column pixel of the image, the arithmetic average value of all phases of the column is calculated and stored in the column mean array meanOfColArray, that is:

[0062] ; (2)

[0063] wherein x = 0, 1,..., N-1, phase_unwrapped2048[y][x] represents the phase value of the yth pixel in the xth column, and meanOfColArray[x] represents the phase average value of the xth column.

[0064] In some embodiments, the phase value of each column pixel in the normalized to-be-unwrapped phase image phase_unwrapped2048 can be converted into the phase average value of the column, which is essentially to implement low-pass filtering in the vertical direction, effectively suppressing the influence of isolated noise points.

[0065] The normalized phase image to be unwrapped comprises M rows and N columns of pixels, where M and N are both integers greater than 1; the column mean array includes the phase average values ​​from column 0 to column (N-1).

[0066] Further, in step S3, the phase change trend is determined based on the column mean array to obtain the phase change trend determination result of the phase image to be unwrapped, including:

[0067] S31. Traverse the first phase average value to the (N-2)th phase average value in the column mean array, and calculate the local trend value of the pixels in each column based on the phase average value of the adjacent columns of each pixel.

[0068] S32. Calculate the cumulative value of all local trend values ​​and normalize them to obtain the normalized cumulative value;

[0069] S33. If the normalized cumulative value is 1, then the phase change trend in the phase image to be unwrapped is determined to be an upward trend within the period; if the normalized cumulative value is -1, then the phase change trend in the phase image to be unwrapped is determined to be a downward trend within the period.

[0070] Specifically, initialize the normalized cumulative value. fuhaoFinal =0, initialize the local trend value array to empty, iterate through the first to N-2 elements of the column mean array meanOfColArray, and calculate the local trend value of each column of pixels based on the phase average of the adjacent columns. diff ,Right now:

[0071] (3)

[0072] Where x = 1, 2, ..., N-2, and diff[x] is the local trend value corresponding to the x-th element in the column mean array meanOfColArray.

[0073] Calculate the cumulative value of all local trend values. fuhao ,Right now:

[0074] (4)

[0075] The final cumulative value of all local trend values fuhao Normalized to 1 (upward trend) or -1 (downward trend), that is:

[0076] (5)

[0077] in, huhaoFinal This represents the normalized cumulative value.

[0078] If the normalized cumulative value huhaoFinal= 1, indicating that the change trend of the unwrapped phase image phase_unwrapped in a complete cycle is gradually rising from -π to π, and then jumping to -π, i.e. the rising trend, and so on; if the normalized cumulative value huhaoFinal = -1, indicating that the change trend of the unwrapped phase image phase_unwrapped in a complete cycle is gradually falling from π to -π, and then jumping to π, i.e. the falling trend, and so on.

[0079] This global trend determination provides a key guide for subsequent processing, and this stage compresses the millions of pixels originally required to participate in the stable zone and jump zone boundary calculation into thousands of feature points (column numbers), laying the foundation for real-time processing.

[0080] Further, in step S4, zero point detection and verification are performed according to the column mean value array to determine the true zero points in the unwrapped phase image, including:

[0081] S41, initializing a first zero point set, a second zero point set and a third zero point set, and adding column index 0 to the third zero point set;

[0082] S42, traversing each phase average value in the column mean value array, comparing the phase average value with a preset zero point neighborhood threshold value, and if the absolute value of the phase average value is less than the preset zero point neighborhood threshold value, storing the column index corresponding to the phase average value in the first zero point set;

[0083] S43, traversing the column indexes in the first zero point set, determining a neighborhood range according to the column indexes in the first zero point set and a preset left and right neighborhood value, calculating the sum of the local trend values of all column pixels in the neighborhood range corresponding to the column index, and if the ratio of the sum of the local trend values to the normalized cumulative value is greater than 0, storing the corresponding column index in the second zero point set;

[0084] S44, storing the 0th column index in the second zero point set in the third zero point set, traversing the column indexes in the second zero point set, and calculating the absolute value of the difference between the current column index and the previous column index, and if the absolute value is greater than a preset minimum threshold value, storing the current column index in the third zero point set;

[0085] S45, adding 1 to the column index corresponding to the last column pixel in the unwrapped phase image and storing it in the third zero point set, and the column indexes in the obtained third zero point set are the column indexes of the true zero points.

[0086] Specifically, in step S41, the first zero point set set1, the second zero point set set2 and the third zero point set set3 are initialized as empty, and the column index 0 is added to the third zero point set set. A preset zero point neighborhood threshold nearZero, a preset left and right neighborhood value rad and a preset minimum threshold minDis are set.

[0087] In step S42, each phase average value in the column mean value array meanOfColArray is traversed, and a candidate point is selected in a region where the phase average value is close to zero, that is, if the absolute value of the phase average value is less than the preset zero point neighborhood threshold nearZero, that is, abs(meanOfColArray[i])<nearZero, the column index i corresponding to the phase average value is stored in the first zero point set set1. Then a double dynamic verification mechanism is introduced.

[0088] In step S43, the first verification is performed by using a sliding window. The column index in the first zero point set set1 is traversed, and the column corresponding to the column index in the first zero point set set1 is taken as the center, and the column pixels in a preset left and right neighborhood value range are taken as the neighborhood range, and the consistency of the difference signs in the neighborhood is checked, that is, the column index set1[j] in the first zero point set set1 is traversed, and the following is performed:

[0089] ; (6)

[0090] wherein diff[] represents a local trend value of the column index, fuhao Now represents the sum of the local trend values of all column pixels in the neighborhood range corresponding to the column index set1[j].

[0091] The column indexes in the left and right rad neighborhood ranges of the column index set1[j] in the first zero point set set1 are set1[j]-rad, set1[j]-rad+1,..., set1[j],..., set1[j]+rad-1, set1[j]+rad, and the local trend value of each column pixel is calculated according to the phase average values of the adjacent columns of each column pixel, and then the local trend values of each column are added to obtain the local trend value sum Now. fuhao

[0092] If the ratio of the local trend value sum to the normalized cumulative value is greater than 0, that is, fuhao Now / fuhao Final>0, it is indicated that the trend sign in the region is consistent with the global trend, and the corresponding column index set1[j] is stored in the second zero point set set2.

[0093] ​In step S44, the second reapplication of the minimum distance constraint avoids over-detection of dense jump regions, i.e., the 0th element set2[0] in the second zero point set set2 is stored in the third zero point set set3, and then the column index set2[k] in the second zero point set set2 is traversed, k starting from 1, and if abs(set2[k]-set2[k-1])>minDis, i.e., the absolute value of the difference between the current column index and the previous column index is greater than the preset minimum threshold minDis, then the kth element set2[k] in the second zero point set set2, i.e., the corresponding column index, is stored in the third zero point set set3.

[0094] In step S45, the column index corresponding to the last column of pixels in the unwrapping phase image is added 1 (col) and stored in the third zero point set set3, where col=N. An interval division framework covering the entire image is formed. In this stage, the sliding window concept of signal processing is innovatively introduced into phase analysis, solving the missing detection problem of traditional methods in low-texture regions.

[0095] The column index in the obtained third zero point set is the column index of the true zero point.

[0096] Further, in step S5, the phase change trend judgment result includes an upward trend within a period and a downward trend within a period.

[0097] According to the phase change trend judgment result and the true zero point, a phase jump boundary in the normalized unwrapping phase image is determined, including:

[0098] S51, for the upward trend within a period, the following operations are performed for each true zero point: according to the column index of the true zero point, the normalized unwrapping phase image is searched column by column to the right, and if the current column index and the phase average value corresponding to the current column meet the first preset condition, the current column is determined as the right boundary of the stable region, and the right search is stopped; starting from the next true zero point, the normalized unwrapping phase image is searched column by column to the left, and if the current column index and the phase average value corresponding to the current column meet the second preset condition, the current column is determined as the left boundary of the stable region, and the left search is stopped.

[0099] S52, for the downward trend within a period, the following operations are performed for each true zero point: according to the column index of the true zero point, the normalized unwrapping phase image is searched column by column to the right, and if the current column index and the phase average value corresponding to the current column meet the third preset condition, the current column is determined as the right boundary of the stable region, and the right search is stopped; starting from the next true zero point, the normalized unwrapping phase image is searched column by column to the left, and if the current column index and the phase average value corresponding to the current column meet the fourth preset condition, the current column is determined as the left boundary of the stable region, and the left search is stopped.

[0100] The first preset condition is that the currently searched column index is equal to the column number of the phase image to be unwrapped, or the phase average value corresponding to the currently searched column is greater than the difference between the normalized maximum range value and the preset boundary threshold value;

[0101] The second preset condition is that the currently searched column index is equal to 0, or the phase average value corresponding to the currently searched column is less than the sum of the normalized minimum range value and the preset boundary threshold value;

[0102] The third preset condition is that the currently searched column index is equal to the column number of the phase image to be unwrapped, or the phase average value corresponding to the currently searched column is less than the sum of the normalized minimum range value and the preset boundary threshold value;

[0103] The fourth preset condition is that the currently searched column index is equal to 0, or the phase average value corresponding to the currently searched column is greater than the difference between the normalized maximum range value and the preset boundary threshold value.

[0104] Specifically, a differentiated search strategy is adopted according to the global trend: a preset boundary threshold value boundary th, a preset two-dimensional left and right boundary array boundaryArray are set, assuming that a total of a true zero points are found, that is, the size of the third zero point set set3 is a+2, and the size of the two-dimensional left and right boundary array boundaryArray is a+1.

[0105] For the upward trend (boundary th fuhaoFinal =1), starting from the column index set3[i] (i=0, 1, 2,..., a) of the 0th true zero point in the third zero point set set3, the column is searched rightward, and the searched column index is equal to the column number of the phase image to be unwrapped, or the phase average value corresponding to the currently searched column is greater than the difference between the normalized maximum range value and the preset boundary threshold value, that is:

[0106] ; (7) or

[0107] ; (8)

[0108] wherein set3[i] is the column index of the ith true zero point in the third zero point set set3, y[i] is the ith column index searched rightward, set3[i]+y[i] is the current column index searched rightward, col represents the column number of the phase image to be unwrapped; meanOfColArray[set3[i]+y[i]] is the phase average value corresponding to the current column [set3[i]+y[i]] searched rightward, 2048 is the normalized maximum range value, and boundary th is the preset boundary threshold value;

[0109] If set3[i] + y[i] is considered as the right boundary of the stable region, stop searching to the right.

[0110] Then, from the next true zero point column index set3[i+1], search to the left column by column. If the searched column index is equal to 0, or the phase average value corresponding to the searched column is less than the sum of the normalized minimum range value and the preset boundary threshold, i.e.

[0111] ; (9) or

[0112] ; (10)

[0113] wherein set3[i+1] is the column index of the i+1th true zero point in the third zero point set set3, x[i+1] is the i+1th column index searched to the left, set3[i+1]-x[i+1] is the current column index searched to the left, meanOfColArray[set3[i+1]-x[i+1]] is the phase average value corresponding to the current column [set3[i+1]-x[i+1]] searched to the left, and -2048 is the normalized minimum range value;

[0114] If set3[i+1]-x[i+1] is considered as the left boundary of the stable region, stop searching to the left.

[0115] Finally, the right boundary of the stable region and the left boundary of the stable region (set3[i]+y[i], set3[i+1]-x[i+1]) are stored in the two-dimensional left and right boundary array boundaryArray.

[0116] If the descending trend is adopted, the symmetric condition is used, i.e. from the true zero point column index set3[i] (i=0, 1, 2,..., a) in the third zero point set set3, search to the right column by column. If the current searched column index is equal to the column number of the phase image to be unwrapped, or the phase average value corresponding to the current searched column is less than the sum of the normalized minimum range value and the preset boundary threshold, i.e.

[0117] ; (11) or

[0118] ; (12)

[0119] wherein set3[i] is the column index of the i-th true zero point in the third zero point set set3, y[i] is the i-th column index searched to the right, set3[i]+y[i] is the current column index searched to the right, col represents the column number of the unwrapping phase image to be solved; meanOfColArray[set3[i]+y[i]] is the average phase value corresponding to the current column [set3[i]+y[i]] searched to the right, -2048 is the minimum range value of normalization, and boundary_th is a preset boundary threshold value;

[0120] If set3[i]+y[i] is equal to 0, or the average phase value corresponding to the current column set3[i]+y[i] searched to the right is greater than the difference between the maximum range value of normalization and the preset boundary threshold value, i.e.

[0121] Then, starting from the next zero point column index set3[i+1], the columns are searched to the left, and if the searched column index is equal to 0, or the average phase value corresponding to the searched column is greater than the difference between the maximum range value of normalization and the preset boundary threshold value, i.e.

[0122] ; (13) or

[0123] ; (14)

[0124] wherein set3[i+1] is the column index of the i+1-th true zero point in the third zero point set set3, x[i+1] is the i+1-th column index searched to the left, set3[i+1]-x[i+1] is the current column index searched to the left, and meanOfColArray[set3[i+1]-x[i+1]] is the average phase value corresponding to the current column [set3[i+1]-x[i+1]] searched to the left.

[0125] If set3[i+1]-x[i+1] is equal to 0, or the average phase value corresponding to the current column set3[i+1]-x[i+1] searched to the left is greater than the maximum range value of normalization, i.e.

[0126] Finally, (set3[i]+y[i], set3[i+1]-x[i+1]) is stored in boundaryArray.

[0127] Suppose that a true zero points are found in total, i.e. the size of the third zero point set set3 is a+2, and the size of the two-dimensional left and right boundary array boundaryArray is a+1.

[0128] Further, in step S6, the normalized unwrapping phase image to be solved is regionally divided according to the phase jump boundary and the true zero point, including:

[0129] In one period, a region between the true zero point and a right boundary of the most adjacent stable region is determined as a right region of the stable region, and a region between the true zero point and a left boundary of the most adjacent stable region is determined as a left region of the stable region, the left region and the right region forming the stable region;

[0130] A region between the left boundary of the closest stable region and the right boundary of the stable region is determined as a jump region.

[0131] Further, in step S6, phase compensation is performed on each region, including:

[0132] S61, each row of pixels in the normalized unwrapping phase image is traversed, if the current pixel is located in the right region of the ith true zero point, for the upward trend, if the current pixel satisfies the fifth preset condition, the phase of the current pixel is compensated by i+1 times of the period phase, if the current pixel does not satisfy the fifth preset condition, the phase of the current pixel is compensated by i times of the period phase; for the downward trend, if the current pixel satisfies the sixth preset condition, the phase of the current pixel is compensated by - (i+1) times of the period phase, if the current pixel does not satisfy the sixth preset condition, the phase of the current pixel is compensated by -i times of the period phase;

[0133] S62, if the current pixel is located in the jump region between the ith true zero point and the ith+1 true zero point, for the upward trend, if the current pixel satisfies the seventh preset condition, the current pixel is compensated by i times of the period phase, if the current pixel does not satisfy the seventh preset condition, the current pixel is compensated by i+1 times of the period phase; for the downward trend, if the current pixel satisfies the seventh preset condition, the current pixel is compensated by - (i+1) times of the period phase, if the current pixel does not satisfy the seventh preset condition, the current pixel is compensated by -i times of the period phase;

[0134] S63, if the current pixel is located in the left region of the ith+1 true zero point, for the upward trend, if the current pixel satisfies the sixth preset condition, the current pixel is compensated by i times of the period phase, if the current pixel does not satisfy the sixth preset condition, the current pixel is compensated by i+1 times of the 2π period phase; for the downward trend, if the current pixel satisfies the fifth preset condition, the current pixel is compensated by -i times of the period phase, if the current pixel does not satisfy the fifth preset condition, the current pixel is compensated by - (i+1) times of the period phase;

[0135] Wherein, i=0, 1, 2……a-1; a is the number of true zero points.

[0136] The fifth preset condition is that the phase value of the current pixel is less than a negative preset jump threshold, and the phase average value of the column where the current pixel is located is greater than the difference between the normalized maximum range value and the preset jump threshold.

[0137] the sixth preset condition is that the phase value of the current pixel is greater than the preset jump threshold value, and the phase average value of the column where the current pixel is located is less than the sum of the normalized minimum range value and the preset jump threshold value;

[0138] the seventh preset condition is that the phase value of the current pixel is greater than 0;

[0139] the periodic phase compensation is the absolute value of the difference between the normalized maximum range value and the normalized minimum range value.

[0140] Specifically, assuming that the unwrapped image is phase_wrapped, a preset jump threshold value thes is set, each row image rowImg of the normalized processed unwrapped phase image phase_unwrapped2048 is traversed, assuming that the rowImg row number is r, the following operations are performed:

[0141] Each pixel pixel of each row image rowImg is traversed, the compensation coefficient i=0 is initialized, and assuming that the column index of pixel is c;

[0142] If c≠0 and c=set3[i+1], then i=i+1, otherwise no change is made;

[0143] If the current pixel pixel is located in the right side area of the i-th true zero point, that is, c≥set3[i] and c<boundaryArray[i][0], a local phase+column average double condition judgment strategy is adopted. For the rising trend ( fuhao Final=1), if the current pixel satisfies that the phase value is less than the negative preset jump threshold value, and the phase average value of the column where the current pixel is located is greater than the difference between the normalized maximum range value and the preset jump threshold value, that is:

[0144] ; (15)

[0145] Wherein, phase_unwrapped2048[r][c] represents the phase value corresponding to the pixel of the r-th row and the c-th column in the normalized processed unwrapped image, thes represents the preset jump threshold value, and meanOfColArray[c] represents the phase average value of the c-th column.

[0146] Let

[0147] ; (16)

[0148] where phase_wrapped[r][c] represents the compensated phase value of the pixel in the rth row and the cth column, and 4096 corresponds to the difference between the normalized maximum range value and the normalized minimum range value, i.e. the periodic phase compensation is applied with (i+1) times.

[0149] If the phase value of the current pixel is greater than or equal to the negative preset jump threshold value, or the phase average value of the column in which the current pixel is located is less than or equal to the difference between the normalized maximum range value and the preset jump threshold value, then:

[0150] ; (17)

[0151] i.e. the periodic phase compensation is applied with i times.

[0152] Further, for the falling trend ( fuhao Final=-1), if the phase value of the current pixel is greater than the preset jump threshold value, and the phase average value of the column in which the current pixel is located is less than the sum of the normalized minimum range value and the preset jump threshold value, i.e.

[0153] ; (18)

[0154] then the phase of the current pixel is applied with - (i+1) times of periodic phase compensation, i.e.

[0155] ; (19)

[0156] i.e. the periodic phase compensation is applied with -(i+1) times.

[0157] If the phase value of the current pixel is less than or equal to the preset jump threshold value, or the phase average value of the column in which the current pixel is located is greater than or equal to the sum of the normalized minimum range value and the preset jump threshold value, then the phase of the current pixel is applied with -i times of periodic phase compensation:

[0158] ; (20)

[0159] i.e. the periodic phase compensation is applied with -i times.

[0160] If the current pixel pixels is located in the jump region between the ith true zero point and the (i+1)th true zero point, i.e. c≥boundaryArray[i][0] and c<boundaryArray[i][1], then the phase sign is directly determined.

[0161] For the rising trend ( fuhao Final=1), if the phase value of the current pixel is greater than 0, i.e.

[0162] ; (21)

[0163] Then, i times periodic phase compensation is applied to the current pixel:

[0164] ; (22)

[0165] That is, (i+1) times periodic phase compensation is applied.

[0166] If the phase value of the current pixel is less than or equal to 0, then i+1 times periodic phase compensation is applied to the current pixel:

[0167] ; (23)

[0168] That is, (i+1) times periodic phase compensation is applied.

[0169] For a falling trend (fuhaoFinal=-1), if the phase value of the current pixel is greater than 0, then - (i+1) times periodic phase compensation is applied to the current pixel:

[0170] ; (24)

[0171] That is, -(i+1) times periodic phase compensation is applied.

[0172] If the phase value of the current pixel is less than or equal to 0, then -i times periodic phase compensation is applied to the current pixel:

[0173] ; (25)

[0174] That is, -i times periodic phase compensation is applied.

[0175] If the current pixel is located in the left side region of the i+1th true zero point, i.e., c≥boundaryArray[i][1] and c<set3[i+1], a double condition judgment is also adopted.

[0176] For a rising trend (fuhaoFinal=1), if the phase value of the current pixel is greater than the preset jump threshold value, and the phase average value of the column where the current pixel is located is less than the sum of the normalized minimum range value and the preset jump threshold value, i.e.:

[0177] ; (26)

[0178] Then, i times periodic phase compensation is applied to the current pixel:

[0179] ; (27)

[0180] That is, i times periodic phase compensation is applied.

[0181] If the phase value of the current pixel is less than or equal to the preset jump threshold value, or the phase average value of the column where the current pixel is located is greater than or equal to the sum of the normalized minimum range value and the preset jump threshold value, i.e. Final = 1, the current pixel is subjected to (i+1) times of periodic phase compensation:

[0182] ; (28)

[0183] i.e. (i+1) times of periodic phase compensation is applied.

[0184] For a falling trend (Final = -1), if the phase value of the current pixel is less than the negative preset jump threshold value, and the phase average value of the column where the current pixel is located is greater than the difference between the normalized maximum range value and the preset jump threshold value, i.e. fuhao

[0185] ; (29)

[0186] i.e. -i times of periodic phase compensation is applied.

[0187] ; (30)

[0188] i.e. -i times of periodic phase compensation is applied.

[0189] If the phase value of the current pixel is greater than or equal to the negative preset jump threshold value, or the phase average value of the column where the current pixel is located is less than or equal to the difference between the normalized maximum range value and the preset jump threshold value, i.e. Final = -1, the current pixel is subjected to -(i+1) times of periodic phase compensation:

[0190] ; (31)

[0191] i.e. -(i+1) times of periodic phase compensation is applied.

[0192] i is dynamically generated by the zero-crossing point number, realizing automatic periodic counting of the whole image. The entire processing procedure only needs to traverse the image once, greatly saving the processing time.

[0193] Further, in some embodiments, after obtaining the unwound image, further comprising:

[0194] normalizing the unwound image to obtain a normalized unwound image.

[0195] ​Specifically, assuming the normalized unwrapped image as phase_normalized, calculating the phase mean value of the 0th column image of the unwrapped image phase_wrapped as mean_first, and the phase mean value of the N-1th column image of the unwrapped image phase_wrapped as mean_last, then traversing each pixel point phase_wrapped[r][c] of the unwrapped image phase_wrapped, and setting phase_normalized[r][c]=phase_wrapped[r][c]-c*(mean_last-mean_first) / (N-1)-mean_first, to realize the global normalization of the unwrapped image phase.

[0196] The method provided by the above embodiment is further described below through a specific embodiment.

[0197] A set of unwrapped phase images phase_unwrapped is selected, as shown in FIG. 8(a), the zero point neighborhood threshold nearZero=10, the sliding window radius rad=5, the minimum distance constraint minDis=20, the left and right boundary threshold boundary_th=256, and the jump threshold thes=512 are taken, respectively, to obtain the unwrapped phase image phase_wrapped, as shown in FIG. 8(b), and finally obtain the normalized phase image phase_normalized, as shown in FIG. 8(c). The example shows that in the case of different trends and defects with phase mutations on the image, the method provided by the embodiment can correctly realize the phase unwrapping processing.

[0198] Reference Figure 9 In some embodiments, an image phase unwrapping device is also provided, comprising:

[0199] The image acquisition module 201 is configured to acquire a to-be-unwrapped phase image and perform normalization processing;

[0200] The phase calculation module 202 is configured to calculate the phase mean value of the normalized to-be-unwrapped phase image to obtain a column mean value array of the phase mean value of each column of pixels;

[0201] The trend judgment module 203 is configured to perform phase change trend judgment according to the column mean value array to obtain a phase change trend judgment result of the to-be-unwrapped phase image;

[0202] The zero point determination module 204 is configured to perform zero point detection and verification according to the column mean value array to determine the true zero point in the to-be-unwrapped phase image;

[0203] The boundary determination module 205 is configured to determine a phase jump boundary in the normalized unwrapping phase image according to the phase change trend judgment result and the true zero point.

[0204] The compensation module 206 is configured to divide the normalized unwrapping phase image into regions according to the phase jump boundary and the true zero point, and perform phase compensation on each region to obtain an unwrapping image.

[0205] Further, the normalization module 207 is further configured to perform normalization processing on the unwrapping image to obtain a normalized unwrapping image after obtaining the unwrapping image.

[0206] Further, the normalized unwrapping phase image includes M rows and N columns of pixels, where M and N are both integers greater than 1; and the column mean value array includes phase average values of the 0th column to the (N-1)th column.

[0207] The trend judgment module 203 performs phase change trend judgment according to the column mean value array to obtain a phase change trend judgment result of the unwrapping phase image, including:

[0208] The trend judgment module 203 performs phase change trend judgment according to the column mean value array to obtain a phase change trend judgment result of the unwrapping phase image, including:

[0209] The trend judgment module 203 performs phase change trend judgment according to the column mean value array to obtain a phase change trend judgment result of the unwrapping phase image, including:

[0210] If the normalized cumulative value is 1, it is determined that the phase change trend in the unwrapping phase image is an upward trend within a period, and if the normalized cumulative value is -1, it is determined that the phase change trend in the unwrapping phase image is a downward trend within a period.

[0211] Further, the zero point determination module 204 performs zero point detection and verification according to the column mean value array to determine a true zero point in the unwrapping phase image, including:

[0212] The zero point determination module 204 initializes a first zero point set, a second zero point set and a third zero point set, and adds the column index 0 to the third zero point set;

[0213] The zero point determination module 204 iterates through each phase average value in the column mean value array, compares the phase average value with a preset zero point neighborhood threshold, and if the absolute value of the phase average value is less than the preset zero point neighborhood threshold, stores the column index of the corresponding phase average value in the first zero point set.

[0214] Traverse the column indexes in the first zero point set, and determine a neighborhood range according to the column indexes in the first zero point set and preset left and right neighborhood values, calculate a local trend value sum of all column pixels in the neighborhood range corresponding to the column indexes, and if a ratio of the local trend value sum to the normalized cumulative value is greater than 0, store the corresponding column indexes in the second zero point set;

[0215] Store the 0th column index in the second zero point set in a third zero point set, traverse the column indexes in the second zero point set, and calculate an absolute value of a difference between a current column index and a previous column index, if the absolute value is greater than a preset minimum threshold, store the current column index in the third zero point set;

[0216] Store a column index corresponding to a last column pixel in the to-be-unwrapped phase image plus 1 in the third zero point set, and the column indexes in the obtained third zero point set are column indexes of true zeros.

[0217] Further, the boundary determination module 205 determines a phase jump boundary in the normalized to-be-unwrapped phase image according to the phase change trend judgment result and the true zero, including:

[0218] For an upward trend in a period, the following operations are performed on each true zero: according to the column index of the true zero, search column by column to the right from the normalized to-be-unwrapped phase image, if a current column index searched and a phase average value corresponding to the current column satisfy a first preset condition, determine that the current column is a right boundary of a stable region, and stop searching to the right; start from a next true zero, search column by column to the left from the normalized to-be-unwrapped phase image, if a current column index searched and a phase average value corresponding to the current column satisfy a second preset condition, determine that the current column is a left boundary of the stable region, and stop searching to the left;

[0219] For a downward trend in a period, the following operations are performed on each true zero: according to the column index of the true zero, search column by column to the right from the normalized to-be-unwrapped phase image, if a current column index searched and a phase average value corresponding to the current column satisfy a third preset condition, determine that the current column is a right boundary of a stable region, and stop searching to the right; start from a next true zero, search column by column to the left from the normalized to-be-unwrapped phase image, if a current column index searched and a phase average value corresponding to the current column satisfy a fourth preset condition, determine that the current column is a left boundary of the stable region, and stop searching to the left.

[0220] Further, the first preset condition is that the current searched column index is equal to a column number of the to-be-unwrapped phase image, or the phase average value corresponding to the current searched column is greater than a difference between a normalized maximum range value and a preset boundary threshold;

[0221] The second preset condition is that the currently searched column index is equal to 0, or the phase average value corresponding to the currently searched column is less than the sum of the normalized minimum range value and a preset boundary threshold value.

[0222] The third preset condition is that the currently searched column index is equal to the column number of the unwrapping phase image to be solved, or the phase average value corresponding to the currently searched column is less than the sum of the normalized minimum range value and a preset boundary threshold value.

[0223] The fourth preset condition is that the currently searched column index is equal to 0, or the phase average value corresponding to the currently searched column is greater than the difference between the normalized maximum range value and a preset boundary threshold value.

[0224] Further, one period includes a stable region and a first jump region.

[0225] The compensation module 206 performs regional division on the normalized unwrapping phase image to be solved according to the phase jump boundary and the true zero point, including:

[0226] In one period, the region between the true zero point and the right boundary of the most adjacent stable region is determined as the right region of the stable region, and the region between the true zero point and the left boundary of the most adjacent stable region is determined as the left region of the stable region, and the left region and the right region constitute the stable region.

[0227] The region between the closest stable region left boundary and the stable region right boundary is determined as the jump region.

[0228] Further, the compensation module 206 performs phase compensation on each region, including:

[0229] Traverse each row of pixels in the normalized unwrapping phase image to be solved, if the current pixel is located in the right region of the i th true zero point, for the upward trend, if the current pixel satisfies the fifth preset condition, the phase of the current pixel is compensated by i+1 times of the period phase, if the current pixel does not satisfy the fifth preset condition, the phase of the current pixel is compensated by i times of the period phase; for the downward trend, if the current pixel satisfies the sixth preset condition, the phase of the current pixel is compensated by - (i+1) times of the period phase, if the current pixel does not satisfy the sixth preset condition, the phase of the current pixel is compensated by -i times of the period phase.

[0230] If the current pixel is located in the jump region between the i th true zero point and the i+1 th true zero point, for the rising trend, if the current pixel satisfies the seventh preset condition, the i times periodic phase compensation is applied to the current pixel, if the current pixel does not satisfy the seventh preset condition, the i+1 times periodic phase compensation is applied to the current pixel; for the falling trend, if the current pixel satisfies the seventh preset condition, the - (i+1) times periodic phase compensation is applied to the current pixel, if the current pixel does not satisfy the seventh preset condition, the -i times periodic phase compensation is applied to the current pixel;

[0231] If the current pixel is located in the left region of the i+1 th true zero point, for the rising trend, if the current pixel satisfies the sixth preset condition, the i times periodic phase compensation is applied to the current pixel, if the current pixel does not satisfy the sixth preset condition, the i+1 times periodic phase compensation is applied to the current pixel; for the falling trend, if the current pixel satisfies the fifth preset condition, the -i times periodic phase compensation is applied to the current pixel, if the current pixel does not satisfy the fifth preset condition, the - (i+1) times periodic phase compensation is applied to the current pixel;

[0232] Wherein, i=0, 1, 2……a-1;a is the number of true zero points.

[0233] Further, the fifth preset condition is that the phase value of the current pixel is less than a negative preset jump threshold value, and the phase average value of the column where the current pixel is located is greater than the difference value between the normalized maximum range value and the preset jump threshold value;

[0234] The sixth preset condition is that the phase value of the current pixel is greater than the preset jump threshold value, and the phase average value of the column where the current pixel is located is less than the sum value of the normalized minimum range value and the preset jump threshold value;

[0235] The seventh preset condition is that the phase value of the current pixel is greater than 0;

[0236] The periodic phase compensation is the absolute value of the difference between the normalized maximum range value and the normalized minimum range value.

[0237] The image phase unwrapping method and device provided by the above embodiment at least have the following beneficial effects:

[0238] (1) In terms of calculation efficiency, the traditional two-dimensional pixel processing is reduced to column statistical feature analysis, and the stable region is uniformly processed instead of being iterated, so that the operation paradigm of the unwrapping algorithm is reconstructed, the efficiency is improved, and in addition, the iteration processing involved in the method provided by the present application can be calculated in parallel, which can also save the running time, so that the algorithm can be processed in real time on an embedded device, thereby saving the operation cost;

[0239] (2) In terms of measurement accuracy, the three innovations solve the inherent errors of traditional methods. First, the introduction of column mean statistics is equivalent to low-pass filtering in the vertical direction, effectively suppressing the influence of isolated noise points. Second, the dynamic double-threshold design accurately identifies real jump events, successfully eliminating the ±2π step error caused by local reflectivity mutations in traditional methods. Finally, the synergy of sliding window verification and minimum distance constraint solves the problem of missed detection in low-texture areas.

[0240] (3) Simple operation, easy to reproduce, using all-deterministic algorithm design, all operation modules (including column mean calculation, zero-crossing detection, boundary positioning and phase compensation) are implemented based on integer operation, avoiding the platform dependency brought by floating point operation, ensuring the efficient deployment of the algorithm in FPGA and other embedded hardware. This "algorithm-hardware" collaborative optimization feature makes the technology can be directly integrated into the lower machine system, providing a reliable solution for the popularization of phase unwrapping technology in resource-constrained scenarios, thereby reducing production costs.

[0241] While the preferred embodiments of the application have been described, additional modifications and changes can occur to those skilled in the art once they are made aware of the basic inventive concepts. Therefore, it is intended that the appended claims be construed to include all such modifications and changes as fall within the true spirit and scope of the present application. Obviously, various modifications and changes are possible in the present application without departing from the scope and spirit of the application. Accordingly, it is intended that the present application embrace all modifications and changes that fall within the scope of the claims and their equivalents.

Claims

1. An image phase unwrapping method, characterized by, The method comprises the following steps: obtaining a to-be-unwrapped phase image and performing normalization processing; calculating the average phase value of the normalized to-be-unwrapped phase image to obtain a column average value array of the average phase value of each column pixel; judging the phase change trend according to the column average value array to obtain a phase change trend judgment result of the to-be-unwrapped phase image; detecting and verifying the zero point according to the column average value array to determine the true zero point in the to-be-unwrapped phase image; determining the phase jump boundary in the normalized to-be-unwrapped phase image according to the phase change trend judgment result and the true zero point; dividing the normalized to-be-unwrapped phase image into regions according to the phase jump boundary and the true zero point, and performing phase compensation on each region to obtain an unwrapped image.

2. The method of claim 1, wherein, After obtaining the unwrapped image, the method further comprises the following steps: performing normalization processing on the unwrapped image to obtain a normalized unwrapped image.

3. The method of claim 1, wherein, The normalized to-be-unwrapped phase image comprises M rows and N columns of pixels, wherein M and N are both integers greater than 1; the column average value array comprises the average phase values of the 0th column to the (N-1)th column; judging the phase change trend according to the column average value array to obtain a phase change trend judgment result of the to-be-unwrapped phase image, which comprises the following steps: traversing the 1st average phase value to the (N-2)th average phase value in the column average value array, and calculating the local trend value of each column pixel according to the average phase values of the adjacent columns of the column pixel; calculating the cumulative value of all local trend values and performing normalization processing to obtain a normalized cumulative value; if the normalized cumulative value is 1, it is determined that the phase change trend in the to-be-unwrapped phase image is an upward trend within a period, and if the normalized cumulative value is -1, it is determined that the phase change trend in the to-be-unwrapped phase image is a downward trend within a period.

4. The method of claim 3, wherein, detecting and verifying the zero point according to the column average value array to determine the true zero point in the to-be-unwrapped phase image, which comprises the following steps: initializing a first zero point set, a second zero point set and a third zero point set, and adding the column index 0 to the third zero point set; traversing each average phase value in the column average value array, comparing the average phase value with a preset zero point neighborhood threshold, and storing the column index of the corresponding average phase value in the first zero point set according to the comparison result; traversing the column indexes in the first zero point set, determining the neighborhood range of the column indexes in the first zero point set, calculating the ratio of the sum of the local trend values of all column pixels in the neighborhood range corresponding to the column index to the normalized cumulative value, and storing the corresponding column index in the second zero point set according to the calculation result; storing the 0th column index in the second zero point set in the third zero point set, traversing the other column indexes in the second zero point set, calculating the absolute value of the difference between the current column index and the previous column index, and comparing the absolute value with a preset minimum threshold, and storing the current column index in the third zero point set according to the comparison result; storing the column index corresponding to the last column pixel in the to-be-unwrapped phase image plus 1 in the third zero point set, and obtaining the column indexes in the third zero point set as the column indexes of the true zero point.

5. The method of claim 1, wherein, According to the phase change trend judgment result and the true zero point, a phase jump boundary in the normalized to-be-unwrapped phase image is determined, including: For an upward trend in a period, for each true zero point, the following operations are performed: according to the column index of the true zero point, a right column-by-column search is performed in the normalized to-be-unwrapped phase image, if the current column index and the phase average value corresponding to the current column searched satisfy a first preset condition, the current column is determined as the right boundary of the stable region, and the right search is stopped; starting from the next true zero point, a left column-by-column search is performed in the normalized to-be-unwrapped phase image, if the current column index and the phase average value corresponding to the current column searched satisfy a second preset condition, the current column is determined as the left boundary of the stable region, and the left search is stopped; For a downward trend in a period, for each true zero point, the following operations are performed: according to the column index of the true zero point, a right column-by-column search is performed in the normalized to-be-unwrapped phase image, if the current column index and the phase average value corresponding to the current column searched satisfy a third preset condition, the current column is determined as the right boundary of the stable region, and the right search is stopped; starting from the next true zero point, a left column-by-column search is performed in the normalized to-be-unwrapped phase image, if the current column index and the phase average value corresponding to the current column searched satisfy a fourth preset condition, the current column is determined as the left boundary of the stable region, and the left search is stopped.

6. The method of claim 5, wherein, The first preset condition is that the current searched column index is equal to the column number of the to-be-unwrapped phase image, or the phase average value corresponding to the current searched column is greater than the difference between the normalized maximum range value and a preset boundary threshold; The second preset condition is that the current searched column index is equal to 0, or the phase average value corresponding to the current searched column is less than the sum of the normalized minimum range value and the preset boundary threshold; The third preset condition is that the current searched column index is equal to the column number of the to-be-unwrapped phase image, or the phase average value corresponding to the current searched column is less than the sum of the normalized minimum range value and the preset boundary threshold; The fourth preset condition is that the current searched column index is equal to 0, or the phase average value corresponding to the current searched column is greater than the difference between the normalized maximum range value and the preset boundary threshold.

7. The method of claim 6, wherein, One period includes one stable region and one jump region, and one stable region has one true zero point; According to the phase jump boundary and the true zero point, the normalized to-be-unwrapped phase image is regionally divided, including: In one period, a region between the true zero point and the most adjacent right boundary of the stable region is determined as a right region of the stable region, and a region between the true zero point and the most adjacent left boundary of the stable region is determined as a left region of the stable region, and the left region and the right region form the stable region; A region between the closest stable region left boundary and the stable region right boundary is determined as the jump region.

8. The method of claim 7, wherein, Phase compensation is performed on each region, including: Each row of pixels in the normalized to-be-unwrapped phase image is traversed; For the current pixel located in the region right to the i-th true zero point, the phase of the current pixel in the rising trend and satisfying the fifth preset condition is compensated by i+1 times of the period phase, and the phase of the current pixel not satisfying the fifth preset condition is compensated by i times of the period phase; the phase of the current pixel in the falling trend and satisfying the sixth preset condition is compensated by - (i+1) times of the period phase, and the phase of the current pixel not satisfying the sixth preset condition is compensated by -i times of the period phase; For the current pixel located in the transition region between the i-th true zero point and the i+1-th true zero point, the phase of the current pixel in the rising trend and satisfying the seventh preset condition is compensated by i times of the period phase, and the phase of the current pixel not satisfying the seventh preset condition is compensated by i+1 times of the period phase; the phase of the current pixel in the falling trend and satisfying the seventh preset condition is compensated by - (i+1) times of the period phase, and the phase of the current pixel not satisfying the seventh preset condition is compensated by -i times of the period phase; For the current pixel located in the region left to the i+1-th true zero point, the phase of the current pixel in the rising trend and satisfying the sixth preset condition is compensated by i times of the period phase, and the phase of the current pixel not satisfying the sixth preset condition is compensated by i+1 times of the period phase; the phase of the current pixel in the falling trend and satisfying the fifth preset condition is compensated by -i times of the period phase, and the phase of the current pixel not satisfying the fifth preset condition is compensated by - (i+1) times of the period phase; Wherein, i=0, 1, 2……a-1; a is the number of true zero points.

9. The method of claim 8, wherein, The fifth preset condition is that the phase value of the current pixel is less than a negative preset transition threshold, and the phase average value of the column where the current pixel is located is greater than the difference between the normalized maximum range value and the preset transition threshold; The sixth preset condition is that the phase value of the current pixel is greater than the preset transition threshold, and the phase average value of the column where the current pixel is located is less than the sum of the normalized minimum range value and the preset transition threshold; The seventh preset condition is that the phase value of the current pixel is greater than 0; The period phase compensation is the absolute value of the difference between the normalized maximum range value and the normalized minimum range value.

10. An image phase unwrapping apparatus characterized by comprising: It comprises: An image acquisition module for acquiring a to-be-unwrapped phase image and performing normalization processing; A phase calculation module for calculating the phase average value of the normalized to-be-unwrapped phase image to obtain a column average value array of the phase average value of each column of pixels; A trend judgment module for judging the phase change trend according to the column average value array to obtain a phase change trend judgment result of the to-be-unwrapped phase image; A zero point determination module for detecting and verifying the true zero points in the to-be-unwrapped phase image according to the column average value array; A boundary determination module for determining the phase transition boundary in the normalized to-be-unwrapped phase image according to the phase change trend judgment result and the true zero points; A compensation module for dividing the normalized to-be-unwrapped phase image into regions according to the phase transition boundary and the true zero points, and performing phase compensation on each region to obtain an unwrapped image.

Citation Information

Patent Citations

  • Real-time holographic phase unwrapping and phase distortion elimination method and system, computer equipment and storage medium

    CN120219205A

  • InSAR (Interferometric Synthetic Aperture Radar) image phase unwrapping method based on phase difference statistic model

    CN106093939A

  • SAR landslide early warning method based on landslide deformation information and meteorological data

    CN113281742A