Non-stationary image filtering method, system and medium based on fast Fourier transform
By using a fast Fourier transform-based image filtering method, interpolation and FFT algorithms are employed to perform fast convolution filtering of local images, solving the problem of high computational cost in traditional methods and achieving efficient digital image filtering.
Patent Information
- Application Number
- CN202411338352.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-25
- Publication Date
- 2025-01-10
- Estimated Expiration
- 2044-09-25
AI Technical Summary
Existing image filtering algorithms, which use a "spatial interpolation + convolution" approach, have high computational costs and cannot meet the current industry's demand for fast digital image filtering.
A fast Fourier transform-based method is adopted. The local image under the action of the discrete filtering function is selected by the interpolation algorithm, and the FFT algorithm is used for fast convolution filtering. The image is then weighted by the interpolation weight coefficients and finally accumulated to obtain the non-steady-state filtered image.
While ensuring computational accuracy, it significantly improves computational efficiency, providing a precise and efficient digital image unsteady filtering processing scheme.
Smart Images

Figure CN118864261B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image filtering, and in particular to a non-steady-state image filtering method, system and medium based on fast Fourier transform. Background Art
[0002] Image filtering is a digital image processing method that improves the quality of an image by changing or emphasizing specific information in the image. The filtering operation involves applying a filter or convolution kernel to each pixel of the image to produce a new pixel value. This new pixel value is usually a linear combination of the original pixel values, with weights determined by the design of the filter. Image filtering technology is widely used in medical image processing, computer vision, remote sensing image processing and other fields.
[0003] Since image filtering functions are often non-steady-state multidimensional signals, traditional image filtering algorithms can only be performed through the "spatial interpolation + convolution" method. That is, first, the filter function is interpolated through the interpolation algorithm to obtain the filter function for any pixel in the image; then the spatial convolution calculation formula is used to perform filtering operations to obtain the convolution filtering result of the pixel. The implementation process of this technical solution is simple, but the calculation cost is high, and it is difficult to meet the current industry's urgent technical needs for fast digital image filtering methods. Summary of the invention
[0004] The purpose of the present invention is to provide a non-steady-state image filtering method, system and medium based on fast Fourier transform, so as to solve the problem that the existing "spatial interpolation + convolution" has high computational cost and is difficult to meet the current industry's urgent technical needs for digital image fast filtering processing methods.
[0005] In order to achieve the above-mentioned invention object, the technical solution adopted by the present invention is:
[0006] In a first aspect, the present invention provides a non-stationary image filtering method based on fast Fourier transform, the method comprising:
[0007] Based on the interpolation algorithm, multiple local images are selected to be acted upon by the discrete filter function;
[0008] Based on the FFT algorithm, the selected multiple local images are subjected to fast convolution filtering with discrete filter functions to obtain multiple local filtered images;
[0009] Based on the interpolation weight coefficient of the interpolation algorithm, each local filter image is weighted to obtain a plurality of interpolation coefficient weighted local filter images;
[0010] A plurality of interpolation coefficient weighted local filtered images are accumulated to obtain a non-stationary filtered image.
[0011] Preferably, based on the interpolation algorithm, a plurality of local images to which the discrete filter function acts are selected, including:
[0012] Select any single-point filter function from the discrete filter functions;
[0013] Based on the interpolation algorithm, the local digital image within the action range of the single-point filter function is determined, and the local digital image within the action range of the single-point filter function is used as a local image. The local digital images within the action range of multiple single-point filter functions constitute multiple local images.
[0014] Preferably, the function expression of the local image is:
[0015] ;
[0016] In the formula, is the local digital image within the scope of the single-point filter function, y represents the center point of the filter function, and x represents the local digital image range within the scope of the single-point filter function. is the image extraction function, and M(x) is the overall digital image to be filtered.
[0017] Preferably, based on the FFT algorithm, the selected multiple local images are subjected to fast convolution filtering processing with discrete filter functions respectively to obtain multiple local filtered images, including:
[0018] In the wave number domain, each single point filter function and the corresponding local image are forward transformed based on the FFT algorithm to obtain multiple spatial convolutions.
[0019] Based on the FFT algorithm, multiple spatial convolutions are inversely transformed to obtain multiple local filtered images.
[0020] Preferably, the function expression of the local filtered image is:
[0021] ;
[0022] Where M y (x) is the local filtered image, FFT() is the Fourier transform, FFT -1 () is the inverse Fourier transform, P is the single-point filter function , R y is the local digital image within the range of the single-point filter function , Represents the spatial range of a single-point filter function.
[0023] Preferably, the function expression of the interpolation coefficient weighted local filtering image is:
[0024] ;
[0025] In the formula, is the interpolation coefficient weighted local filtered image, is the interpolation weight coefficient of the interpolation algorithm, M y (x) is the local filtered image.
[0026] Preferably, the function expression of the non-stationary filtered image is:
[0027] ;
[0028] In the formula, is a non-stationary filtered image, is the interpolation coefficient weighted local filtered image.
[0029] In a second aspect, the present invention provides a non-stationary image filtering device based on fast Fourier transform, which is used to implement the above-mentioned non-stationary image filtering based on fast Fourier transform, characterized in that the device comprises:
[0030] An image extraction module, used for selecting a plurality of local images to which a discrete filter function is applied based on an interpolation algorithm;
[0031] An image filtering module is used to perform fast convolution filtering processing on multiple selected local images and discrete filter functions based on the FFT algorithm to obtain multiple local filtered images;
[0032] An image weighting module is used to perform weighted processing on each local filter image based on the interpolation weight coefficient of the interpolation algorithm to obtain a plurality of interpolation coefficient weighted local filter images;
[0033] The image summation module is used to accumulate multiple interpolation coefficient weighted local filtering images to obtain a non-steady-state filtering image.
[0034] In a third aspect, 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 implements the above-mentioned non-steady-state image filtering based on fast Fourier transform when executing the computer program.
[0035] In a fourth aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the above-mentioned non-steady-state image filtering based on fast Fourier transform.
[0036] The beneficial effects of the present invention are mainly embodied in:
[0037] Through reasonable algorithm design, the present invention can use FFT to perform fast calculation of non-steady-state image filtering, can greatly improve calculation efficiency while ensuring calculation accuracy, and can provide an accurate and efficient implementation plan for non-steady-state filtering processing of digital images. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] The accompanying drawings are used to provide a further understanding of the embodiments of the present invention and constitute a part of the specification. Together with the following specific implementations, they are used to explain the embodiments of the present invention, but do not constitute a limitation on the embodiments of the present invention. In the accompanying drawings:
[0039] Figure 1 is a flow chart of a non-steady-state image filtering method based on fast Fourier transform provided by an embodiment of the present invention;
[0040] Figure 2 is a block diagram of a non-steady-state image filtering device based on fast Fourier transform provided by an embodiment of the present invention;
[0041] Figure 3 is the reflection coefficient image of the existing two-dimensional Overthrust model;
[0042] Figure 4 It is the non-steady discrete filter function field obtained for the two-dimensional Overthrust model;
[0043] Figure 5 It uses traditional algorithms to Figure 3 right Figure 4 Image after non-steady-state filtering;
[0044] Figure 6 It is a non-steady-state filtered image obtained by the non-steady-state image filtering method based on fast Fourier transform of the present invention. DETAILED DESCRIPTION
[0045] The specific implementation of the embodiment of the present invention is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described here is only used to illustrate and explain the embodiment of the present invention, and is not used to limit the embodiment of the present invention.
[0046] Embodiment 1: Figure 1 is a flowchart of a non-steady-state image filtering method based on fast Fourier transform provided by an embodiment of the present invention. Figure 1 As shown, this embodiment provides a non-steady-state image filtering method based on fast Fourier transform, and the method includes:
[0047] Step S10: Based on the interpolation algorithm, multiple local images are selected to be acted upon by the discrete filter function.
[0048] Specifically, based on the interpolation algorithm, multiple local images to which the discrete filter function acts are selected, including:
[0049] Step S101: Select any single-point filter function from the discrete filter functions;
[0050] Step S102: determining a local digital image within the action range of the single-point filter function based on an interpolation algorithm, taking the local digital image within the action range of the single-point filter function as a local image, and multiple local digital images within the action range of multiple single-point filter functions constitute multiple local images.
[0051] In this embodiment, the discrete filter function is a space-variant image filter function. A single-point filter function is selected from the space-variant image filter function. , represents the spatial range of the single-point filter function, and selects the local digital image within the range of the single-point filter function according to the interpolation method to be adopted (the present embodiment preferably adopts cubic convolution interpolation, which is an algorithm in image processing for enlarging the image; it is a more complex and computationally intensive image interpolation method, but it can usually provide a smoother and higher-quality enlargement effect than bilinear interpolation or nearest neighbor interpolation) .
[0052] In this embodiment, the function expression of the local image is:
[0053] ;
[0054] In the formula, is the local digital image within the scope of the single-point filter function, y represents the center point of the filter function, and x represents the local digital image range within the scope of the single-point filter function. is an image extraction function, which is 1 within the valid range x and 0 outside the range. M(x) is the entire digital image to be filtered.
[0055] Step S20: performing fast convolution filtering processing on the selected multiple local images and the discrete filter function based on the FFT (Fast Fourier Transform) algorithm to obtain multiple local filtered images.
[0056] Specifically, based on the FFT algorithm, a plurality of selected local images are subjected to fast convolution filtering processing with discrete filter functions respectively to obtain a plurality of local filtered images, including:
[0057] Step S201: in the wave number domain, each single point filter function and the corresponding local image are respectively forward transformed based on the FFT algorithm to obtain multiple spatial convolutions;
[0058] Step S202: performing inverse transformation on multiple spatial convolutions based on the FFT algorithm to obtain multiple local filtered images.
[0059] In this embodiment, the function expression of the local filtered image is:
[0060] ;
[0061] Where M y (x) is the local filtered image, FFT() is the Fourier transform, FFT -1 () is the inverse Fourier transform, P is the single-point filter function , R y is the local digital image within the range of the single-point filter function , Represents the spatial range of a single-point filter function.
[0062] Step S30: Based on the interpolation weight coefficients of the interpolation algorithm, weighted processing is performed on each local filtered image to obtain a plurality of interpolation coefficient weighted local filtered images.
[0063] In this embodiment, the function expression of the interpolation coefficient weighted local filtering image is:
[0064] ;
[0065] In the formula, is the interpolation coefficient weighted local filtered image, is the interpolation weight coefficient of the interpolation algorithm (which is centered on y and has a valid spatial range of x), M y (x) is the local filtered image.
[0066] Step S40: Accumulate a plurality of interpolation coefficient weighted local filtering images to obtain a non-steady-state filtering image.
[0067] In this embodiment, the interpolation coefficient weighted local filtering images formed by all single-point filtering functions are accumulated to obtain the final non-steady-state filtering image, and the function expression of the non-steady-state filtering image is:
[0068] ;
[0069] In the formula, is a non-stationary filtered image, The interpolation coefficients are weighted locally filtered images.
[0070] Through reasonable algorithm design, the present invention can use FFT to perform fast calculation of non-steady-state image filtering, can greatly improve calculation efficiency while ensuring calculation accuracy, and can provide an accurate and efficient implementation plan for non-steady-state filtering processing of digital images.
[0071] Embodiment 2: Figure 2 is a block diagram of a non-steady-state image filtering device based on fast Fourier transform provided by an embodiment of the present invention, such as Figure 2 As shown, this embodiment provides a non-steady-state image filtering device based on fast Fourier transform, which is used to implement the non-steady-state image filtering based on fast Fourier transform of embodiment 1, characterized in that the device includes:
[0072] An image extraction module, used for selecting a plurality of local images to which a discrete filter function is applied based on an interpolation algorithm;
[0073] An image filtering module is used to perform fast convolution filtering processing on multiple selected local images and discrete filter functions based on the FFT algorithm to obtain multiple local filtered images;
[0074] An image weighting module is used to perform weighted processing on each local filter image based on the interpolation weight coefficient of the interpolation algorithm to obtain a plurality of interpolation coefficient weighted local filter images;
[0075] The image summation module is used to accumulate multiple interpolation coefficient weighted local filtering images to obtain a non-steady-state filtering image.
[0076] This embodiment also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the non-steady-state image filtering based on fast Fourier transform of the first embodiment when executing the computer program.
[0077] This embodiment further provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the non-steady-state image filtering based on fast Fourier transform of the first embodiment is implemented.
[0078] Through reasonable algorithm design, the present invention can use FFT to perform fast calculation of non-steady-state image filtering, can greatly improve calculation efficiency while ensuring calculation accuracy, and can provide an accurate and efficient implementation plan for non-steady-state filtering processing of digital images.
[0079] Embodiment 3: This embodiment uses the two-dimensional Overthrust model widely used in seismic digital image processing to test the application effect of the present invention. Figure 3~Figure 6 In the figure, the horizontal axis is the width of the image and the vertical axis is the height of the image. Figure 3is the reflection coefficient image of the two-dimensional Overthrust model, Figure 4 This is the non-steady-state discrete filter function field obtained for the two-dimensional Overthrust model. It can be seen that due to the complexity of the model, the shape and energy intensity of the obtained filter function change dramatically with the spatial position. Figure 5 To use traditional algorithms Figure 3 right Figure 4 After the image is processed by non-steady-state filtering, it can be seen that due to the influence of the filtering function, the reflectance image has an obvious blurring effect, and the resolution and energy intensity have changed significantly. Figure 6 The non-steady-state filtered image obtained by the non-steady-state image filtering method based on fast Fourier transform of embodiment 1 can be seen that its morphological features are exactly the same as the results of the traditional algorithm, and can well simulate the blurring effect of the filter function field on the reflection coefficient image. However, there is a significant difference in the calculation time of the two algorithms. The calculation time of the traditional algorithm is 5.3s, while the calculation time of embodiment 1 is 0.9s, which is only 1 / 5 of the traditional algorithm. Therefore, the present invention can significantly improve the calculation efficiency of non-steady-state image filtering processing.
[0080] The optional implementation modes of the embodiments of the present invention are described in detail above in conjunction with the accompanying drawings. However, the embodiments of the present invention are not limited to the specific details in the above implementation modes. Within the technical concept of the embodiments of the present invention, various simple modifications can be made to the technical scheme of the embodiments of the present invention, and these simple modifications all belong to the protection scope of the embodiments of the present invention.
[0081] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. To avoid unnecessary repetition, the embodiments of the present invention will not further describe various possible combinations.
[0082] Those skilled in the art can understand that all or part of the steps in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a program, and the program is stored in a storage medium, including a number of instructions to enable a single-chip microcomputer, a chip or a processor to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.
[0083] In addition, various implementations of the embodiments of the present invention may be arbitrarily combined, and as long as they do not violate the concept of the embodiments of the present invention, they should also be regarded as the contents disclosed in the embodiments of the present invention.
Claims
1. A non-stationary image filtering method based on fast Fourier transform, characterized in that: The method comprises: Based on the interpolation algorithm, a plurality of local images to which a discrete filter function acts are selected, wherein the discrete filter function is a single-point filter function; Based on the FFT algorithm, the selected multiple local images are subjected to fast convolution filtering with discrete filter functions to obtain multiple local filtered images; Based on the interpolation weight coefficient of the interpolation algorithm, each local filter image is weighted to obtain a plurality of interpolation coefficient weighted local filter images; Accumulating a plurality of interpolation coefficient weighted local filtering images to obtain a non-steady-state filtering image; Among them, based on the FFT algorithm, the selected multiple local images are respectively subjected to fast convolution filtering processing with discrete filter functions to obtain multiple local filtered images, including: In the wave number domain, each single point filter function and the corresponding local image are forward transformed based on the FFT algorithm to obtain multiple spatial convolutions. Based on the FFT algorithm, multiple spatial convolutions are inversely transformed to obtain multiple local filtered images; Wherein, the function expression of the local filtering image is: M y (x)=FFT -1 (FFT(P)×FFT(R y )); Where M y (x) is the local filtered image, FFT() is the Fourier transform, FFT -1 () is the inverse Fourier transform, P is the single-point filter function , R y is the local digital image within the range of the single-point filter function , Represents the spatial range of a single-point filter function.
2. The non-steady-state image filtering method based on fast Fourier transform according to claim 1, characterized in that: Based on the interpolation algorithm, multiple local images are selected for the discrete filter function to act on, including: Select any single-point filter function from the discrete filter functions; Based on the interpolation algorithm, the local digital image within the action range of the single-point filter function is determined, and the local digital image within the action range of the single-point filter function is used as a local image. The local digital images within the action range of multiple single-point filter functions constitute multiple local images.
3. The non-steady-state image filtering method based on fast Fourier transform according to claim 2, characterized in that: The function expression of the local image is: ; In the formula, is the local digital image within the scope of the single-point filter function, y represents the center point of the filter function, and x represents the local digital image range within the scope of the single-point filter function. is the image extraction function, and M(x) is the overall digital image to be filtered.
4. The non-steady-state image filtering method based on fast Fourier transform according to claim 1, characterized in that: The function expression of the interpolation coefficient weighted local filtering image is: ; In the formula, is the interpolation coefficient weighted local filtered image, is the interpolation weight coefficient of the interpolation algorithm, M y (x) is the local filtered image.
5. The non-steady-state image filtering method based on fast Fourier transform according to claim 4, characterized in that: The functional expression of the non-stationary filtered image is: ; In the formula, is a non-stationary filtered image, is the interpolation coefficient weighted local filtered image.
6. A non-steady-state image filtering device based on fast Fourier transform, used to implement the non-steady-state image filtering method based on fast Fourier transform according to any one of claims 1 to 5, characterized in that: The device comprises: An image extraction module, used for selecting a plurality of local images to which a discrete filter function is applied based on an interpolation algorithm; An image filtering module is used to perform fast convolution filtering processing on multiple selected local images and discrete filter functions based on an FFT algorithm to obtain multiple local filtered images; An image weighting module is used to perform weighted processing on each local filter image based on the interpolation weight coefficient of the interpolation algorithm to obtain a plurality of interpolation coefficient weighted local filter images; The image summation module is used to accumulate multiple interpolation coefficient weighted local filtering images to obtain a non-steady-state filtering image.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the non-steady-state image filtering method based on fast Fourier transform described in any one of claims 1 to 5 is implemented.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the non-steady-state image filtering method based on fast Fourier transform described in any one of claims 1 to 5 is implemented.
Citation Information
Patent Citations
Non-subsampled Shearlet speckle reduction method based on improved non-local mean
CN108447039A
Image compressed sensing method and system based on fast Fourier convolution and convolution filtering flow
CN115100301A