Image registration method and defect detection method

By combining Fourier transform and inverse Fourier transform, the scaling factor, rotation angle and translation of the image are calculated, which solves the problem of low image registration accuracy in the existing technology and achieves higher-precision image registration.

CN114882088BActive Publication Date: 2026-02-24SHANGHAI JINGJI SEMICON TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210466691.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-29
Publication Date
2026-02-24
Estimated Expiration
2042-04-29

AI Technical Summary

Technical Problem

In existing technologies, image registration accuracy is low, especially when there is scaling and rotation between images, the accuracy of translation is severely affected by the scaling factor and the accuracy of the rotation angle.

Method used

By calculating the energy spectrum of the corresponding regions of the image to be registered and the reference image, and transforming it into a log-polar coordinate system, the phase cross-correlation spectrum of the energy spectrum is obtained. An inverse Fourier transform with upsampling is performed, the scaling factor and rotation angle are calculated, and then the image transformation is performed. Finally, the translation amount is calculated based on the transformed Fourier spectrum.

Benefits of technology

It significantly improves the accuracy of scaling factors and rotation angles during image registration, thereby improving the accuracy of translation and enhancing the overall accuracy of image registration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114882088B_ABST
    Figure CN114882088B_ABST
Patent Text Reader

Abstract

The application provides an image registration method and a defect detection method, and the inverse Fourier transform of the up-sampled phase cross-correlation spectrum of the energy spectrum is performed to obtain a scaling factor and a rotation angle of a to-be-registered image relative to a reference image, the to-be-registered image is transformed according to the scaling factor and the rotation angle, the translation of the to-be-registered image relative to the reference image is calculated based on the Fourier spectrum of the corresponding region of the to-be-registered image after transformation and the Fourier spectrum of the corresponding region of the reference image, and the accuracy of the scaling factor and the rotation angle in the registration process is significantly improved through the inverse Fourier transform of the up-sampling, and then the accuracy of the translation is improved, and the accuracy of the image registration is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image processing technology, and in particular to an image registration method and a defect detection method. Background Technology

[0002] Image registration refers to the process of converting two or more images to the same coordinate system. The process of image registration is commonly used in computer vision, medical imaging, remote sensing images, and military security.

[0003] Two or more images may have been acquired at different times, under different lighting conditions, from different angles, at different depths, using different sensors, or even from different devices. Image registration is essential for comparing and stitching these images together, but the accuracy of image registration in existing technologies is relatively low.

[0004] Therefore, it is necessary to provide a novel image registration method and defect detection method to solve the above-mentioned problems existing in the prior art. Summary of the Invention

[0005] The purpose of this invention is to provide an image registration method and a defect detection method to improve image registration accuracy.

[0006] To achieve the above objectives, the image registration method of the present invention performs registration based on corresponding regions of the image to be registered and the reference image, and includes the following steps:

[0007] S1: Calculate the Fourier spectra of the corresponding regions of the image to be registered and the reference image, respectively;

[0008] S2: Calculate the energy spectrum of the Fourier spectrum of the corresponding region of the image to be registered and the energy spectrum of the Fourier spectrum of the corresponding region of the reference image, and transform the energy spectrum into a logarithmic polar coordinate system;

[0009] S3: Based on the energy spectrum of the corresponding region of the image to be registered in the logarithmic polar coordinate system and the energy spectrum of the corresponding region of the reference image, obtain the phase cross-correlation spectrum of the energy spectrum in the corresponding region;

[0010] S4: Perform an upsampled inverse Fourier transform on the phase cross-correlation spectrum of the energy spectrum to obtain the scaling factor and rotation angle of the image to be registered relative to the reference image.

[0011] S5: Transform the image to be registered according to the scaling factor and the rotation angle;

[0012] S6: Based on the Fourier spectrum of the corresponding region of the image to be registered after transformation and the Fourier spectrum of the corresponding region of the reference image, calculate the translation amount of the image to be registered relative to the reference image, and complete the image registration according to the translation amount.

[0013] The beneficial effect of the image registration method is as follows: An upsampled inverse Fourier transform is performed on the phase cross-correlation spectrum of the energy spectrum to obtain the scaling factor and rotation angle of the image to be registered relative to the reference image. The image to be registered is then transformed based on the scaling factor and rotation angle. Based on the Fourier spectrum of the corresponding region of the transformed image to be registered and the Fourier spectrum of the corresponding region of the reference image, the translation amount of the image to be registered relative to the reference image is calculated. Through the upsampled inverse Fourier transform, the accuracy of the scaling factor and rotation angle during the registration process is significantly improved, thereby improving the accuracy of the translation amount and ultimately enhancing the overall image registration accuracy.

[0014] Optionally, S4 includes: performing a global upsampling inverse Fourier transform on the phase cross-correlation spectrum of the energy spectrum to obtain a first spatial function, finding the peak position of the first spatial function, and calculating the scaling factor and rotation angle of the image to be registered relative to the reference image.

[0015] Optionally, S4 includes:

[0016] The phase cross-correlation spectrum of the energy spectrum is subjected to inverse Fourier transform to obtain a second spatial function. The peak position is found in the second spatial function, and the first scaling factor and the first rotation angle are calculated.

[0017] Based on the phase cross-correlation spectrum of the energy spectrum, the neighborhood of the peak position in the second spatial function is found and local upsampling inverse Fourier transform is performed to obtain the third spatial function. The peak position of the third spatial function is then found to obtain the second scaling factor and the second rotation angle.

[0018] Calculate the product of the first scaling factor and the second scaling factor to obtain the scaling factor of the image to be registered relative to the reference image; calculate the sum of the first rotation angle and the second rotation angle to obtain the rotation angle of the image to be registered relative to the reference image.

[0019] Optionally, calculating the translation amount of the image to be registered relative to the reference image based on the Fourier spectrum of the corresponding region of the transformed image to be registered and the Fourier spectrum of the corresponding region of the reference image includes:

[0020] Based on the Fourier spectrum of the corresponding region of the image to be registered and the Fourier spectrum of the corresponding region of the reference image, the phase cross-correlation spectrum of the spectrum in the corresponding region is obtained;

[0021] A global upsampling inverse Fourier transform is performed on the phase cross-correlation spectrum of the spectrum to obtain a fourth spatial domain function; the peak position of the fourth spatial domain function is found to obtain the translation amount of the image to be registered relative to the reference image.

[0022] Optionally, calculating the translation amount of the image to be registered relative to the reference image based on the Fourier spectrum of the corresponding region of the transformed image to be registered and the Fourier spectrum of the corresponding region of the reference image includes:

[0023] Based on the Fourier spectrum of the corresponding region of the image to be registered and the Fourier spectrum of the corresponding region of the reference image, the phase cross-correlation spectrum of the spectrum in the corresponding region is obtained;

[0024] The inverse Fourier transform of the phase cross-correlation spectrum of the spectrum is performed to obtain the fifth spatial domain function;

[0025] Find the peak position of the fifth spatial function to obtain the first translation amount;

[0026] Based on the phase cross-correlation spectrum of the spectrum, the neighborhood of the peak position in the fifth spatial function is found and subjected to local upsampling inverse Fourier transform to obtain the sixth spatial function. The peak position of the sixth spatial function is found to obtain the second translation amount. The sum of the first translation amount and the second translation amount is calculated to obtain the translation amount of the image to be registered relative to the reference image.

[0027] The present invention also provides an image defect detection method, comprising:

[0028] The image registration method described above is used to complete the image registration between the image to be detected and the reference image.

[0029] The image to be detected and the reference image are resampled to obtain the target detection region, and the target detection region is identified to achieve defect detection.

[0030] Optionally, the resampling includes cropping the image to be registered and the reference image to obtain the overlapping region of the image to be registered and the reference image, and using the overlapping region as the target detection region.

[0031] Optionally, identifying the target detection region to achieve defect detection includes differentiating the image pixels of the target detection region and detecting defects based on the result of the difference. Attached Figure Description

[0032] Figure 1 This is a flowchart of the image registration method of the present invention;

[0033] Figure 2 This is a flowchart illustrating the calculation of the scaling factor and rotation angle of the image to be registered relative to the reference image in some embodiments of the present invention;

[0034] Figure 3 This is a flowchart illustrating the calculation of the translation amount of the image to be registered relative to the reference image in some embodiments of the present invention;

[0035] Figure 4 This is a flowchart for calculating the translation amount of the image to be registered relative to the reference image in some other embodiments of the present invention;

[0036] Figure 5 These are schematic diagrams of reference images in some embodiments of the present invention;

[0037] Figure 6 This is a schematic diagram of the images to be registered in some embodiments of the present invention;

[0038] Figure 7 This is a schematic diagram of the phase cross-correlation spectrum of the energy spectrum after global upsampling and inverse Fourier transform in some embodiments of the present invention.

[0039] Figure 8 This is a schematic diagram of the phase cross-correlation spectrum of the spectrum after global upsampling and inverse Fourier transform in some embodiments of the present invention;

[0040] Figure 9 This is a schematic diagram of the phase cross-correlation spectrum of the energy spectrum in some embodiments of the present invention;

[0041] Figure 10 As shown in some embodiments of the present invention Figure 9 A schematic diagram after performing local upsampling and inverse Fourier transform based on the peak position;

[0042] Figure 11 This is the phase cross-correlation spectrum of the spectra of the image to be registered and the reference image after transformation according to the scaling factor and rotation angle in some embodiments of the present invention;

[0043] Figure 12 As shown in some embodiments of the present invention Figure 11 A schematic diagram after performing local upsampling and inverse Fourier transform based on the peak position;

[0044] Figure 13 This is a schematic diagram illustrating the overlap effect between the image to be registered and the reference image after resampling in some embodiments of the present invention. Detailed Implementation

[0045] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions in the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without inventive effort are within the scope of protection of this invention. Unless otherwise defined, the technical or scientific terms used herein should have the ordinary meaning understood by those skilled in the art. The terms "comprising" and similar expressions used herein mean that the element or object preceding the word covers the element or object listed following the word and its equivalents, but do not exclude other elements or objects.

[0046] To address the problems existing in the prior art, embodiments of the present invention provide an image registration method. (Refer to...) Figure 1 The image registration method is based on the corresponding regions of the image to be registered and the reference image, and specifically includes the following steps:

[0047] S1: Calculate the Fourier spectra of the corresponding regions of the image to be registered and the reference image, respectively;

[0048] S2: Calculate the energy spectrum of the Fourier spectrum of the corresponding region of the image to be registered and the energy spectrum of the Fourier spectrum of the corresponding region of the reference image, and transform the energy spectrum into a logarithmic polar coordinate system;

[0049] S3: Based on the energy spectrum of the corresponding region of the image to be registered in the logarithmic polar coordinate system and the energy spectrum of the corresponding region of the reference image, obtain the phase cross-correlation spectrum of the energy spectrum in the corresponding region;

[0050] S4: Perform an upsampled inverse Fourier transform on the phase cross-correlation spectrum of the energy spectrum to obtain the scaling factor and rotation angle of the image to be registered relative to the reference image.

[0051] S5: Transform the image to be registered according to the scaling factor and the rotation angle;

[0052] S6: Based on the Fourier spectrum of the corresponding region of the image to be registered after transformation and the Fourier spectrum of the corresponding region of the reference image, calculate the translation amount of the image to be registered relative to the reference image, and complete the image registration according to the translation amount.

[0053] For example, the corresponding region can be the entire original image of the image to be registered and the reference image, or it can be a corresponding region with the same or similar structure in the image to be registered and the reference image selected based on the original image. In this invention, at least one set of corresponding regions of the image to be registered and the reference image can be obtained by cropping the image to be registered and the reference image.

[0054] In existing technologies, image registration typically needs to be done at the sub-pixel level, such as 1 / 5 of a pixel or even higher. When only translation exists between images, upsampling can achieve the required registration accuracy. However, when scaling and rotation also exist between images, the corresponding scaling factor and rotation angle must first be found before appropriate transformations can be performed to obtain the translation amount. Therefore, the accuracy of the scaling factor and rotation angle will inevitably have a significant impact on the accuracy of the translation amount. For example, when there is a 0.1-degree error in the rotation angle, the difference in the edge of a 1000-pixel image can reach about 1 pixel. Similarly, errors in the scaling factor have a similar effect.

[0055] This invention performs an upsampled inverse Fourier transform based on the phase cross-correlation spectrum of the energy spectra in corresponding regions of the image to be registered and the reference image to obtain the scaling factor and rotation angle of the image to be registered relative to the reference image. The image to be registered is then transformed according to the scaling factor and rotation angle. Based on the Fourier spectrum of the corresponding region of the transformed image to be registered and the Fourier spectrum of the corresponding region of the reference image, the translation amount of the image to be registered relative to the reference image is calculated. Through the upsampled inverse Fourier transform, the accuracy of the scaling factor and rotation angle during the registration process is significantly improved, as is the accuracy of the translation amount, thereby improving the overall image registration accuracy.

[0056] In some embodiments, within the corresponding region, according to the displacement theorem of Fourier transform, the function of the reference image is denoted as g1(x, y), and the Fourier spectrum of the reference image is denoted as G1(u, v). The function of the image to be registered is denoted as g2(x, y), and the Fourier spectrum of the image to be registered is denoted as G2(u, v). The translation relationship between the functions g1(x, y) and g2(x, y) is: g1(x, y) = g2(xa, yb). Based on the displacement theorem of Fourier transform, the relationship between the Fourier spectrum of the reference image and the Fourier spectrum of the image to be registered is: G2(u, v) = F(g2(xa, yb)) = G1(u, v)exp(-j2π(a u + bv)), where F() represents the Fourier transform operation, a and b represent the total translation amount of the image to be registered relative to the reference image, and u and v represent the spatial frequencies.

[0057] Furthermore, the phase cross-correlation spectrum within the corresponding region can be obtained from the complex conjugate conj(G2(fu,v)) of the Fourier spectrum G1(u,v) of the reference image and the Fourier spectrum G2(u,v) of the image to be registered, where conj(G2(fu,v)) is the formula for the phase cross-correlation spectrum.

[0058]

[0059] Perform an inverse Fourier transform on the phase cross-correlation spectrum to obtain the Dirac function in the spatial domain. Find the peak of the function, and the coordinates of the peak position are the pixel-level translations a and b of the image to be registered relative to the reference image.

[0060] Furthermore, the function g1(x, y) is transformed by a function g2(x, y) through translation (x0, y0), rotation by an angle θ0, and scaling by a size s. Based on the scaling property of the Fourier transform and the displacement theorem of the Fourier transform, we can obtain...

[0061] g2(x, y)=g1(s(xcosθ0+ysinθ0-x0), s(-xsinθ0+ycosθ0-y0))

[0062]

[0063] Energy spectrum P1 is obtained by taking the energy of Fourier spectrum G1, and energy spectrum P2 is obtained by taking the energy of Fourier spectrum G2. Comparing energy spectra P1 and P2 in logarithmic polar coordinates yields the following results.

[0064] It can be seen that the relationship between energy spectra P1 and P2 is very similar to the relationship between functions g1 and g2. Therefore, the scaling factor s = e can be obtained from the cross-correlation spectrum of the energy spectra using the displacement theorem. d and rotation angle θ0.

[0065] In some embodiments, S4 includes: performing a global upsampling inverse Fourier transform on the phase cross-correlation spectrum of the energy spectrum to obtain a first spatial function, finding the peak position of the first spatial function, and calculating the scaling factor and rotation angle of the image to be registered relative to the reference image.

[0066] In some embodiments, a global upsampling inverse Fourier transform is performed on the phase cross-correlation spectrum of the energy spectrum to obtain a first spatial domain function. The peak position of the first spatial domain function is found, and the scaling factor and rotation angle of the image to be registered relative to the reference image are calculated. The specific calculation process includes:

[0067] Calculate the transformation matrices T'1 and T'2 based on the upsampling factor and the size of the energy spectrum;

[0068] Multiply the transformation matrix T'1, the phase cross-correlation spectrum of the energy spectrum, and the transformation matrix T'2 to obtain the first spatial domain function;

[0069] Find the peak position of the first spatial domain function to obtain the scaling factor and rotation angle of the image to be registered relative to the reference image.

[0070] In some specific embodiments, for an image with M rows and N columns, its function is g(x, y), and its Fourier spectrum is G(u, v), where G(u, v) = T1g(x, y)T2.

[0071]

[0072]

[0073] Its spatial domain coordinates are X = (x1, x2, ..., x...). N ) T Y = (y1, y2, ..., y M ) T Frequency domain coordinates U = (u1, u2, ..., u N ) T V = (v1, v2, ..., v) M ) T After obtaining the Fourier spectrum G(u, v), upsampling is performed to obtain X = (x... s x s +Dx,...,x e ) T , Y = (y s y s +Dy,...,y e ) T Then you can obtain

[0074] g′(x, y)=T′1G(u,v)T′2,

[0075]

[0076]

[0077] When performing global upsampling, let x s =x1, x e =x N y s =y1, y e =y M When performing local upsampling, the peak value (x) is taken. p y p The size of the vicinity is (2x) r ,2y r The neighborhood of ), that is, let xs =x p -x r x e =x p +x r y s =y p -y r , y e =y p -y r .

[0078] In some embodiments, if only rotation and translation exist between the image to be registered and the reference image, then

[0079] g2(x,y)=g1(xcosθ0+ysinθ0-x0,-xsinθ0+ycosθ0-y0)

[0080]

[0081] P2(u,v)=P1(ucosθ0+vsinθ0,-usinθ0+vcosθ0)

[0082] P1(ρ, θ) = P2(ρ, θ - θ0)

[0083] To improve the efficiency of image registration, we can obtain the 1*N transformation matrix T1, the phase cross-correlation spectrum of the N*M energy spectrum, and the M*N transformation matrix T2, and then obtain the phase cross-correlation spectrum of the energy spectrum of the 1*M vector.

[0084] Figure 2 This is a flowchart illustrating the calculation of the scaling factor and rotation angle of the image to be registered relative to the reference image in some embodiments of the present invention. (Refer to...) Figure 2 S4 includes:

[0085] S41: Perform an inverse Fourier transform on the phase cross-correlation spectrum of the energy spectrum to obtain a second spatial function. Find the peak position in the second spatial function and calculate the first scaling factor and the first rotation angle.

[0086] S42: Based on the phase cross-correlation spectrum of the energy spectrum, the neighborhood of the peak position in the second spatial function is found and local upsampling inverse Fourier transform is performed to obtain the third spatial function. The peak position of the third spatial function is then found to obtain the second scaling factor and the second rotation angle.

[0087] S43: Calculate the product of the first scaling factor and the second scaling factor to obtain the scaling factor of the image to be registered relative to the reference image; calculate the sum of the first rotation angle and the second rotation angle to obtain the rotation angle of the image to be registered relative to the reference image.

[0088] Figure 3 This is a flowchart illustrating the calculation of the translation amount of the image to be registered relative to a reference image in some embodiments of the present invention. (Refer to...) Figure 3 The step of calculating the translation amount of the image to be registered relative to the reference image based on the Fourier spectrum of the corresponding region of the transformed image to be registered and the Fourier spectrum of the corresponding region of the reference image includes:

[0089] S61: Based on the Fourier spectrum of the corresponding region of the image to be registered and the Fourier spectrum of the corresponding region of the reference image, obtain the phase cross-correlation spectrum of the spectrum in the corresponding region;

[0090] S62: Perform a global upsampling inverse Fourier transform on the phase cross-correlation spectrum of the spectrum to obtain the fourth spatial domain function;

[0091] S63: Find the peak position of the fourth spatial function to obtain the translation amount of the image to be registered relative to the reference image.

[0092] Figure 4 This is a flowchart illustrating the calculation of the translation amount of the image to be registered relative to the reference image in some embodiments of the present invention. (Refer to...) Figure 4 The step of calculating the translation amount of the image to be registered relative to the reference image based on the Fourier spectrum of the corresponding region of the transformed image to be registered and the Fourier spectrum of the corresponding region of the reference image includes:

[0093] S611: Based on the Fourier spectrum of the corresponding region of the image to be registered and the Fourier spectrum of the corresponding region of the reference image, obtain the phase cross-correlation spectrum of the spectrum in the corresponding region;

[0094] S622: Perform an inverse Fourier transform on the phase cross-correlation spectrum of the spectrum to obtain the fifth spatial domain function;

[0095] S633: Find the peak position of the fifth spatial function to obtain the first translation amount;

[0096] S644: Based on the phase cross-correlation spectrum of the spectrum, the neighborhood of the peak position in the fifth spatial function is found and local upsampling inverse Fourier transform is performed to obtain the sixth spatial function. The peak position of the sixth spatial function is found to obtain the second translation amount. The sum of the first translation amount and the second translation amount is calculated to obtain the translation amount of the image to be registered relative to the reference image.

[0097] Figure 5 These are schematic diagrams of reference images in some embodiments of the present invention; Figure 6 This is a schematic diagram of the images to be registered in some embodiments of the present invention; Figure 7 This is a schematic diagram of the phase cross-correlation spectrum of the energy spectrum after global upsampling and inverse Fourier transform in some embodiments of the present invention. Figure 8 This is a schematic diagram of the phase cross-correlation spectrum of the spectrum after global upsampling and inverse Fourier transform in some embodiments of the present invention; Figure 9 This is a schematic diagram of the phase cross-correlation spectrum of the energy spectrum in some embodiments of the present invention; Figure 10 As shown in some embodiments of the present invention Figure 9 A schematic diagram after performing local upsampling and inverse Fourier transform based on the peak position; Figure 11 This is the phase cross-correlation spectrum of the spectra of the image to be registered and the reference image after transformation according to the scaling factor and rotation angle in some embodiments of the present invention; Figure 12 As shown in some embodiments of the present invention Figure 11 A schematic diagram of the inverse Fourier transform after local upsampling based on the peak position.

[0098] The present invention also provides an image defect detection method, comprising:

[0099] The image registration method described above is used to complete the image registration between the image to be detected and the reference image.

[0100] The image to be detected and the reference image are resampled to obtain the target detection region, and the target detection region is identified to achieve defect detection.

[0101] In some embodiments, the resampling includes cropping the image to be registered and the reference image to obtain an overlapping region between the image to be registered and the reference image, and using the overlapping region as the target detection region.

[0102] In some embodiments, identifying the target detection region to achieve defect detection includes differentially dividing the image pixels of the target detection region and detecting defects based on the result of the differential division.

[0103] Figure 13 This is a schematic diagram illustrating the overlap effect between the image to be registered and the reference image after resampling in some embodiments of the present invention.

[0104] In some embodiments, the resampling includes direct interpolation in the spatial domain, including bilinear interpolation, bicubic interpolation, and nonlinear interpolation.

[0105] In some embodiments, the resampling includes an inverse Fourier transform (IDFT), and the total translation is (x0, y0), then the resampled image is obtained from... get.

[0106] While embodiments of the present invention have been described in detail above, it will be apparent to those skilled in the art that various modifications and variations can be made to these embodiments. However, it should be understood that such modifications and variations fall within the scope and spirit of the invention as set forth in the claims. Furthermore, the invention described herein may have other embodiments and can be implemented or carried out in various ways.

Claims

1. An image registration method, characterized in that, Registration is performed based on corresponding regions of the image to be registered and the reference image, including the following steps: S1: Calculate the Fourier spectra of the corresponding regions of the image to be registered and the reference image, respectively; S2: Calculate the energy spectrum of the Fourier spectrum of the corresponding region of the image to be registered and the energy spectrum of the Fourier spectrum of the corresponding region of the reference image, and transform the energy spectrum into a logarithmic polar coordinate system; S3: Based on the energy spectrum of the corresponding region of the image to be registered in the logarithmic polar coordinate system and the energy spectrum of the corresponding region of the reference image, obtain the phase cross-correlation spectrum of the energy spectrum in the corresponding region; S4: Perform an upsampled inverse Fourier transform on the phase cross-correlation spectrum of the energy spectrum to obtain the scaling factor and rotation angle of the image to be registered relative to the reference image. S4 includes: performing a global upsampling inverse Fourier transform on the phase cross-correlation spectrum of the energy spectrum to obtain a first spatial domain function, finding the peak position of the first spatial domain function, and calculating the scaling factor and rotation angle of the image to be registered relative to the reference image. Alternatively, S4 includes: performing an inverse Fourier transform on the phase cross-correlation spectrum of the energy spectrum to obtain a second spatial function, finding the peak position in the second spatial function, and calculating the first scaling factor and the first rotation angle. Based on the phase cross-correlation spectrum of the energy spectrum, the neighborhood of the peak position in the second spatial function is found and local upsampling inverse Fourier transform is performed to obtain the third spatial function. The peak position of the third spatial function is then found to obtain the second scaling factor and the second rotation angle. Calculate the product of the first scaling factor and the second scaling factor to obtain the scaling factor of the image to be registered relative to the reference image; calculate the sum of the first rotation angle and the second rotation angle to obtain the rotation angle of the image to be registered relative to the reference image. S5: Transform the image to be registered according to the scaling factor and the rotation angle; S6: Based on the Fourier spectrum of the corresponding region of the image to be registered after transformation and the Fourier spectrum of the corresponding region of the reference image, obtain the phase cross-correlation spectrum of the corresponding region of the image to be registered and the corresponding region of the reference image. Perform inverse Fourier transform with global upsampling or inverse Fourier transform with local upsampling based on the phase cross-correlation spectrum, calculate the translation amount of the image to be registered relative to the reference image, and complete the image registration based on the translation amount.

2. The image registration method according to claim 1, characterized in that, The step of calculating the translation amount of the image to be registered relative to the reference image based on the Fourier spectrum of the corresponding region of the transformed image to be registered and the Fourier spectrum of the corresponding region of the reference image includes: Based on the Fourier spectrum of the corresponding region of the image to be registered and the Fourier spectrum of the corresponding region of the reference image, the phase cross-correlation spectrum of the spectrum in the corresponding region is obtained. A global upsampling inverse Fourier transform is performed on the phase cross-correlation spectrum of the spectrum to obtain the fourth spatial domain function; Find the peak position of the fourth spatial domain function to obtain the translation amount of the image to be registered relative to the reference image.

3. The image registration method according to claim 1, characterized in that, The step of calculating the translation amount of the image to be registered relative to the reference image based on the Fourier spectrum of the corresponding region of the transformed image to be registered and the Fourier spectrum of the corresponding region of the reference image includes: Based on the Fourier spectrum of the corresponding region of the image to be registered and the Fourier spectrum of the corresponding region of the reference image, the phase cross-correlation spectrum of the spectrum in the corresponding region is obtained. The inverse Fourier transform of the phase cross-correlation spectrum of the spectrum is performed to obtain the fifth spatial domain function; Find the peak position of the fifth spatial function to obtain the first translation amount; Based on the phase cross-correlation spectrum of the spectrum, the neighborhood of the peak position in the fifth spatial function is found and subjected to local upsampling inverse Fourier transform to obtain the sixth spatial function. The peak position of the sixth spatial function is found to obtain the second translation amount. The sum of the first translation amount and the second translation amount is calculated to obtain the translation amount of the image to be registered relative to the reference image.

4. An image defect detection method, characterized in that, include: Image registration between the image to be detected and the reference image is completed using the image registration method described in any one of claims 1 to 3. The image to be detected and the reference image are resampled to obtain the target detection region, and the target detection region is identified to achieve defect detection.

5. The image defect detection method according to claim 4, characterized in that, The resampling process involves cropping the image to be registered and the reference image to obtain the overlapping region between the image to be registered and the reference image, and using the overlapping region as the target detection region.

6. The image defect detection method according to claim 4, characterized in that, The method of identifying the target detection region to achieve defect detection includes performing differential analysis on the image pixels of the target detection region and detecting defects based on the result of the differential analysis.

Citation Information

Patent Citations

  • Fourier-Merlin transform and maximum mutual information theory based image registration method

    CN104200463A

  • Printed matter defect detection method and device based on artifact elimination

    CN111986190A