Method and device for blocking and registering orthoimage of unmanned aerial vehicle from whole to local
Through the whole-then-partial UAV orthophoto block registration method, combined with fast Fourier transform, scale-invariant feature transformation based on point features and Poisson fusion algorithm, the problem of local distortion errors in UAV image registration is solved. problem, achieving high-precision image registration and automated processing.
Patent Information
- Application Number
- CN202410706050.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-03
- Publication Date
- 2024-08-27
- Estimated Expiration
- 2044-06-03
AI Technical Summary
Existing UAV orthophoto registration methods are difficult to effectively correct registration errors caused by local distortion when processing large-scale, high-resolution images, resulting in low registration accuracy or failure, and methods based on polynomials and spline functions It requires a large number of control points, is time-consuming, labor-intensive and costly.
The UAV orthophoto block registration method is adopted, which is first overall and then local. The fast Fourier transform algorithm is used for overall registration. After block processing, the scale-invariant feature conversion algorithm based on point features is used for local registration. The Poisson fusion algorithm performs image block splicing to reduce errors caused by distortion.
It realizes the automation of UAV image registration, improves the registration accuracy, reduces errors, saves time and energy, and the obtained registration results are superior to traditional ones in terms of peak signal-to-noise ratio, structural similarity and mutual information. method.
Smart Images

Figure CN118552867A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of remote sensing image processing, and in particular to a method and device for first overall and then local block registration of unmanned aerial vehicle orthophotos. Background Art
[0002] With the development of drone aerial photogrammetry technology in recent years, drone images have gradually become an indispensable part of the image data source in the field of remote sensing. Drone orthophotos can objectively reflect the state of the earth through real images and rich colors. They are widely used in image fusion, geological surveys, and illegal building change detection. Image registration is the key technical support for the above aspects. Its purpose is to eliminate or weaken the image spatial structure differences between the image to be registered and the reference image caused by shooting posture, terrain undulations, image projection, etc. Therefore, image registration is an indispensable part of remote sensing applications.
[0003] At present, grayscale-based registration methods and feature-based registration methods have been developed and matured. However, due to the large range and high resolution of UAV orthophotos, the ground object information is extremely complex. At the same time, there are different degrees of local distortion in the two phases of images. When the above methods are used to directly register the orthophotos, a large number of wrong matches will be generated, and the registration errors caused by local distortion cannot be corrected, resulting in low registration accuracy or even registration failure. Although the polynomial-based and spline-based registration methods can handle the registration errors caused by local distortion of the two phases of images, the above two registration methods require a sufficient number of evenly distributed control points, which is time-consuming, labor-intensive and costly. Therefore, it is necessary to provide a UAV orthophoto block registration method that first considers the whole and then the local to solve the above technical problems. Summary of the invention
[0004] The present invention provides a method and device for unmanned aerial vehicle orthophoto block registration that first focuses on the whole and then the parts, which can effectively reduce the registration error caused by the distortion of the two-phase images, improve the registration accuracy, and provide strong technical support for subsequent analysis applications such as change detection and geological survey.
[0005] The first aspect of the present invention provides a method for first overall and then local orthophoto registration of drone images, comprising the following steps:
[0006] Step 1, using a fast Fourier transform algorithm to convert the drone orthophoto from the image domain to the frequency domain, and obtaining the displacement of the drone orthophoto by calculating the phase-related pixel frequency domain offset, and performing overall registration of the drone orthophoto according to the displacement;
[0007] Step 2, the UAV orthophoto image after overall registration is processed into blocks to obtain multiple UAV orthophoto blocks, and each UAV orthophoto block is locally registered using a scale-invariant feature conversion algorithm based on point features;
[0008] Step 3: Use the Poisson fusion algorithm to stitch the multiple UAV orthophoto blocks after local registration to obtain the final registered UAV orthophoto.
[0009] Optionally, in one embodiment of the present invention, step 1 specifically includes:
[0010] Calculate the center point of the UAV orthophoto, determine the center matching window, and use the fast Fourier transform algorithm to calculate the phase-related pixel frequency domain offset estimation in the center matching window. Assume that the displacement vector is (μ0, ν0), then the displacement between the UAV orthophoto and the reference image is:
[0011] f2(x,y)=f1(x-μ0,y-ν0)
[0012] Among them, f2 is the UAV orthophoto, and f1 is the reference image;
[0013] The Fourier transforms corresponding to f1 and f2 are F1 and F2, and the displacement between the UAV orthophoto and the reference image in the frequency domain is:
[0014]
[0015] Among them, ε is XXX, η is XXX;
[0016] The mutual power spectrum between f1 and f2 is:
[0017]
[0018] Among them, F2 * (ε,η) represents the conjugate complex number of F2(ε,η), and the inverse Fourier transform of the cross-power spectrum image is performed to obtain the impulse response in the image domain. The distance between the peak at the registration point of the UAV orthophoto and the center position of the spectrum represents the pixel coordinate displacement vector (μ0,ν0) on the UAV orthophoto.
[0019] Optionally, in one embodiment of the present invention, after obtaining the pixel coordinate displacement vector, the step further includes:
[0020] Perform displacement detection on the pixel coordinate displacement vector, perform frequency domain offset estimation again on the registered drone orthophoto, and determine whether the displacement detection condition that the pixel coordinate displacement is zero displacement is met. If the displacement detection condition is not met, re-perform frequency domain offset estimation and determine whether the displacement detection condition is met until the maximum number of iterations is reached;
[0021] If the initial center matching window cannot meet the displacement detection condition, the center window is moved to the left by the length of the window size, and it is determined again whether the displacement detection condition is met. If it is still not met, the matching window position is changed clockwise around the center of the drone orthophoto;
[0022] After the displacement detection condition is passed, the only displacement greater than the preset threshold is eliminated according to the threshold condition. If the displacement does not meet the threshold condition, the matching window is reselected.
[0023] Optionally, in one embodiment of the present invention, step 2 specifically includes:
[0024] The UAV orthophoto block is multi-scaled using a scale space, where the scale space is obtained by convolution operation of a Gaussian function and the UAV orthophoto block;
[0025] In order to extract feature points at each scale, after the scale space pyramid is constructed, two adjacent layers at the same scale are subtracted to generate a Gaussian difference scale space;
[0026] In the Gaussian difference scale space, the local extreme point in the drone orthophoto block is obtained. If the local extreme point is the maximum or minimum value in the three adjacent scale neighborhoods, it is considered to be the extreme point. Then, the Gaussian difference function in the scale space is used to perform curve fitting using the Taylor expansion to obtain the position of the feature point.
[0027] The feature points are described using the neighborhood pixel information of the feature points, and the SIFT descriptor is constructed. The KNN algorithm is used to perform rough feature matching on the feature points, and the PROSAC algorithm is used for precise matching. The PROSAC algorithm first sorts the feature points in descending order according to their similarity, and then iteratively calculates the point pairs with strong similarity to solve the model parameters, and then obtains the homography matrix to perform projection transformation on the image, completing the local registration of each drone orthophoto block.
[0028] Optionally, in one embodiment of the present invention, step 3 further comprises:
[0029] The Poisson fusion algorithm makes the gradient field of the two-dimensional function f to be solved in the region Ω as similar as possible to the reference gradient field ν under the Dirichlet boundary condition. The expression is:
[0030]
[0031] Among them, f represents the drone orthophoto block, f * represents the drone orthophoto to be stitched. When the values of the two are the same on the function boundary, the Dirichlet boundary condition is satisfied. represents the gradient operator. If the solution of the above equation can satisfy the following Euler-Lagrange equation, then the following equation is the Poisson equation, expressed as:
[0032] Δf=div(v(x)),(x,y)∈Ω,f Ω =f * Ω
[0033] in, represents the Laplace operator, It represents the divergence of v = (u, v). When the UAV orthophoto blocks are fused, the guidance field of Poisson fusion is the gradient field of the set area of the UAV orthophoto blocks to be fused. The Poisson equation is solved to realize the fusion of UAV orthophoto blocks.
[0034] The second aspect of the present invention provides a device for first overall and then local orthophoto registration of drone images, comprising:
[0035] An overall registration module is used to convert the drone orthophoto from the image domain to the frequency domain using a fast Fourier transform algorithm, obtain the displacement of the drone orthophoto by calculating the phase-related pixel frequency domain offset, and perform overall registration on the drone orthophoto according to the displacement;
[0036] The local registration module is used to process the UAV orthophoto after overall registration in blocks to obtain multiple UAV orthophoto blocks, and locally register each UAV orthophoto block using a scale-invariant feature conversion algorithm based on point features;
[0037] The fusion module is used to use the Poisson fusion algorithm to stitch multiple UAV orthophoto blocks after local registration to obtain the final registered UAV orthophoto.
[0038] Optionally, in one embodiment of the present invention, the overall registration module is specifically used for:
[0039] Calculate the center point of the UAV orthophoto, determine the center matching window, and use the fast Fourier transform algorithm to calculate the phase-related pixel frequency domain offset estimation in the center matching window. Assume that the displacement vector is (μ0, ν0), then the displacement between the UAV orthophoto and the reference image is:
[0040] f2(x,y)=f1(x-μ0,y-ν0)
[0041] Among them, f2 is the UAV orthophoto, and f1 is the reference image;
[0042] The Fourier transforms corresponding to f1 and f2 are F1 and F2, and the displacement between the UAV orthophoto and the reference image in the frequency domain is:
[0043]
[0044] Among them, ε is XXX, η is XXX;
[0045] The mutual power spectrum between f1 and f2 is:
[0046]
[0047] Among them, F2 * (ε,η) represents the conjugate complex number of F2(ε,η), and the inverse Fourier transform of the cross-power spectrum image is performed to obtain the impulse response in the image domain. The distance between the peak at the registration point of the UAV orthophoto and the center position of the spectrum represents the pixel coordinate displacement vector (μ0,ν0) on the UAV orthophoto.
[0048] Optionally, in one embodiment of the present invention, the overall registration module is further used for:
[0049] Perform displacement detection on the pixel coordinate displacement vector, perform frequency domain offset estimation again on the registered drone orthophoto, and determine whether the displacement detection condition that the pixel coordinate displacement is zero displacement is met. If the displacement detection condition is not met, re-perform frequency domain offset estimation and determine whether the displacement detection condition is met until the maximum number of iterations is reached;
[0050] If the initial center matching window cannot meet the displacement detection condition, the center window is moved to the left by the length of the window size, and it is determined again whether the displacement detection condition is met. If it is still not met, the matching window position is changed clockwise around the center of the drone orthophoto;
[0051] After the displacement detection condition is passed, the only displacement greater than the preset threshold is eliminated according to the threshold condition. If the displacement does not meet the threshold condition, the matching window is reselected.
[0052] Optionally, in one embodiment of the present invention, the local registration module is specifically used for:
[0053] The UAV orthophoto block is multi-scaled using a scale space, where the scale space is obtained by convolution operation of a Gaussian function and the UAV orthophoto block;
[0054] In order to extract feature points at each scale, after the scale space pyramid is constructed, two adjacent layers at the same scale are subtracted to generate a Gaussian difference scale space;
[0055] In the Gaussian difference scale space, the local extreme point in the drone orthophoto block is obtained. If the local extreme point is the maximum or minimum value in the three adjacent scale neighborhoods, it is considered to be the extreme point. Then, the Gaussian difference function in the scale space is used to perform curve fitting using the Taylor expansion to obtain the position of the feature point.
[0056] The feature points are described using the neighborhood pixel information of the feature points, and the SIFT descriptor is constructed. The KNN algorithm is used to perform rough feature matching on the feature points, and the PROSAC algorithm is used for precise matching. The PROSAC algorithm first sorts the feature points in descending order according to their similarity, and then iteratively calculates the point pairs with strong similarity to solve the model parameters, and then obtains the homography matrix to perform projection transformation on the image, completing the local registration of each drone orthophoto block.
[0057] Optionally, in one embodiment of the present invention, the fusion module is specifically used for:
[0058] The Poisson fusion algorithm makes the gradient field of the two-dimensional function f to be solved in the region Ω as similar as possible to the reference gradient field ν under the Dirichlet boundary condition. The expression is:
[0059]
[0060] Among them, f represents the drone orthophoto block, f * represents the drone orthophoto to be stitched. When the values of the two are the same on the function boundary, the Dirichlet boundary condition is satisfied. represents the gradient operator. If the solution of the above equation can satisfy the following Euler-Lagrange equation, then the following equation is the Poisson equation, expressed as:
[0061] Δf=div(v(x)),(x,y)∈Ω,f Ω =f * Ω
[0062] in, represents the Laplace operator, It represents the divergence of v = (u, v). When the UAV orthophoto blocks are fused, the guidance field of Poisson fusion is the gradient field of the set area of the UAV orthophoto blocks to be fused. The Poisson equation is solved to realize the fusion of UAV orthophoto blocks.
[0063] A third aspect of the present invention provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the overall-first-local-later drone orthophoto block registration method as described in the above embodiment.
[0064] A fourth aspect of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, which, when executed by a processor, implements the above-mentioned overall-first-local-second drone orthophoto block registration method.
[0065] A fourth aspect of the present invention provides a computer program product, including a computer program, which is executed to implement the overall-first-local-later drone orthophoto block registration method as described in the above embodiments.
[0066] The method and device for first overall and then local block registration of drone orthophotos in the embodiments of the present invention have the following beneficial effects:
[0067] (1) The present invention does not require manual selection of control points during the UAV orthophoto registration process, thereby automating the registration process and saving time and effort.
[0068] (2) The present invention takes both the overall and local perspectives into consideration, and uses the pixel frequency domain offset estimation of the fast Fourier transform and the SIFT algorithm based on point features for overall registration and local registration, respectively, which effectively reduces the local registration error caused by the different degrees of distortion of the orthophotos in the two periods and improves the registration accuracy.
[0069] (3) Compared with the registration results obtained by the polynomial-based and spline-based registration methods, the registration results obtained by the present invention have a higher peak signal-to-noise ratio, higher structural similarity, greater mutual information and lower mean square error, and the obtained registration results are better.
[0070] Additional aspects and advantages of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0071] The above and / or additional aspects and advantages of the present invention will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:
[0072] Figure 1 A flowchart of a method for first overall and then local orthophoto registration of unmanned aerial vehicle (UAV) images according to an embodiment of the present invention;
[0073] Figure 2 A framework diagram of a method for first overall and then local block registration of UAV orthophotos provided according to an embodiment of the present invention;
[0074] Figure 3 The experimental area diagram of the embodiment of the present invention: (a) T1 period image; (b) T2 period image;
[0075] Figure 4is a local registration error map of an embodiment of the present invention;
[0076] Figure 5 This is the difference feature map of the eastern part of the image according to an embodiment of the present invention:
[0077] Figure 6 This is a difference feature map of the southern part of the image according to an embodiment of the present invention:
[0078] Figure 7 This is the western difference feature map of the image according to an embodiment of the present invention:
[0079] Figure 8 This is a feature map of the northern difference of an image according to an embodiment of the present invention:
[0080] Fig. 9 This is a feature map of the difference value in the middle of an image according to an embodiment of the present invention:
[0081] Fig.10 A schematic diagram of the structure of a device for first overall and then local registration of drone orthophotos according to an embodiment of the present invention. DETAILED DESCRIPTION
[0082] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and should not be construed as limiting the present invention.
[0083] Figure 1 The present invention provides a flowchart of a method for first global and then local block registration of UAV orthophotos according to an embodiment of the present invention.
[0084] like Figure 1 As shown, the overall-first-local-later drone orthophoto block registration method includes the following steps:
[0085] Step 1: Use the fast Fourier transform (FFTW) algorithm to convert the UAV orthophoto from the image domain to the frequency domain. The displacement of the UAV orthophoto is obtained by calculating the phase-related pixel frequency domain offset, and the UAV orthophoto is overall registered according to the displacement.
[0086] In an embodiment of the present invention, step 1 specifically includes:
[0087] Calculate the center point of the drone orthophoto, determine the center matching window, and use the fast Fourier transform algorithm in the center matching window to calculate the phase-related pixel frequency domain offset estimate. Assume that the displacement vector is (μ0, ν0), then the displacement between the drone orthophoto and the reference image is:
[0088] f2(x,y)=f1(x-μ0,y-ν0)
[0089] Among them, f2 is the UAV orthophoto, and f1 is the reference image;
[0090] The Fourier transforms corresponding to f1 and f2 are F1 and F2, and the displacement between the drone orthophoto and the reference image in the frequency domain is:
[0091]
[0092] Among them, ε is XXX, η is XXX;
[0093] The cross power spectrum (CPS) between f1 and f2 is:
[0094]
[0095] Among them, F2 * (ε,η) represents the conjugate complex number of F2(ε,η). The inverse Fourier transform of the cross-power spectrum image is performed to obtain the impulse response in the image domain. There is an obvious peak at the registration point of the image. The distance between the peak at the registration point of the UAV orthophoto and the center position of the spectrum represents the pixel coordinate displacement vector (μ0,ν0) on the UAV orthophoto.
[0096] Optionally, in one embodiment of the present invention, after obtaining the pixel coordinate displacement vector, the step further includes:
[0097] Perform displacement detection on the pixel coordinate displacement vector, and perform frequency domain offset estimation on the registered UAV orthophoto again to determine whether the displacement detection condition of zero displacement of pixel coordinate displacement is met. If the displacement detection condition is not met, re-estimate the frequency domain offset and determine whether the displacement detection condition is met until the maximum number of iterations is reached;
[0098] If the initial center matching window cannot meet the displacement detection condition, the center window is moved to the left by the length of the window size to determine whether the displacement detection condition is met again. If it still does not meet the condition, the matching window position is changed clockwise around the center of the drone orthophoto.
[0099] After the displacement detection condition is passed, the only displacement greater than the preset threshold is eliminated according to the threshold condition. If the displacement does not meet the threshold condition, the matching window is reselected.
[0100] Specifically, Figure 2 As shown, the present invention performs displacement detection after obtaining the coordinate displacement vector using the Fourier shift theorem, and the frequency domain offset estimation of the corrected target subset image must result in zero displacement, and the calculation formula is as follows:
[0101] f2(x,y)-f1(x-μ0,y-ν0)=0
[0102] If subsequent calculations still produce non-zero X / Y shifts, the match found is considered a false positive and rejected. In this case, the offset should be recalculated and the shift should be evaluated repeatedly for zero. This will continue until the maximum number of iterations. If the initial center match window does not meet the displacement test, move the center window to the left by the length of the window size, repeat the above steps again, and if the displacement test is still not met, change the match window position clockwise around the center of the image.
[0103] After displacement detection, a threshold check is performed to eliminate unrealistic large displacements, where r and c represent the displacements in the x and y directions respectively, and N is the number of pixels that meet the conditions. The calculation is shown as follows:
[0104]
[0105] If the displacement does not meet the threshold condition, the matching window should be reselected as in the previous step.
[0106] Step 2: The UAV orthophoto image after overall registration is divided into blocks to obtain multiple UAV orthophoto image blocks, and each UAV orthophoto image block is locally registered using a scale-invariant feature conversion algorithm based on point features.
[0107] The embodiment of the present invention uses the GDAL library to perform block processing on the drone orthophoto after overall registration, and then uses the SIFT (Scale-Invariant Feature Transform) algorithm based on point features to perform local registration on the image blocks.
[0108] Optionally, in one embodiment of the present invention, step 2 specifically includes:
[0109] The scale space is used to perform multi-scale scaling on the UAV orthophoto block. The scale space is obtained by convolution operation between Gaussian function and the UAV orthophoto block.
[0110] In order to extract feature points at each scale, after the scale space pyramid is constructed, two adjacent layers at the same scale are subtracted to generate a Gaussian difference scale space;
[0111] In the Gaussian difference scale space, the local extreme point in the drone orthophoto block is obtained. If the local extreme point is the maximum or minimum value in the three adjacent scale neighborhoods, it is considered to be the extreme point. Then, the Gaussian difference function in the scale space is used to perform curve fitting using the Taylor expansion to obtain the position of the feature point.
[0112] The feature points are described using the neighborhood pixel information of the feature points, and the SIFT descriptor is constructed. The KNN (k-Nearest Neighbor) algorithm is used to perform rough feature matching on the feature points, and the PROSAC (Progressive Sampling with Approximate Clustering) algorithm is used for precise matching. The PROSAC algorithm first sorts the feature points in descending order according to their similarity, and then iteratively calculates the point pairs with strong similarity to solve the model parameters, and then obtains the homography matrix to perform projection transformation on the image, completing the local registration of each drone orthophoto block.
[0113] Specifically, GDAL is a typical image processing library. The library is used to crop the drone orthophoto into image blocks with coordinates, and then the SIFT algorithm based on point features is used to locally align these image blocks. In order to extract the feature points in the image, the algorithm usually uses the scale space to perform multi-scale scaling on the image. The scale space is obtained by convolution operation of the Gaussian function and the original image. The formula is as follows:
[0114] L(x,y,σ)=G(x,y,σ)*I(x,y)
[0115] In the above formula, G(x, y, σ) represents a Gaussian function whose scale can be transformed, and the mathematical expression is:
[0116]
[0117] σ represents the scale space factor, which represents the number of times the original image to be registered is Gaussian blurred. The smaller σ is, the fewer the blur times are, and the higher the clarity of the image is, which represents the detailed features of the image. Conversely, the more times the original image is Gaussian blurred, the lower the clarity of the image is, which represents the general features of the image.
[0118] In order to extract feature points at each scale, after the scale space pyramid is constructed, the two adjacent layers at the same scale are subtracted to generate the Difference of Gauss (DoG) scale space. The calculation formula is as follows:
[0119] D(x,y,σ)=(G(x,y,kσ)-G(x,y,σ))*I(x,y)
[0120] =L(x,y,kσ)-L(x,y,σ)
[0121] In the above formula: D(x,y,σ) is the response value image, I(x,y) is the original image, σ is the smoothing factor, and the symbol * represents the convolution operation. In the DoG space, the local extreme points in the image can be obtained, and the extreme points are potential feature points. If the point is the maximum or minimum value in the three adjacent scale neighborhoods, it is considered to be an extreme point. Then, the scale space DoG function is used to perform curve fitting using the Taylor expansion to obtain the position of the feature point. The calculation formula is as follows:
[0122]
[0123]
[0124] In the above formula, X=(x,y,σ) T Let its derivative be zero, then we can find the position of the extreme point After obtaining the extreme point, the feature point neighborhood pixel information is used to describe the point, a sift descriptor is constructed, and the feature point is roughly matched using the KNN algorithm. The feature point rough matching can quickly eliminate invalid feature point pairs, but there are still many mismatches of the feature points after the rough screening, and feature precise matching is required. The present invention uses the PROSAC algorithm for precise matching. The PROSAC algorithm first sorts the feature points in descending order according to the similarity, and then iteratively calculates the point pairs with strong similarity, solves the model parameters, and then obtains the homography matrix to perform projection transformation on the image to complete the local registration of the drone orthophoto block.
[0125] Step 3: Use the Poisson fusion algorithm to stitch the multiple UAV orthophoto blocks after local registration to obtain the final registered UAV orthophoto.
[0126] Optionally, in one embodiment of the present invention, step 3 further comprises:
[0127] The Poisson fusion algorithm makes the gradient field of the two-dimensional function f to be solved in the region Ω as similar as possible to the reference gradient field ν under the Dirichlet boundary condition. The expression is:
[0128]
[0129] Among them, f represents the drone orthophoto block, f * represents the drone orthophoto to be stitched. When the values of the two are the same on the function boundary, the Dirichlet boundary condition is satisfied. represents the gradient operator. If the solution of the above equation can satisfy the following Euler-Lagrange equation, then the following equation is the Poisson equation, expressed as:
[0130] Δf=div(v(x)),(x,y)∈Ω,f Ω=f * Ω
[0131] in, represents the Laplace operator, It represents the divergence of v = (u, v). When the UAV orthophoto blocks are fused, the guidance field of Poisson fusion is the gradient field of the set area of the UAV orthophoto blocks to be fused. The Poisson equation is solved to achieve seamless fusion of UAV orthophoto blocks.
[0132] The overall-first-local-later drone orthophoto block registration method of the present invention is described in detail below through a specific embodiment.
[0133] The case study area is located in Tancheng Street, Tancheng County, Linyi City, Shandong Province, China. The data source is the dual-period images of the Huating area taken by the DJI Phantom 4Pro V2.0 drone on February 17, 2022 and July 16, 2022. The DJI Zhitu software is used to generate real-time images, and the orthophotos of the two periods with a spatial resolution of about 9.3 cm are obtained as follows: Figure 3 As shown in the figure, there are many types of buildings in the experimental area, including commercial areas, urban villages, and high-end residential areas. Due to the shooting posture, terrain undulations, and other reasons, the orthophotos of the two periods have different degrees of distortion in different areas, which brings challenges to the registration technology. The resulting local registration errors are as follows: Figure 4 As shown by Figure 4 It can be seen that when registering orthophotos from two periods, it is necessary to correct the registration errors of different degrees in different areas.
[0134] The block registration method of UAV orthophotos first overall and then local includes:
[0135] Step 1: Overall registration of drone orthophotos. By calculating the center point of the entire orthophoto, determine the position and size of the center matching window, extend a template window of 256×256 or 512×512 pixels according to the center of the image, obtain a subset of the image, and use the fastest Western Fourier algorithm to perform phase-related pixel frequency domain offset estimation within the matching window to calculate the overall offset.
[0136] After successful calculation of the sub-pixel X / Y displacement, a displacement check is performed, where the frequency domain offset estimation for the corrected target subset image must result in zero displacement. If the subsequent calculation still produces a non-zero X / Y displacement, the found match is considered a false positive and rejected. In this case, the offset should be recalculated and the evaluation is repeated to see if the displacement is now zero. This is continued until the maximum number of iterations is reached, which is set to 5 iterations for the experimental region. If the displacement still exists, the registration of the corresponding geographic location fails and the center matching window is changed. After the displacement detection, a threshold check is applied to eliminate unrealistically large displacements. This can be achieved by rejecting vectors exceeding a certain length, which is set to 15 reference image pixels for the experimental region. If the displacement does not meet the threshold condition, the matching window should be reselected as in the previous step.
[0137] If the initial center matching window cannot meet the displacement detection and threshold detection, move the center window to the left by the length of the window size and repeat the above steps. If it still does not meet the displacement detection, change the matching window position clockwise around the image center until the overall alignment is completed.
[0138] Step 2: GDAL library image segmentation and local registration based on point feature SIFT algorithm. The GDAL library is used to segment the drone orthophotos of the two periods. Each image will generate 525 image blocks of 1024×1024 size and 50% overlap. The SIFT algorithm based on point features is used in a loop to perform local registration of the 525 image blocks. The KNN algorithm is used to perform rough feature matching of feature points. The KNN Euclidean metric is set to 0.75 times the original distance. The PROSAC algorithm is used for precise matching. The matching threshold is set to 5 reference image pixels. The feature points are first sorted in descending order according to the similarity, and then the point pairs with strong similarity are iteratively calculated to solve the model parameters, and then the homography matrix is obtained to perform projection transformation on the image to complete the local registration of the drone orthophoto blocks.
[0139] Step 3: Use the Poisson fusion algorithm to stitch the 525 drone image blocks that have undergone local registration into a complete orthophoto in a coordinate cycle to complete the final registration work.
[0140] The difference feature map is used to reflect the registration results of the two periods of images. The difference feature maps of different regions of the image obtained by the unregistered, polynomial registration method, spline registration method, and the first global and then local block registration method are shown as follows: Figures 5 to 9 In the difference feature map, the dark part indicates the registration error. Since the resolution of the drone orthophoto is high, the seasonal changes of illumination, shadows, trees, and parking of cars will also be reflected in the difference feature map. Therefore, we only focus on the edge changes of the building to visually analyze the registration effect. Figures 5 to 9 It can be seen that when the two period images are not registered, there is a large registration error and the highlight noise is significant. The block registration proposed by the present invention, which is first overall and then local, can better reduce the registration errors of different degrees in different regions compared with the polynomial registration method and the spline registration method. At the same time, the present invention does not need to manually select a large number of evenly distributed control points, saving time and energy. In order to quantitatively evaluate the accuracy of the three algorithms, the root mean square error (RMSE), peak signal-to-noise ratio (PSNR), structural similarity (SSIM) and mutual information (MI) are used to evaluate the registration results of the two images using four indicators for evaluating image similarity, as shown in Table 1. Compared with the polynomial registration method and the spline registration method, the present invention has a higher peak signal-to-noise ratio, higher structural similarity, greater mutual information and lower mean square error, and the registration results are better, which can be effectively applied to the registration of UAV orthophotos.
[0141] Table 1
[0142] method RMSE PSNR SSIM MI Not registered 0.013260498 85.67960664 0.999996315 0.488367122 Polynomial Registration 0.012526520 86.17419476 0.999996935 0.488482308 Spline Registration 0.011021658 87.28586523 0.999997451 0.488795579 Block Registration 0.010605595 87.62010278 0.999997595 0.488882689
[0143] According to the first overall and then local drone orthophoto block registration method proposed in the embodiment of the present invention, the drone orthophoto is converted from the image domain to the frequency domain using the fast Fourier transform algorithm, and the phase-related pixel frequency domain offset is calculated to estimate the image displacement, thereby completing the overall registration. On this basis, the drone orthophoto is cropped, and the entire image is cropped into small image blocks. The SIFT algorithm based on point features is then used to perform local registration on these image blocks, and finally the Poisson fusion method is used to splice the image blocks, thereby completing the entire registration process. The present invention can effectively reduce the registration error caused by the distortion of the two-phase images, improve the registration accuracy, and provide strong technical support for subsequent analysis applications such as change detection and geological surveys.
[0144] Next, the overall-first-partial-later drone orthophoto block registration device proposed in an embodiment of the present invention will be described with reference to the accompanying drawings.
[0145] Fig.10 A schematic diagram of the structure of a device for first overall and then local registration of drone orthophotos according to an embodiment of the present invention.
[0146] like Fig.10 As shown, the first overall and then local drone orthophoto block registration device 10 includes: an overall registration module 100, a local registration module 200 and a fusion module 300.
[0147] Among them, the overall registration module 100 is used to convert the drone orthophoto from the image domain to the frequency domain using the fast Fourier transform algorithm, obtain the displacement of the drone orthophoto by calculating the phase-related pixel frequency domain offset, and perform overall registration on the drone orthophoto according to the displacement. The local registration module 200 is used to perform block processing on the drone orthophoto after overall registration to obtain multiple drone orthophoto blocks, and perform local registration on each drone orthophoto block using the scale-invariant feature conversion algorithm based on point features. The fusion module 300 is used to use the Poisson fusion algorithm to perform image block splicing on the multiple drone orthophoto blocks after local registration to obtain the final registered drone orthophoto.
[0148] Optionally, in one embodiment of the present invention, the overall registration module 100 is specifically used for:
[0149] Calculate the center point of the drone orthophoto, determine the center matching window, and use the fast Fourier transform algorithm in the center matching window to calculate the phase-related pixel frequency domain offset estimate. Assume that the displacement vector is (μ0, ν0), then the displacement between the drone orthophoto and the reference image is:
[0150] f2(x,y)=f1(x-μ0,y-ν0)
[0151] Among them, f2 is the UAV orthophoto, and f1 is the reference image;
[0152] The Fourier transforms corresponding to f1 and f2 are F1 and F2, and the displacement between the drone orthophoto and the reference image in the frequency domain is:
[0153]
[0154] Among them, ε is XXX, η is XXX;
[0155] The mutual power spectrum between f1 and f2 is:
[0156]
[0157] Among them, F2 * (ε,η) represents the conjugate complex number of F2(ε,η). The inverse Fourier transform of the cross-power spectrum image is performed to obtain the impulse response in the image domain. The distance between the peak at the registration point of the UAV orthophoto and the center position of the spectrum represents the pixel coordinate displacement vector (μ0,ν0) on the UAV orthophoto.
[0158] Optionally, in one embodiment of the present invention, the overall registration module 100 is further used for:
[0159] Perform displacement detection on the pixel coordinate displacement vector, and perform frequency domain offset estimation on the registered UAV orthophoto again to determine whether the displacement detection condition of zero displacement of pixel coordinate displacement is met. If the displacement detection condition is not met, re-estimate the frequency domain offset and determine whether the displacement detection condition is met until the maximum number of iterations is reached;
[0160] If the initial center matching window cannot meet the displacement detection condition, the center window is moved to the left by the length of the window size to determine whether the displacement detection condition is met again. If it still does not meet the condition, the matching window position is changed clockwise around the center of the drone orthophoto.
[0161] After the displacement detection condition is passed, the only displacement greater than the preset threshold is eliminated according to the threshold condition. If the displacement does not meet the threshold condition, the matching window is reselected.
[0162] Optionally, in one embodiment of the present invention, the local registration module 200 is specifically used for:
[0163] The scale space is used to perform multi-scale scaling on the UAV orthophoto block. The scale space is obtained by convolution operation between Gaussian function and the UAV orthophoto block.
[0164] In order to extract feature points at each scale, after the scale space pyramid is constructed, two adjacent layers at the same scale are subtracted to generate a Gaussian difference scale space;
[0165] In the Gaussian difference scale space, the local extreme point in the drone orthophoto block is obtained. If the local extreme point is the maximum or minimum value in the three adjacent scale neighborhoods, it is considered to be the extreme point. Then, the Gaussian difference function in the scale space is used to perform curve fitting using the Taylor expansion to obtain the position of the feature point.
[0166] The feature points are described using the neighborhood pixel information of the feature points, and the SIFT descriptor is constructed. The KNN algorithm is used to perform rough feature matching on the feature points, and the PROSAC algorithm is used for precise matching. The PROSAC algorithm first sorts the feature points in descending order according to their similarity, and then iteratively calculates the point pairs with strong similarity to solve the model parameters, and then obtains the homography matrix to perform projection transformation on the image, completing the local registration of each drone orthophoto block.
[0167] Optionally, in one embodiment of the present invention, the fusion module 300 is specifically used for:
[0168] The Poisson fusion algorithm makes the gradient field of the two-dimensional function f to be solved in the region Ω as similar as possible to the reference gradient field ν under the Dirichlet boundary condition. The expression is:
[0169]
[0170] Among them, f represents the drone orthophoto block, f * represents the drone orthophoto to be stitched. When the values of the two are the same on the function boundary, the Dirichlet boundary condition is satisfied. represents the gradient operator. If the solution of the above equation can satisfy the following Euler-Lagrange equation, then the following equation is the Poisson equation, expressed as:
[0171] Δf=div(v(x)),(x,y)∈Ω,f Ω =f * Ω
[0172] in, represents the Laplace operator, It represents the divergence of v = (u, v). When the UAV orthophoto blocks are fused, the guidance field of Poisson fusion is the gradient field of the set area of the UAV orthophoto blocks to be fused. The Poisson equation is solved to realize the fusion of UAV orthophoto blocks.
[0173] It should be noted that the above explanation of the embodiment of the method for first overall and then local drone orthophoto registration block by block is also applicable to the device for first overall and then local drone orthophoto registration block by block in this embodiment, and will not be repeated here.
[0174] According to the first overall then local drone orthophoto block registration device proposed in the embodiment of the present invention, the drone orthophoto is converted from the image domain to the frequency domain using the fast Fourier transform algorithm, and the phase-related pixel frequency domain offset is calculated to estimate the image displacement, thereby completing the overall registration. On this basis, the drone orthophoto is cropped, and the entire image is cropped into small image blocks. The SIFT algorithm based on point features is then used to perform local registration on these image blocks, and finally the Poisson fusion method is used to splice the image blocks, thereby completing the entire registration process. The present invention can effectively reduce the registration error caused by the distortion of the two-phase images, improve the registration accuracy, and provide strong technical support for subsequent analysis applications such as change detection and geological surveys.
[0175] Furthermore, an embodiment of the present invention also provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the overall-first-local-later drone orthophoto block registration method as described in the above embodiment.
[0176] Furthermore, an embodiment of the present invention provides a computer-readable storage medium, which stores a computer program. When the program is executed by a processor, it implements the above-mentioned overall-first-local-second drone orthophoto block registration method.
[0177] In addition, an embodiment of the present invention further provides a computer program product, including a computer program, which is executed to implement the overall-first-local-later drone orthophoto block registration method of the above embodiment.
[0178] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or N embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0179] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of the present invention, the meaning of "N" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0180] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, fragment or portion of code comprising one or N executable instructions for implementing the steps of a custom logical function or process, and the scope of the preferred embodiments of the present invention includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in reverse order depending on the functions involved, which should be understood by technicians in the technical field to which the embodiments of the present invention belong.
Claims
1. A method for block registration of UAV orthophotos, first overall and then local, characterized in that: The following steps are involved: Step 1, using a fast Fourier transform algorithm to convert the drone orthophoto from the image domain to the frequency domain, and obtaining the displacement of the drone orthophoto by calculating the phase-related pixel frequency domain offset, and performing overall registration of the drone orthophoto according to the displacement; Step 2, the UAV orthophoto image after overall registration is processed into blocks to obtain multiple UAV orthophoto blocks, and each UAV orthophoto block is locally registered using a scale-invariant feature conversion algorithm based on point features; Step 3: Use the Poisson fusion algorithm to stitch the multiple UAV orthophoto blocks after local registration to obtain the final registered UAV orthophoto.
2. The method according to claim 1, characterized in that The step 1 specifically includes: Calculate the center point of the UAV orthophoto, determine the center matching window, and use the fast Fourier transform algorithm to calculate the phase-related pixel frequency domain offset estimation in the center matching window. Assume that the displacement vector is (μ0, ν0), then the displacement between the UAV orthophoto and the reference image is: f2(x,y)=f1(x-μ0,y-ν0) Among them, f2 is the UAV orthophoto, and f1 is the reference image; The Fourier transforms corresponding to f1 and f2 are F1 and F2, and the displacement between the UAV orthophoto and the reference image in the frequency domain is: Among them, ε is XXX, η is XXX; The mutual power spectrum between f1 and f2 is: Among them, F2 * (ε,η) represents the conjugate complex number of F2(ε,η), and the inverse Fourier transform of the cross-power spectrum image is performed to obtain the impulse response in the image domain. The distance between the peak at the registration point of the UAV orthophoto and the center position of the spectrum represents the pixel coordinate displacement vector (μ0,ν0) on the UAV orthophoto.
3. The method according to claim 2, characterized in that After obtaining the pixel coordinate displacement vector, the method further includes: Perform displacement detection on the pixel coordinate displacement vector, perform frequency domain offset estimation again on the registered drone orthophoto, and determine whether the displacement detection condition that the pixel coordinate displacement is zero displacement is met. If the displacement detection condition is not met, re-perform frequency domain offset estimation and determine whether the displacement detection condition is met until the maximum number of iterations is reached; If the initial center matching window cannot meet the displacement detection condition, the center window is moved to the left by the length of the window size, and it is determined again whether the displacement detection condition is met. If it is still not met, the matching window position is changed clockwise around the center of the drone orthophoto; After the displacement detection condition is passed, the only displacement greater than the preset threshold is eliminated according to the threshold condition. If the displacement does not meet the threshold condition, the matching window is reselected.
4. The method according to claim 1, characterized in that: The step 2 specifically includes: The UAV orthophoto block is multi-scaled using a scale space, where the scale space is obtained by convolution operation of a Gaussian function and the UAV orthophoto block; In order to extract feature points at each scale, after the scale space pyramid is constructed, two adjacent layers at the same scale are subtracted to generate a Gaussian difference scale space; In the Gaussian difference scale space, the local extreme point in the drone orthophoto block is obtained. If the local extreme point is the maximum or minimum value in the three adjacent scale neighborhoods, it is considered to be the extreme point. Then, the Gaussian difference function in the scale space is used to perform curve fitting using the Taylor expansion to obtain the position of the feature point. The feature points are described using the neighborhood pixel information of the feature points, and the SIFT descriptor is constructed. The KNN algorithm is used to perform rough feature matching on the feature points, and the PROSAC algorithm is used for precise matching. The PROSAC algorithm first sorts the feature points in descending order according to their similarity, and then iteratively calculates the point pairs with strong similarity to solve the model parameters, and then obtains the homography matrix to perform projection transformation on the image, completing the local registration of each drone orthophoto block.
5. The method according to claim 1, characterized in that The step 3 further comprises: The Poisson fusion algorithm makes the gradient field of the two-dimensional function f to be solved in the region Ω as similar as possible to the reference gradient field ν under the Dirichlet boundary condition. The expression is: Among them, f represents the drone orthophoto block, f * represents the drone orthophoto to be stitched. When the values of the two are the same on the function boundary, the Dirichlet boundary condition is satisfied. represents the gradient operator. If the solution of the above equation can satisfy the following Euler-Lagrange equation, then the following equation is the Poisson equation, expressed as: Δf=div(v(x)),(x,y)∈Ω,f Ω =f * Ω in, represents the Laplace operator, It represents the divergence of v = (u, v). When the UAV orthophoto blocks are fused, the guidance field of Poisson fusion is the gradient field of the set area of the UAV orthophoto blocks to be fused. The Poisson equation is solved to realize the fusion of UAV orthophoto blocks.
6. A device for registering orthophotos of drones in blocks by first overall and then local, characterized in that: include: An overall registration module is used to convert the drone orthophoto from the image domain to the frequency domain using a fast Fourier transform algorithm, obtain the displacement of the drone orthophoto by calculating the phase-related pixel frequency domain offset, and perform overall registration on the drone orthophoto according to the displacement; The local registration module is used to process the UAV orthophoto after overall registration in blocks to obtain multiple UAV orthophoto blocks, and locally register each UAV orthophoto block using a scale-invariant feature conversion algorithm based on point features; The fusion module is used to use the Poisson fusion algorithm to stitch multiple UAV orthophoto blocks after local registration to obtain the final registered UAV orthophoto.
7. The device according to claim 6, characterized in that The overall registration module is specifically used for: Calculate the center point of the UAV orthophoto, determine the center matching window, and use the fast Fourier transform algorithm to calculate the phase-related pixel frequency domain offset estimation in the center matching window. Assume that the displacement vector is (μ0, ν0), then the displacement between the UAV orthophoto and the reference image is: f2(x,y)=f1(x-μ0,y-ν0) Among them, f2 is the UAV orthophoto, and f1 is the reference image; The Fourier transforms corresponding to f1 and f2 are F1 and F2, and the displacement between the UAV orthophoto and the reference image in the frequency domain is: Among them, ε is XXX, η is XXX; The mutual power spectrum between f1 and f2 is: Among them, F2 * (ε,η) represents the conjugate complex number of F2(ε,η), and the inverse Fourier transform of the cross-power spectrum image is performed to obtain the impulse response in the image domain. The distance between the peak at the registration point of the UAV orthophoto and the center position of the spectrum represents the pixel coordinate displacement vector (μ0,ν0) on the UAV orthophoto.
8. An electronic device, characterized in that: include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the overall-first-local-later drone orthophoto block registration method as described in any one of claims 1 to 5.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: The program is executed by a processor to implement the overall-first-local-later drone orthophoto block registration method as described in any one of claims 1 to 5.
10. A computer program product, comprising a computer program, characterized in that The computer program is executed to implement the overall-first-local-later drone orthophoto block registration method as described in any one of claims 1-5.
Citation Information
Patent Citations
Robust multi-source satellite remote sensing image registration method
CN103077527A
Template-based Poisson fusion image splicing method, system and device, and medium
CN110390640A
Multi-modal image registration method with scale, rotation and radiation invariance
CN111462198A
Optimization method based on unmanned aerial vehicle camera image stitching algorithm
CN116433492A
Unmanned aerial vehicle remote sensing image adaptive registration method, device, equipment and storage medium
CN116703704A
Cited By
Remote sensing image inter-band registration method based on phase correlation method
CN119379757A
