Image processing method, device, electronic device and storage medium

Through frequency domain transformation and fusion weight adjustment technology, it solves the problem of poor noise elimination effect of traditional image denoising technology in moving areas, achieves the balance of image details and denoising effect and the uniformity of noise distribution, and improves the denoising effect. and avoid motion blur.

CN113781357BActive Publication Date: 2024-10-29GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111120118.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-09-24
Publication Date
2024-10-29
Estimated Expiration
2041-09-24

AI Technical Summary

Technical Problem

Traditional image denoising technology is not effective in removing noise in moving areas, resulting in significant differences in noise between moving areas and static areas, and uneven denoising effects.

Method used

By acquiring multiple images to be processed, the reference image and non-reference image are determined, divided into multiple image blocks, and subjected to frequency domain transformation processing. The correction parameters are determined according to the frequency band of each reference frequency domain pixel, and the fusion weight is adjusted. Realize the adjustment of denoising intensity in different frequency bands and fusion processing to obtain denoised images.

Benefits of technology

It achieves a balance between image details and denoising effect, eliminates differences in noise distribution, improves denoising effect, avoids motion blur, and has excellent noise reduction capabilities especially in moving areas.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113781357B_ABST
    Figure CN113781357B_ABST
Patent Text Reader

Abstract

The present application relates to an image processing method, device, electronic device and computer-readable storage medium, the image processing method comprising: after dividing a reference image and a non-reference image into more than one image block respectively, performing frequency domain transformation processing on each reference image block in the reference image to obtain each reference frequency domain image block, and performing frequency domain transformation processing on the non-reference image blocks matching each reference image block in the non-reference image to obtain each non-reference frequency domain image block; according to the frequency bands corresponding to each reference frequency domain pixel point in each reference frequency domain image block, determining the correction parameters corresponding to each reference frequency domain pixel point respectively, and using each correction parameter to adjust the fusion weight between each reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point; performing fusion processing according to the adjusted fusion weight to obtain a denoised image corresponding to each image to be processed. This method can improve the image denoising effect.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to image processing technology, and in particular to an image processing method, device, electronic device and computer-readable storage medium. Background Art

[0002] With the development of electronic equipment technology, people have higher and higher requirements for image clarity. Image denoising technology has become a key research direction in the field of computer vision, and various image denoising technologies have emerged, such as spatial domain fusion denoising and transform domain fusion denoising.

[0003] However, the traditional image denoising technology has the problem of uneven denoising effect. For example, when there is a moving object in the shooting scene, the noise intensity in the moving area of ​​the shot image will jump abruptly, and the traditional image denoising technology cannot eliminate most of the noise in the moving area, resulting in a significant difference in noise between the moving area and the static area, and poor denoising effect. Summary of the invention

[0004] The embodiments of the present application provide an image processing method, device, electronic device and computer-readable storage medium, which can improve the image denoising effect.

[0005] An image processing method, comprising:

[0006] Acquire more than one image to be processed, and determine a reference image and a non-reference image other than the reference image from each of the images to be processed;

[0007] After dividing the reference image and the non-reference image into more than one image block respectively, performing frequency domain transformation processing on each reference image block in the reference image to obtain each reference frequency domain image block composed of reference frequency domain pixels, and performing frequency domain transformation processing on non-reference image blocks in the non-reference image that match each reference image block to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels;

[0008] Determine the correction parameters corresponding to each reference frequency domain pixel point according to the frequency bands corresponding to each reference frequency domain pixel point in each reference frequency domain image block;

[0009] Using the correction parameters corresponding to each reference frequency domain pixel point, respectively, the fusion weight between each reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is adjusted; the non-reference frequency domain pixel point corresponding to the reference frequency domain pixel point is a non-reference frequency domain pixel point in the non-reference frequency domain image block that matches the reference frequency domain image block where the reference frequency domain pixel point is located;

[0010] According to the adjusted fusion weight, each reference frequency domain pixel point is fused with the corresponding non-reference frequency domain pixel point to obtain a denoised image corresponding to each image to be processed.

[0011] An image processing device, comprising:

[0012] An image acquisition module, used for acquiring more than one image to be processed, and determining a reference image and a non-reference image other than the reference image from each image to be processed;

[0013] A frequency domain transformation processing module is used to perform frequency domain transformation processing on each reference image block in the reference image after dividing the reference image and the non-reference image into more than one image block respectively, so as to obtain each reference frequency domain image block composed of reference frequency domain pixels, and perform frequency domain transformation processing on non-reference image blocks in the non-reference image that match each reference image block, so as to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels;

[0014] A correction parameter determination module, used to determine the correction parameters corresponding to each reference frequency domain pixel point in each reference frequency domain image block according to the frequency band corresponding to each reference frequency domain pixel point in each reference frequency domain image block;

[0015] A fusion weight adjustment module is used to adjust the fusion weight between each reference frequency domain pixel and the corresponding non-reference frequency domain pixel using the correction parameters corresponding to each reference frequency domain pixel; the non-reference frequency domain pixel corresponding to the reference frequency domain pixel is a non-reference frequency domain pixel in a non-reference frequency domain image block that matches the reference frequency domain image block where the reference frequency domain pixel is located;

[0016] The fusion denoising module is used to fuse each reference frequency domain pixel point with the corresponding non-reference frequency domain pixel point according to the adjusted fusion weight to obtain a denoised image corresponding to each image to be processed.

[0017] An electronic device includes a memory and a processor. The memory stores a computer program. When the computer program is executed by the processor, the processor executes the steps of the above-mentioned image processing method.

[0018] A computer-readable storage medium stores a computer program, which implements the steps of the above-mentioned image processing method when executed by a processor.

[0019] The image processing method, device, electronic device and computer-readable storage medium divide the reference image and the non-reference image into more than one image block respectively, perform frequency domain transformation processing on each reference image block in the reference image to obtain each reference frequency domain image block composed of reference frequency domain pixels, perform frequency domain transformation processing on non-reference image blocks in the non-reference image that match each reference image block to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels, determine the correction parameters corresponding to each reference frequency domain pixel respectively according to the frequency bands corresponding to each reference frequency domain pixel in each reference frequency domain image block, and use each reference frequency domain pixel to obtain the correction parameters corresponding to each reference frequency domain pixel respectively. The correction parameters corresponding to the points are respectively used to adjust the fusion weights between each reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point, and each reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point are fused according to the adjusted fusion weights to obtain a denoised image corresponding to each image to be processed. In this way, due to the differences in image contents corresponding to different frequency bands, the reference frequency domain pixels of different frequency bands are treated with denoising strengths suitable for the frequency bands. On the one hand, a balance between image details and denoising effects can be achieved, and on the other hand, differences in noise distribution can be eliminated, thereby improving the denoising effect, and for moving areas, motion blur can be avoided. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0021] Figure 1 is a schematic flow chart of an image processing method in one embodiment;

[0022] Figure 2 A schematic diagram of determining a non-reference image block that matches a reference image block in one embodiment;

[0023] Figure 3 A schematic diagram of determining a non-reference image block that matches a reference image block in another embodiment;

[0024] Figure 4 is a schematic diagram of frequency band distribution of a frequency domain image block in one embodiment;

[0025] Figure 5 A schematic diagram of fusion processing in one embodiment;

[0026] Figure 6 is a schematic flow chart of an image processing method in one embodiment;

[0027] Figure 7 is a schematic flow chart of an image processing method in another embodiment;

[0028] Figure 8 is a schematic flow chart of an image processing method in another embodiment;

[0029] Fig. 9 is a schematic flow chart of an image processing method in another embodiment;

[0030] Fig.10 is a schematic flow chart of an image processing method in another embodiment;

[0031] Fig.11 A schematic diagram of a denoising effect in an embodiment;

[0032] Fig.12 is a structural block diagram of an image processing device in one embodiment;

[0033] Fig.13 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0034] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0035] In one embodiment, Figure 1 As shown, an image processing method is provided. This embodiment takes the method applied to a terminal as an example for illustration. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:

[0036] Step 102 : acquiring more than one image to be processed, and determining a reference image and non-reference images other than the reference image from each of the images to be processed.

[0037] Among them, the image to be processed is an image processed by the method provided in the embodiment of the present application, specifically, more than one image to be processed is subjected to fusion denoising processing to obtain a denoised image corresponding to more than one image to be processed.

[0038] In one possible implementation, the terminal shoots a target object in a real scene to obtain more than one image to be processed, and obtains the output image of this shooting by fusing and denoising the more than one image to be processed. Specifically, the terminal continuously transmits more than one light spot signal to the target object, receives more than one light spot signal reflected by the target object, and generates more than one sensor imaging according to the more than one light spot signal reflected by the target object. The terminal can use the sensor imaging as the image to be processed, or use the image generated by any image processing node between the sensor imaging and the final output image as the image to be processed. The number of target objects can be at least one, and the target object can be a static object or a moving object. In other embodiments, the terminal reads more than one image to be processed from the local storage, or continuously extracts more than one video frame from the video as the image to be processed, and so on.

[0039] In a possible implementation, the terminal determines a reference image from more than one image to be processed, and uses images other than the reference image in the more than one image to be processed as non-reference images. The number of reference images may be one, and the number of non-reference images may be one or at least two.

[0040] In one possible implementation, the terminal may also select reference images according to the clarity of the subject. For example, the terminal identifies the clarity of the subject in each image to be processed, and uses the image to be processed corresponding to the highest clarity as the reference image. In other embodiments, the terminal may also select reference images from dimensions such as image brightness and sharpness. For example, the terminal calculates the brightness matching degree between each image to be processed and other images, and uses the image to be processed corresponding to the maximum brightness matching degree as the reference image. When there are at least two images to be processed corresponding to the maximum brightness matching degree, the image to be processed with the highest sharpness among the at least two images to be processed corresponding to the maximum brightness matching degree is used as the reference image.

[0041] In one possible implementation, the terminal performs image alignment processing on the reference image and the non-reference image based on the reference image, such as local alignment processing and / or global alignment processing. The image alignment processing is used to align more than one image according to the image content. The terminal can use a general image alignment strategy to perform image alignment processing on the reference image and the non-reference image.

[0042] Step 104, after dividing the reference image and the non-reference image into more than one image block respectively, frequency domain transform processing is performed on each reference image block in the reference image to obtain each reference frequency domain image block composed of reference frequency domain pixels, and frequency domain transform processing is performed on non-reference image blocks in the non-reference image that match each reference image block to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels.

[0043] Among them, an image block is a collection of more than one pixel point. Frequency domain transformation processing is to transform the image block from the time domain to the frequency domain. The frequency domain image block is the result of frequency domain transformation processing on the time domain image block. The frequency domain pixel point is the pixel point in the frequency domain image block.

[0044] In one possible implementation, the terminal divides the reference image and the non-reference image into more than one image block respectively. The number of pixels of the image block of the reference image and the image block of the non-reference image are consistent, for example, the number of pixels of the image block of the reference image and the image block of the non-reference image can both be 8*8 pixels.

[0045] In one possible implementation, the terminal performs frequency domain transformation processing on each reference image block in the reference image to obtain a reference frequency domain image block corresponding to each reference image block. The number of pixels of the reference image block and its corresponding reference frequency domain image block is consistent. For example, if the reference image block is 8*8 pixels, its corresponding reference frequency domain image block is also 8*8 reference frequency domain pixels.

[0046] In a possible implementation manner, the terminal determines, from the non-reference image, non-reference image blocks that match each reference image block.

[0047] In one possible implementation, for each reference image block in the reference image, the terminal determines a non-reference image block that matches the reference image block in position from the non-reference image as the non-reference image block that matches the reference image block. It can be understood that the terminal divides the reference image and the non-reference image into image blocks of the same number and the same number of pixels, and the image block positions of the reference image and the non-reference image correspond to each other. For example, referring to Figure 2 , Figure 2 A schematic diagram of determining a non-reference image block matching a reference image block from a non-reference image in one embodiment is shown. It can be seen that the terminal divides the reference image A1 and the non-reference images A2 and A3 into 4*4 image blocks, and for the image block 202 in the reference image A1, it corresponds to the image block 204 in the non-reference image A2, and it corresponds to the image block 206 in the non-reference image A3.

[0048] In one possible implementation, for each reference image block in the reference image, the terminal determines a non-reference image block that matches the reference image block in terms of image content from the non-reference image as the non-reference image block that matches the reference image block. The terminal may use a general image matching algorithm to determine a non-reference image block that matches the reference image block in terms of image content from the non-reference image. For example, referring to Figure 3 , Figure 3A schematic diagram of determining a non-reference image block that matches a reference image block from a non-reference image in another embodiment is shown. It can be seen that for image block 302 in reference image A1, it corresponds to image block 304 in non-reference image A2, and it corresponds to image block 306 in non-reference image A3, and the image contents of image block 302, image block 304, and image block 306 match.

[0049] In one possible implementation, the terminal performs frequency domain transformation processing on the non-reference image blocks that match each reference image block in the non-reference image to obtain a non-reference frequency domain image block corresponding to each non-reference image block. The number of pixels of the non-reference image block and its corresponding non-reference frequency domain image block is consistent, for example, if the non-reference image block is 8*8 pixels, its corresponding non-reference frequency domain image block is also 8*8 non-reference frequency domain pixels.

[0050] In a possible implementation, after the terminal divides the reference image and the non-reference image into more than one image block respectively, for one of the reference image blocks in the reference image, a non-reference image block matching the reference image block is determined from the non-reference image, and the reference image block and the matching non-reference image block are listed as a batch for subsequent fusion processing into a denoised image block. When the batch processing is completed one by one, a denoised image corresponding to the reference image and the non-reference image is obtained.

[0051] In a possible implementation, the terminal may use a general frequency domain transformation strategy to perform frequency domain transformation processing, such as discrete cosine transform (DCT), fast Fourier transform (FFT), wavelet transform (WT), etc.

[0052] Step 106 , determining correction parameters corresponding to each reference frequency domain pixel point respectively according to the frequency band respectively corresponding to each reference frequency domain pixel point in each reference frequency domain image block.

[0053] Among them, frequency band refers to the frequency range in the frequency domain. The correction parameter is used to correct the fusion weight between the reference frequency domain pixel points and the non-reference frequency domain pixel points. Since the fusion weight is proportional to the fusion strength, and the fusion strength affects the denoising strength, the correction parameter actually corrects the fusion strength between the reference frequency domain pixel points and the non-reference frequency domain pixel points, thereby affecting the denoising strength of different frequency bands.

[0054] In a possible implementation, the terminal performs frequency domain transformation processing on the time domain image block to obtain a frequency domain image block, and each frequency band in the frequency domain image block has a corresponding distribution area. Taking the frequency domain image block obtained by discrete cosine transform processing as an example, refer to Figure 4It can be seen that the lowest frequency is concentrated in the upper left corner of the frequency domain image block, and the highest frequency is concentrated in the lower right corner of the frequency domain image block. Therefore, the terminal can determine the frequency band corresponding to each reference frequency domain pixel point according to the position information of each reference frequency domain pixel point in the reference frequency domain image block.

[0055] In the present application, it is considered that there are differences in the image content corresponding to different frequency bands. For example, the image content of the low-frequency band is generally smooth color blocks, inconspicuous noise, etc., the image content of the mid-frequency band is generally transition lines, contours, relatively obvious noise, etc., and the image content of the high-frequency band is generally fine lines, textures, obvious noise, etc. If the same denoising intensity is used for all frequency bands, if the denoising intensity is too low, the noise in the high-frequency band may remain, and if the denoising intensity is too high, the image details may be lost. In addition, there may be slight differences in the image content between the image blocks used for fusion denoising, and when there are moving areas in the image blocks, too high a fusion intensity may cause motion blur. Therefore, in the present application, according to the frequency bands corresponding to each reference frequency domain pixel point, the correction parameters corresponding to each reference frequency domain pixel point are determined, so as to use the correction parameters corresponding to each reference frequency domain pixel point to affect the denoising intensity of different frequency bands.

[0056] In one possible implementation, the terminal may pre-divide multiple frequency bands, such as a predetermined lowest frequency band, a predetermined low frequency band, a predetermined medium-low frequency band, a predetermined medium-high frequency band, and a predetermined high frequency band, and set a correction parameter for each frequency band. Optionally, the terminal may also directly set a corresponding fusion weight for each frequency band. It is understood that the correction parameter or fusion weight corresponding to each frequency band can be debugged according to the actual application scenario, and this application does not make specific limitations.

[0057] In one possible implementation, for a predetermined high frequency band, the band only contains high frequency noise, and at least two pixels used for fusion denoising can be fully fused to improve the denoising strength. For a predetermined mid-high frequency band, the band contains not only mid-high frequency noise, but also some mid-high frequency details and motion areas, and the fusion strength can be moderately weakened to avoid loss of details and motion blur. For a predetermined mid-low frequency band, the band contains more mid-low frequency details and motion areas, and the fusion strength can be further weakened to avoid loss of details and motion blur. For a predetermined low frequency band, the band contains low frequency details, as well as low frequency brightness noise and color noise, and the fusion strength can be moderately enhanced to suppress noise. For a predetermined lowest frequency band, the band is the concentrated area of ​​most energy, with few details, and there is no need to worry about detail loss, and the fusion strength can be further enhanced.

[0058] Step 108, using the correction parameters corresponding to each reference frequency domain pixel point, respectively, to adjust the fusion weight between each reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point; the non-reference frequency domain pixel point corresponding to the reference frequency domain pixel point is a non-reference frequency domain pixel point in the non-reference frequency domain image block that matches the reference frequency domain image block where the reference frequency domain pixel point is located.

[0059] In one possible implementation, after the terminal divides the reference image and the non-reference image into more than one image block respectively, for one of the reference image blocks in the reference image, a non-reference image block matching the reference image block is determined from the non-reference image, and frequency domain transform processing is performed on the reference image block and the matching non-reference image block respectively to obtain a reference frequency domain image block corresponding to the reference image and a non-reference frequency domain image block corresponding to the non-reference image block, and there is also a matching relationship between the reference frequency domain image block and the non-reference frequency domain image block.

[0060] In one possible implementation, for each reference frequency domain pixel in the reference frequency domain image block, the terminal obtains position information of the reference frequency domain pixel in the reference frequency domain image block, and determines, according to the position information, a non-reference frequency domain pixel corresponding to the reference frequency domain pixel from a non-reference frequency domain image block that matches the reference frequency domain image block.

[0061] The position information may be the relative position of the reference frequency domain pixel in the reference frequency domain image block, such as the relative coordinates of the reference frequency domain pixel in the reference frequency domain image block.

[0062] In a possible implementation, each reference frequency domain pixel in the reference frequency domain image block has a corresponding relationship with a non-reference frequency domain pixel in the non-reference frequency domain image block that matches the reference frequency domain image block. Figure 5 , Figure 5 A schematic diagram of fusing a reference frequency domain image block with a matching non-reference frequency domain image block in one embodiment is shown. It can be seen that the reference frequency domain image block a1 is 8*8 reference frequency domain pixels, and the non-reference frequency domain image blocks a2 and a3 are also 8*8 non-reference frequency domain pixels. For the reference frequency domain pixel 502 in the reference frequency domain image block a1, it corresponds to the non-reference frequency domain pixel 504 in the non-reference frequency domain image block a2, and it corresponds to the non-reference frequency domain pixel 506 in the non-reference frequency domain image block a3.

[0063] In one possible implementation, for each reference frequency domain pixel in the reference frequency domain image block, the terminal determines a corresponding non-reference frequency domain pixel in a non-reference frequency domain image block that matches the reference frequency domain image block in position, and fuses the reference frequency domain pixel with the corresponding non-reference frequency domain pixel to obtain a fused frequency domain pixel. Figure 5It can be seen that for one of the reference frequency domain pixels 502 in the reference frequency domain image block a1, the terminal fuses the reference frequency domain pixel 502 with the corresponding non-reference frequency domain pixel 504 in the non-reference frequency domain image block a2 and the corresponding non-reference frequency domain pixel 506 in the non-reference frequency domain image block a3 to obtain a fused frequency domain pixel 508; the terminal fuses each reference frequency domain pixel in the reference frequency domain image block a1 one by one to obtain a fused frequency domain image block a* corresponding to the reference frequency domain image block a1.

[0064] In one possible implementation, for each reference frequency domain pixel point, the terminal determines the frequency domain data difference between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point, and calculates the fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point based on the frequency domain data difference.

[0065] The frequency domain data corresponding to the frequency domain pixel point is a parameter value in the frequency domain, such as frequency, spectrum value, amplitude spectrum value, etc.

[0066] Specifically, the terminal determines the frequency domain data difference between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point, and the frequency domain data difference reflects the similarity between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point. The larger the frequency domain data difference, the smaller the similarity; the fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is calculated based on the frequency domain data difference, and the frequency domain data difference is inversely proportional to the fusion weight, that is, the smaller the similarity, the smaller the fusion weight. Optionally, the terminal calculates the absolute value of the frequency domain data difference between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point as the frequency domain data difference.

[0067] In a possible implementation, the fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point can be expressed by the following formula:

[0068]

[0069] Among them, ω i represents the fusion weight between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the reference frequency domain image block; diff i represents the frequency domain data difference between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the reference frequency domain image block; β represents a constant.

[0070] In one embodiment, the terminal uses the correction parameter corresponding to the reference frequency domain pixel point to adjust the fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point, which can be expressed by the following formula:

[0071]

[0072] Among them, ω i represents the adjusted fusion weight between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the reference frequency domain image block; diff i represents the frequency domain data difference between the i-th reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point in the reference frequency domain image block; β represents a constant; Represents the correction parameter corresponding to the i-th reference frequency domain pixel in the reference frequency domain image block.

[0073] In one possible implementation, referring to the above analysis, for a predetermined high frequency band, at least two pixels used for fusion denoising can be completely fused, the fusion weight can be 1, and the correction parameter does not interfere with the fusion weight. For a predetermined medium and high frequency band, the fusion strength can be moderately weakened, and the correction parameter can be 0.8 to 0.95; for a predetermined medium and low frequency band, the fusion strength can be further weakened, and the correction parameter can be 0.5 to 0.6; for a predetermined low frequency band, the fusion strength can be moderately enhanced, and the correction parameter can be 1.5 to 1.6; for a predetermined lowest frequency band, the fusion strength can be further enhanced, and the correction parameter can be 1.8 to 2.

[0074] Step 110 , fusing each reference frequency domain pixel with the corresponding non-reference frequency domain pixel according to the adjusted fusion weight, to obtain a denoised image corresponding to each image to be processed.

[0075] In one embodiment, the terminal fuses each reference frequency domain pixel point with the corresponding non-reference frequency domain pixel point according to the adjusted fusion weight to obtain a fused frequency domain image block corresponding to each reference frequency domain image block; performs frequency domain inverse transform processing on each fused frequency domain image block to obtain a denoised image block corresponding to each reference frequency domain image block; and splices each denoised image block to obtain a denoised image corresponding to each image to be processed.

[0076] In one embodiment, the terminal fuses the reference frequency domain pixel points with the corresponding non-reference frequency domain pixel points according to the adjusted fusion weights to obtain a fused frequency domain image block corresponding to the reference frequency domain image block, which can be expressed by the following formula:

[0077]

[0078] Among them, δ represents the frequency domain data of the fused frequency domain image block; δ0 represents the frequency domain data of the reference frequency domain pixel point, δ1~δ j Represents the frequency domain data of the 1st to jth non-reference frequency domain pixel points; ω1~ω j Represents the adjusted fusion weights between the reference frequency domain pixel and the 1st to jth non-reference frequency domain pixels.

[0079] Reference Figure 6 , Figure 6 A flow chart of an image processing method in an embodiment is shown. It can be seen that the terminal divides the reference image A1, the non-reference image A2, and the non-reference image A3 into more than one image block respectively. For one of the reference image blocks A11 in the reference image A1, a non-reference image block A21 matching the reference image block A11 is determined from the non-reference image A2, and a non-reference image block A31 matching the reference image block A11 is determined from the non-reference image A3, and the reference image block A11, the non-reference image block A21, and the non-reference image block A31 are listed as a batch for processing. The reference image block A11, the non-reference image block A21, and the non-reference image block A31 are respectively subjected to frequency domain transformation processing to obtain a reference frequency domain image block a1 corresponding to the reference image block A11, a non-reference frequency domain image block a2 corresponding to the non-reference image block A21, and a non-reference frequency domain image block a3 corresponding to the non-reference image block A31. According to the correction parameters corresponding to each reference frequency domain pixel in the reference frequency domain image block a1, the fusion weights between each reference frequency domain pixel and the corresponding non-reference frequency domain pixel are adjusted. According to the adjusted fusion weights, each reference frequency domain pixel in the reference frequency domain image block a1 is fused with the corresponding non-reference frequency domain pixel in the non-reference frequency domain image block a2 and the corresponding non-reference frequency domain pixel in the non-reference frequency domain image block a3 to obtain a fused frequency domain image block a*. The fused frequency domain image block a* is subjected to frequency domain inverse transform processing to obtain a denoised image block a corresponding to the fused frequency domain image block a*. When the batch processing is completed, a denoised image A corresponding to the reference image A1, the non-reference image A2 and the non-reference image A3 is obtained.

[0080] The image processing method of the present embodiment divides the reference image and the non-reference image into more than one image block respectively, performs frequency domain transformation processing on each reference image block in the reference image to obtain each reference frequency domain image block composed of reference frequency domain pixels, performs frequency domain transformation processing on non-reference image blocks matching each reference image block in the non-reference image to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels, determines the correction parameters corresponding to each reference frequency domain pixel point respectively according to the frequency bands corresponding to each reference frequency domain pixel point in each reference frequency domain image block, and uses the correction parameters corresponding to each reference frequency domain pixel point respectively. Positive parameters adjust the fusion weights between each reference frequency domain pixel and the corresponding non-reference frequency domain pixel. According to the adjusted fusion weights, each reference frequency domain pixel and the corresponding non-reference frequency domain pixel are fused to obtain a denoised image corresponding to each image to be processed. In this way, due to the differences in image content corresponding to different frequency bands, the reference frequency domain pixels of different frequency bands are treated with denoising strengths suitable for the frequency bands. On the one hand, a balance between image details and denoising effects can be achieved. On the other hand, differences in noise distribution can be eliminated, thereby improving the denoising effect. In addition, motion blur can be avoided in moving areas.

[0081] In one embodiment, the method further includes: for each reference frequency domain pixel point, obtaining position information of the reference frequency domain pixel point in a target reference frequency domain image block, the target reference frequency domain image block being the reference frequency domain image block where the reference frequency domain pixel point is located; and determining a frequency band corresponding to the reference frequency domain pixel point according to the position information.

[0082] The position information may be the relative position of the reference frequency domain pixel in the reference frequency domain image block, such as the relative coordinates of the reference frequency domain pixel in the reference frequency domain image block.

[0083] In one embodiment, the position information of the reference frequency domain pixel point in the reference frequency domain image block can be expressed by the following formula:

[0084] x i =i * %n

[0085] y i =i * / n

[0086] Among them, x i represents the horizontal coordinate of the i-th reference frequency domain pixel in the reference frequency domain image block; i represents the ordinate of the i-th reference frequency domain pixel in the reference frequency domain image block; i *represents the serial number corresponding to the i-th reference frequency domain pixel in the reference frequency domain image block; n represents half of the number of reference frequency domain pixels in the reference frequency domain image block. For example, if the reference frequency domain image block is 8*8 reference frequency domain pixels, then n can be 8; i * %n means i * remainder when divided by n; i * / n means i * The quotient when divided by n.

[0087] In one embodiment, each frequency band in the frequency domain image block has a corresponding distribution area, so the terminal can determine the frequency band corresponding to each reference frequency domain pixel point according to the position information of each reference frequency domain pixel point in the reference frequency domain image block.

[0088] In one embodiment, the position information is a relative coordinate; determining the frequency band corresponding to the reference frequency domain pixel point according to the position information includes: obtaining the horizontal coordinate value and the vertical coordinate value in the relative coordinates of the reference frequency domain pixel point; and determining the frequency band corresponding to the reference frequency domain pixel point based on the sum of the horizontal coordinate value and the vertical coordinate value.

[0089] In one embodiment, taking the reference frequency domain image block as 8*8 reference frequency domain pixels as an example, the terminal can determine the frequency band corresponding to the reference frequency domain pixels by the following formula: i +y i <3, it is determined to be the predetermined lowest frequency band; if x i +y i <5, it is determined to be a predetermined low frequency band; if x i +y i <9, it is determined to be the predetermined low-mid frequency band; if x i +y i <11, it is determined to be the predetermined medium and high frequency band; if x i +y i ≥11, it is determined to be a predetermined high frequency band.

[0090] In this embodiment, the frequency bands corresponding to each reference frequency domain pixel point are determined according to the position information of each reference frequency domain pixel point in the reference frequency domain image block. This not only can accurately identify the frequency bands corresponding to each reference frequency domain pixel point, but also can reduce the amount of calculation and improve the denoising speed in actual application scenarios.

[0091] In one embodiment, the method further includes: for each reference frequency domain pixel point, obtaining the noise parameter corresponding to the target reference frequency domain image block where the reference frequency domain pixel point is located; determining the frequency domain data difference between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point; and calculating the fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point based on the frequency domain data difference and the noise parameter.

[0092] The noise parameter is used to describe the amount of noise in the reference image block and its adjacent image regions. Optionally, the noise parameter is proportional to the amount of noise.

[0093] In one embodiment, the terminal calculates a root mean square (RMS) value for a reference image block, and pre-sets a mapping relationship between the root mean square value and a noise parameter, and determines the noise parameter of the reference image block based on the calculated root mean square value and the mapping relationship as the noise parameter corresponding to the reference frequency domain image block obtained by transforming the reference image block.

[0094] In one embodiment, the fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point can be expressed by the following formula:

[0095]

[0096] Among them, ω i represents the fusion weight between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the reference frequency domain image block; diff i It represents the frequency domain data difference between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the reference frequency domain image block; Noiselevel represents the noise parameter corresponding to the reference frequency domain image block.

[0097] In one embodiment, the terminal calculates the product between the correction parameter corresponding to the reference frequency domain pixel point and the noise parameter; after calculating the sum of the product and the frequency domain data difference, calculates the quotient between the frequency domain data difference and the sum; calculates the difference between the predetermined value and the quotient to obtain the adjusted fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point.

[0098] In one embodiment, the terminal uses the correction parameter corresponding to the reference frequency domain pixel point to adjust the fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point, which can be expressed by the following formula:

[0099]

[0100] Among them, ω i represents the adjusted fusion weight between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the reference frequency domain image block; diff i represents the frequency domain data difference between the i-th reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point in the reference frequency domain image block; It represents the correction parameter corresponding to the i-th reference frequency domain pixel in the reference frequency domain image block; Noiselevel represents the noise parameter corresponding to the reference frequency domain image block.

[0101] In one embodiment, for each reference frequency domain pixel point, it is determined whether the frequency band corresponding to the reference frequency domain pixel point is a predetermined adjustment frequency band; when the frequency band corresponding to the reference frequency domain pixel point is a predetermined adjustment frequency band, the step of calculating the product between the correction parameter corresponding to the reference frequency domain pixel point and the noise parameter is executed.

[0102] In one embodiment, the predetermined adjustment frequency band may be other frequency bands in the predetermined frequency band except the predetermined high frequency band, such as a predetermined medium-high frequency band, a predetermined medium-low frequency band, a predetermined low frequency band, a predetermined lowest frequency band, etc.

[0103] In one embodiment, for a predetermined high frequency band, at least two pixel points used for fusion denoising may all be fused, the fusion weight may take a value of 1, and the correction parameter does not interfere with the fusion weight.

[0104] In one embodiment, for each reference frequency domain pixel point, it is determined whether the frequency band corresponding to the reference frequency domain pixel point is a predetermined high frequency band; when the frequency band corresponding to the reference frequency domain pixel point is the predetermined high frequency band, the correction parameter corresponding to the reference frequency domain pixel point is zero, and the adjusted fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is a preset value, so that the fusion processing strategy between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is full fusion.

[0105] The preset value may be 1, so that the reference frequency domain pixel points and the corresponding non-reference frequency domain pixel points are all fused during the fusion process.

[0106] In one embodiment, for other frequency bands in the predetermined frequency band except the predetermined high frequency band, such as the predetermined medium-high frequency band, the predetermined medium-low frequency band, the predetermined low frequency band, the predetermined lowest frequency band, etc., the above method can be used to correct the fusion weight, so that the reference frequency domain pixels of different frequency bands and the corresponding non-reference frequency domain pixels are fused according to different fusion strengths. In one embodiment, the adjusted fusion weight between the reference frequency domain pixel and the corresponding non-reference frequency domain pixel is calculated by the following formula:

[0107]

[0108] Among them, ω i represents the adjusted fusion weight between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the target reference frequency domain image block; diff i represents the frequency domain data difference between the i-th reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point in the target reference frequency domain image block; represents the correction parameter corresponding to the i-th reference frequency domain pixel in the target reference frequency domain image block. When the frequency band corresponding to the i-th reference frequency domain pixel in the target reference frequency domain image block is a predetermined high frequency band, When the frequency band corresponding to the i-th reference frequency domain pixel point in the target reference frequency domain image block is a frequency band other than the predetermined high frequency band in the predetermined frequency band, Noiselevel represents the noise parameter corresponding to the target reference frequency domain image block.

[0109] In this embodiment, the fusion weight between the reference frequency domain pixel and the corresponding non-reference frequency domain pixel is calculated based on the frequency domain data difference between the reference frequency domain pixel and the corresponding non-reference frequency domain pixel, and the noise parameter corresponding to the reference frequency domain image block where the reference frequency domain pixel is located. This can improve the accuracy of the evaluation of the fusion strength between the reference frequency domain pixel and the corresponding non-reference frequency domain pixel. The correction parameter corresponding to the reference frequency domain pixel is used to adjust the fusion weight between the reference frequency domain pixel and the corresponding non-reference frequency domain pixel, so that the adjusted fusion strength is also accurate.

[0110] In one embodiment, the method further includes: for each reference frequency domain image block, determining the proportion of each frequency band in the reference frequency domain image block according to the frequency bands corresponding to each reference frequency domain pixel point in the reference frequency domain image block, and determining the correction parameter corresponding to the reference frequency domain image block according to the frequency band corresponding to the maximum proportion; using the correction parameters corresponding to each reference frequency domain image block, adjusting the fusion weight between each reference frequency domain image block and the matching non-reference frequency domain image block; and fusing each reference frequency domain image block with the matching non-reference frequency domain image block according to the adjusted fusion weight to obtain a denoised image corresponding to each image to be processed.

[0111] In one embodiment, the terminal determines the frequency band with the largest number of reference frequency domain pixels in the reference frequency domain image block according to the frequency bands corresponding to the reference frequency domain pixels in the reference frequency domain image block, and determines the correction parameter corresponding to the reference frequency domain image block according to the frequency band.

[0112] In one embodiment, when there are at least two frequency bands corresponding to the maximum proportion in the reference frequency domain image block, the terminal can select one of the frequency bands according to a predetermined frequency band selection strategy, and determine the correction parameters corresponding to the reference frequency domain image block based on the frequency band. The predetermined frequency band selection strategy may include selecting a higher frequency band.

[0113] In one embodiment, the terminal determines the frequency domain data difference between each reference frequency domain pixel point in the reference frequency domain image block and the corresponding non-reference frequency domain pixel point in the matching non-reference frequency domain image block, and takes the sum of the frequency domain data differences corresponding to each reference frequency domain pixel point as the frequency domain data difference between the reference frequency domain image block and the matching non-reference frequency domain image block.

[0114] In one embodiment, the terminal uses the correction parameter corresponding to the reference frequency domain image block to adjust the fusion weight between the reference frequency domain image block and the matching non-reference frequency domain image block, which can be expressed by the following formula:

[0115]

[0116] Among them, ω k represents the adjusted fusion weight between the kth reference frequency domain image block and the matching non-reference frequency domain image block in the reference frequency domain image; diff k represents the frequency domain data difference between the kth reference frequency domain image block and the matching non-reference frequency domain image block in the reference frequency domain image; represents the correction parameter corresponding to the kth reference frequency domain image block in the reference frequency domain image; β represents a constant, which can also be the noise parameter corresponding to the kth reference frequency domain image block in the reference frequency domain image.

[0117] In one embodiment, the terminal fuses each reference frequency domain image block with the matching non-reference frequency domain image block according to the adjusted fusion weight to obtain each fused frequency domain image block; performs frequency domain inverse transform processing on each fused frequency domain image block to obtain each denoised image block; and splices each denoised image block to obtain a denoised image corresponding to each image to be processed.

[0118] In one embodiment, the terminal performs fusion processing on the reference frequency domain image block and the matching non-reference frequency domain image block according to the adjusted fusion weight to obtain a fused frequency domain image block, which can be expressed by the following formula:

[0119]

[0120] Wherein, ρ represents the frequency domain data of the fused frequency domain image block, which can be a matrix composed of the frequency domain data of each fused frequency domain pixel point; ρ0 represents the frequency domain data of the reference frequency domain image block, which can be a matrix composed of the frequency domain data of each reference frequency domain pixel point; ρ1~ρ s represents the frequency domain data of the 1st to sth non-reference frequency domain image blocks, which may be a matrix composed of the frequency domain data of each non-reference frequency domain pixel point; ω1~ω s represents the adjusted fusion weights between the reference frequency domain image block and the 1st to sth non-reference frequency domain image blocks.

[0121] In one embodiment, the image to be processed is an image in YUV format, which is a coding format that separates brightness and chrominance.

[0122] The present application can be applied to the YUV domain. Compared with the Bayer raw domain, on the one hand, YUV separates brightness and chromaticity, and can independently adjust the HDR (High-Dynamic Range) fusion strength of the two, and has a more flexible suppression and adjustment capability for brightness noise and color noise; on the other hand, the YUV domain can avoid the impact on color modules (such as 3DLUT, etc.), such as 3D LUT (3D lookup table), etc., because the YUV domain is later in the imaging process than the RAW domain, and the adjustment of the fusion module will not involve the debugging of the previous module.

[0123] In one embodiment, Figure 7 As shown, an image processing method is provided. This embodiment takes the method applied to a terminal as an example for illustration. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:

[0124] Step 702: Acquire more than one image to be processed, and determine a reference image and non-reference images other than the reference image from each image to be processed.

[0125] In one embodiment, the terminal performs image alignment processing on the reference image and the non-reference image based on the reference image, such as local alignment processing and / or global alignment processing.

[0126] Step 704, after dividing the reference image and the non-reference image into more than one image block respectively, for one of the reference image blocks in the reference image, determine a non-reference image block that matches the reference image block in image content from the non-reference image, and list the reference image block and the matching non-reference image block into a batch.

[0127] Step 706, performing frequency domain transform processing on the reference image blocks in the current batch to obtain reference frequency domain image blocks composed of reference frequency domain pixels, and performing frequency domain transform processing on the non-reference image blocks in the current batch to obtain non-reference frequency domain image blocks composed of non-reference frequency domain pixels.

[0128] Step 708: For each reference frequency domain pixel in the reference frequency domain image block, obtain the position information of the reference frequency domain pixel in the reference frequency domain image block, and determine the frequency band corresponding to the reference frequency domain pixel according to the position information.

[0129] In one embodiment, the position information of the reference frequency domain pixel point in the reference frequency domain image block can be expressed by the following formula:

[0130] x i =i * %n

[0131] y i =i * / n

[0132] Among them, x i represents the horizontal coordinate of the i-th reference frequency domain pixel in the reference frequency domain image block; i represents the ordinate of the i-th reference frequency domain pixel in the reference frequency domain image block; i * represents the serial number corresponding to the i-th reference frequency domain pixel in the reference frequency domain image block; n represents half of the number of reference frequency domain pixels in the reference frequency domain image block. For example, if the reference frequency domain image block is 8*8 reference frequency domain pixels, then n can be 8; i * %n means i * remainder when divided by n; i * / n means i * The quotient when divided by n.

[0133] In one embodiment, taking the reference frequency domain image block as 8*8 reference frequency domain pixels as an example, the terminal can determine the frequency band corresponding to the reference frequency domain pixels by the following formula: i +y i <3, it is determined to be the predetermined lowest frequency band; if x i +y i <5, it is determined to be a predetermined low frequency band; if x i +y i <9, it is determined to be the predetermined low-mid frequency band; if x i +y i <11, it is determined to be the predetermined medium and high frequency band; if x i +y i ≥11, it is determined to be a predetermined high frequency band.

[0134] Step 710, according to the frequency band corresponding to each reference frequency domain pixel in the reference frequency domain image block, determine the correction parameters corresponding to each reference frequency domain pixel, and use the correction parameters corresponding to each reference frequency domain pixel to adjust the fusion weight between each reference frequency domain pixel and the corresponding non-reference frequency domain pixel; the non-reference frequency domain pixel corresponding to the reference frequency domain pixel is the non-reference frequency domain pixel in the non-reference frequency domain image block that matches the reference frequency domain image block where the reference frequency domain pixel is located.

[0135] In one embodiment, the adjusted fusion weight between the reference frequency domain pixel and the corresponding non-reference frequency domain pixel is calculated by the following formula:

[0136]

[0137] Among them, ω irepresents the adjusted fusion weight between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the target reference frequency domain image block; diff i represents the frequency domain data difference between the i-th reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point in the target reference frequency domain image block; represents the correction parameter corresponding to the i-th reference frequency domain pixel in the target reference frequency domain image block. When the frequency band corresponding to the i-th reference frequency domain pixel in the target reference frequency domain image block is a predetermined high frequency band, When the frequency band corresponding to the i-th reference frequency domain pixel point in the target reference frequency domain image block is a frequency band other than the predetermined high frequency band in the predetermined frequency band, Noiselevel represents the noise parameter corresponding to the target reference frequency domain image block.

[0138] Step 712, according to the adjusted fusion weight, each reference frequency domain pixel point is fused with the corresponding non-reference frequency domain pixel point to obtain a fused frequency domain image block corresponding to the reference frequency domain image block; the fused frequency domain image block is subjected to frequency domain inverse transform processing to obtain denoised image blocks corresponding to the reference frequency domain image blocks.

[0139] Step 714, when the processing of each batch is completed, the denoised image blocks corresponding to each batch are spliced ​​to obtain the denoised image corresponding to each image to be processed.

[0140] Reference Figure 8 , Figure 8 A schematic diagram of an image processing method in an embodiment is shown. It can be seen that the terminal divides the reference image and the non-reference image into more than one image block respectively, and for each reference image block in the reference image, determines a non-reference image block that matches the reference image block in image content from the non-reference image, and lists the reference image block and the matching non-reference image block into a batch for fusion processing. Fig. 9 , Fig. 9 A flow chart of an image processing method in one embodiment is shown. It can be seen that when the batch processing is completed, the denoised image blocks obtained in each batch are spliced ​​to obtain a denoised image corresponding to each image to be processed. In this embodiment, processing images in batches can reduce the amount of calculation and speed up the processing.

[0141] Reference Fig.10 , Fig.10A flow chart of an image processing method in an embodiment is shown. It can be seen that the terminal obtains more than one image to be processed, determines a reference image and a non-reference image other than the reference image from each image to be processed, and divides the reference image and the non-reference image into more than one image block respectively. Then, frequency domain transform processing is performed on one of the reference image blocks in the reference image and its matching non-reference image block in the non-reference image to obtain a reference frequency domain image block corresponding to the reference image block and a non-reference frequency domain image block corresponding to the non-reference image block. According to the frequency band corresponding to each reference frequency domain pixel point in the reference frequency domain image block, the correction parameters corresponding to each reference frequency domain pixel point are determined, and the fusion weights between each reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point are adjusted using the correction parameters corresponding to each reference frequency domain pixel point. According to the adjusted fusion weights, each reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point are fused to obtain a fused frequency domain image block corresponding to the reference frequency domain image block. The fused frequency domain image block is subjected to frequency domain inverse transform processing to obtain denoised image blocks corresponding to the reference frequency domain image blocks.

[0142] Reference Fig.11 , Fig.11 A schematic diagram of the denoising effect is shown. Fig.11 The left picture shows the denoising effect of the general denoising method. Fig.11 The right figure shows the denoising effect of this embodiment. It can be seen that compared with the general denoising method, this embodiment can effectively suppress the noise in the moving area, and for the static area and the moving area, it can eliminate the difference in noise distribution and improve the consistency of noise reduction.

[0143] The image processing method in this embodiment uses a denoising intensity suitable for the reference frequency domain pixels of different frequency bands because the image contents corresponding to different frequency bands are different. This can achieve a balance between image details and denoising effects, eliminate noise distribution differences, and improve denoising effects. Furthermore, for moving areas, it can not only avoid motion blur, but also has excellent noise reduction capabilities for moving areas. Furthermore, by setting correction parameters, it can perform flexible denoising in response to the needs of actual application scenarios.

[0144] It should be understood that although Figure 1 , Figure 7 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 1 , Figure 7At least part of the steps may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least part of the sub-steps or stages of other steps.

[0145] Fig.12 FIG. 1 is a structural block diagram of an image processing device according to an embodiment. Fig.12 As shown, an image processing device is provided, which can be a part of a computer device using a software module or a hardware module, or a combination of the two. The device specifically includes: an image acquisition module 1202, a frequency domain transformation processing module 1204, a correction parameter determination module 1206, a fusion weight adjustment module 1208 and a fusion denoising module 1210, wherein:

[0146] An image acquisition module 1202 is used to acquire more than one image to be processed, and determine a reference image and a non-reference image other than the reference image from each image to be processed;

[0147] The frequency domain transform processing module 1204 is used to perform frequency domain transform processing on each reference image block in the reference image after dividing the reference image and the non-reference image into more than one image block respectively, so as to obtain each reference frequency domain image block composed of reference frequency domain pixels, and perform frequency domain transform processing on non-reference image blocks in the non-reference image that match each reference image block, so as to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels;

[0148] A correction parameter determination module 1206 is used to determine the correction parameters corresponding to each reference frequency domain pixel point according to the frequency band corresponding to each reference frequency domain pixel point in each reference frequency domain image block;

[0149] The fusion weight adjustment module 1208 is used to adjust the fusion weight between each reference frequency domain pixel and the corresponding non-reference frequency domain pixel using the correction parameters corresponding to each reference frequency domain pixel; the non-reference frequency domain pixel corresponding to the reference frequency domain pixel is a non-reference frequency domain pixel in the non-reference frequency domain image block that matches the reference frequency domain image block where the reference frequency domain pixel is located;

[0150] The fusion denoising module 1210 is used to fuse each reference frequency domain pixel point with the corresponding non-reference frequency domain pixel point according to the adjusted fusion weight to obtain a denoised image corresponding to each image to be processed.

[0151] In one embodiment, the frequency domain transform processing module 1204 is further used to: for each reference image block in the reference image, determine a non-reference image block from the non-reference image that matches the reference image block in image content as the non-reference image block that matches the reference image block.

[0152] In one embodiment, the correction parameter determination module 1206 is also used to: for each reference frequency domain pixel point, obtain the position information of the reference frequency domain pixel point in the target reference frequency domain image block, the target reference frequency domain image block is the reference frequency domain image block where the reference frequency domain pixel point is located; determine the frequency band corresponding to the reference frequency domain pixel point according to the position information.

[0153] In one embodiment, the position information is a relative coordinate; the correction parameter determination module 1206 is also used to: obtain the horizontal coordinate value and the vertical coordinate value in the relative coordinate of the reference frequency domain pixel point; and determine the frequency band corresponding to the reference frequency domain pixel point based on the sum of the horizontal coordinate value and the vertical coordinate value.

[0154] In one embodiment, the fusion weight adjustment module 1208 is also used to: for each reference frequency domain pixel point, obtain the position information of the reference frequency domain pixel point in the target reference frequency domain image block, the target reference frequency domain image block is the reference frequency domain image block where the reference frequency domain pixel point is located; according to the position information, determine the non-reference frequency domain pixel point corresponding to the reference frequency domain pixel point from the non-reference frequency domain image block that matches the target reference frequency domain image block.

[0155] In one embodiment, the fusion weight adjustment module 1208 is also used to: for each reference frequency domain pixel point, obtain the noise parameter corresponding to the target reference frequency domain image block where the reference frequency domain pixel point is located; determine the frequency domain data difference between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point; and calculate the fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point based on the frequency domain data difference and the noise parameter.

[0156] In one embodiment, the fusion weight adjustment module 1208 is also used to: calculate the product between the correction parameter corresponding to the reference frequency domain pixel point and the noise parameter; after calculating the sum of the product and the frequency domain data difference, calculate the quotient between the frequency domain data difference and the sum; calculate the difference between the predetermined value and the quotient to obtain the adjusted fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point.

[0157] In one embodiment, the fusion weight adjustment module 1208 is also used to: for each reference frequency domain pixel point, determine whether the frequency band corresponding to the reference frequency domain pixel point is a predetermined high frequency band; when the frequency band corresponding to the reference frequency domain pixel point is a predetermined high frequency band, the correction parameter corresponding to the reference frequency domain pixel point is zero, and the adjusted fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is a preset value, so that the fusion processing strategy between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is full fusion.

[0158] In one embodiment, the fusion weight adjustment module 1208 is further used to calculate the adjusted fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point by using the following formula:

[0159]

[0160] Among them, ω i represents the adjusted fusion weight between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the target reference frequency domain image block; diff i represents the frequency domain data difference between the i-th reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point in the target reference frequency domain image block; represents the correction parameter corresponding to the i-th reference frequency domain pixel in the target reference frequency domain image block. When the frequency band corresponding to the i-th reference frequency domain pixel in the target reference frequency domain image block is a predetermined high frequency band, When the frequency band corresponding to the i-th reference frequency domain pixel point in the target reference frequency domain image block is a frequency band other than the predetermined high frequency band in the predetermined frequency band, Noiselevel represents the noise parameter corresponding to the target reference frequency domain image block.

[0161] In one embodiment, the fusion denoising module 1210 is also used to: fuse each reference frequency domain pixel point with the corresponding non-reference frequency domain pixel point according to the adjusted fusion weight to obtain a fused frequency domain image block corresponding to each reference frequency domain image block; perform frequency domain inverse transform processing on each fused frequency domain image block to obtain a denoised image block corresponding to each reference frequency domain image block; and splice each denoised image block to obtain a denoised image corresponding to each image to be processed.

[0162] In one embodiment, the correction parameter determination module 1206 is also used to: for each reference frequency domain image block, determine the proportion of each frequency band in the reference frequency domain image block according to the frequency bands corresponding to each reference frequency domain pixel point in the reference frequency domain image block, and determine the correction parameter corresponding to the reference frequency domain image block according to the frequency band corresponding to the maximum proportion; the fusion weight adjustment module 1208 is also used to: use the correction parameters corresponding to each reference frequency domain image block to adjust the fusion weight between each reference frequency domain image block and the matching non-reference frequency domain image block; the fusion denoising module 1210 is also used to: according to the adjusted fusion weight, fuse each reference frequency domain image block with the matching non-reference frequency domain image block to obtain a denoised image corresponding to each image to be processed.

[0163] For the specific definition of the image processing device, please refer to the definition of the image processing method above, which will not be repeated here. Each module in the above image processing device can be implemented in whole or in part by software, hardware and a combination thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0164] The image processing device in this embodiment divides the reference image and the non-reference image into more than one image block respectively, performs frequency domain transformation processing on each reference image block in the reference image to obtain each reference frequency domain image block composed of reference frequency domain pixels, performs frequency domain transformation processing on non-reference image blocks matching each reference image block in the non-reference image to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels, determines the correction parameters corresponding to each reference frequency domain pixel respectively according to the frequency bands corresponding to each reference frequency domain pixel in each reference frequency domain image block, and uses the correction parameters corresponding to each reference frequency domain pixel respectively. Positive parameters adjust the fusion weights between each reference frequency domain pixel and the corresponding non-reference frequency domain pixel. According to the adjusted fusion weights, each reference frequency domain pixel and the corresponding non-reference frequency domain pixel are fused to obtain a denoised image corresponding to each image to be processed. In this way, due to the differences in image content corresponding to different frequency bands, the reference frequency domain pixels of different frequency bands are treated with denoising strengths suitable for the frequency bands. On the one hand, a balance between image details and denoising effects can be achieved. On the other hand, differences in noise distribution can be eliminated, thereby improving the denoising effect. In addition, motion blur can be avoided in moving areas.

[0165] The division of the modules in the above-mentioned image processing device is only for illustration. In other embodiments, the image processing device may be divided into different modules as needed to complete all or part of the functions of the above-mentioned image processing device.

[0166] Fig.13FIG. 1 is a schematic diagram of the internal structure of an electronic device in one embodiment. Fig.13 As shown, the electronic device includes a processor and a memory connected via a system bus. The processor is used to provide computing and control capabilities to support the operation of the entire electronic device. The memory may include a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The computer program can be executed by the processor to implement an image processing method provided in each of the following embodiments. The internal memory provides a cached operating environment for the operating system computer program in the non-volatile storage medium. The electronic device can be any terminal device such as a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a POS (Point of Sales), a vehicle-mounted computer, a wearable device, etc.

[0167] The implementation of each module in the image processing device provided in the embodiment of the present application may be in the form of a computer program. The computer program may be run on a terminal or a server. The program module constituted by the computer program may be stored in a memory of an electronic device. When the computer program is executed by a processor, the steps of the method described in the embodiment of the present application are implemented.

[0168] The embodiment of the present application further provides a computer-readable storage medium, one or more non-volatile computer-readable storage media containing computer-executable instructions, which, when executed by one or more processors, enable the processors to perform the steps of the image processing method.

[0169] A computer program product comprising instructions, when executed on a computer, causes the computer to perform an image processing method.

[0170] Any reference to memory, storage, database or other medium used in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM), which is used as an external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

[0171] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. An image processing method, characterized in that: include: Acquire more than one image to be processed, and determine a reference image and a non-reference image other than the reference image from each of the images to be processed; After dividing the reference image and the non-reference image into more than one image block respectively, performing frequency domain transformation processing on each reference image block in the reference image to obtain each reference frequency domain image block composed of reference frequency domain pixels, and performing frequency domain transformation processing on non-reference image blocks in the non-reference image that match each reference image block to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels; According to the frequency bands respectively corresponding to the reference frequency domain pixels in each reference frequency domain image block, the correction parameters respectively corresponding to the reference frequency domain pixels are determined; and the corresponding correction parameters are set for each frequency band; Using the correction parameters respectively corresponding to the reference frequency domain pixels, the fusion weights between the reference frequency domain pixels and the corresponding non-reference frequency domain pixels are adjusted; the non-reference frequency domain pixels corresponding to the reference frequency domain pixels are non-reference frequency domain pixels in the non-reference frequency domain image block that matches the reference frequency domain image block where the reference frequency domain pixels are located; According to the adjusted fusion weight, each of the reference frequency domain pixels and the corresponding non-reference frequency domain pixels are fused to obtain a denoised image corresponding to each of the images to be processed.

2. The method according to claim 1, characterized in that: The method further comprises: For each reference image block in the reference image, a non-reference image block matching the reference image block in terms of image content is determined from the non-reference image as the non-reference image block matching the reference image block.

3. The method according to claim 1, characterized in that The method further comprises: For each reference frequency domain pixel point, obtaining position information of the reference frequency domain pixel point in a target reference frequency domain image block, where the target reference frequency domain image block is a reference frequency domain image block where the reference frequency domain pixel point is located; A frequency band corresponding to the reference frequency domain pixel point is determined according to the position information.

4. The method according to claim 3, characterized in that The position information is a relative coordinate; and determining the frequency band corresponding to the reference frequency domain pixel point according to the position information includes: Obtaining the horizontal coordinate value and the vertical coordinate value in the relative coordinates of the reference frequency domain pixel point; The frequency band corresponding to the reference frequency domain pixel point is determined according to the sum of the abscissa value and the ordinate value.

5. The method according to claim 1, characterized in that The method further comprises: For each reference frequency domain pixel point, obtaining position information of the reference frequency domain pixel point in a target reference frequency domain image block, where the target reference frequency domain image block is a reference frequency domain image block where the reference frequency domain pixel point is located; According to the position information, a non-reference frequency domain pixel point corresponding to the reference frequency domain pixel point is determined from the non-reference frequency domain image block that matches the target reference frequency domain image block.

6. The method according to claim 1, characterized in that The method further comprises: For each reference frequency domain pixel point, obtaining a noise parameter corresponding to the target reference frequency domain image block where the reference frequency domain pixel point is located; Determining a frequency domain data difference between the reference frequency domain pixel point and a corresponding non-reference frequency domain pixel point; A fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is calculated according to the frequency domain data difference and the noise parameter.

7. The method according to claim 6, characterized in that The method further comprises: Calculating the product of the correction parameter corresponding to the reference frequency domain pixel point and the noise parameter; After calculating the sum of the product and the frequency domain data difference, calculating a quotient between the frequency domain data difference and the sum; The difference between the predetermined value and the quotient value is calculated to obtain an adjusted fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point.

8. The method according to claim 7, characterized in that The method further comprises: For each reference frequency domain pixel point, determining whether the frequency band corresponding to the reference frequency domain pixel point is a predetermined high frequency band; When the frequency band corresponding to the reference frequency domain pixel point is the predetermined high frequency band, the correction parameter corresponding to the reference frequency domain pixel point is zero, and the adjusted fusion weight between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is a preset value, so that the fusion processing strategy between the reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point is full fusion.

9. The method according to claim 6, characterized in that The adjusted fusion weight between the reference frequency domain pixel and the corresponding non-reference frequency domain pixel is calculated by the following formula: Among them, ω i represents the adjusted fusion weight between the i-th reference frequency domain pixel and the corresponding non-reference frequency domain pixel in the target reference frequency domain image block; diff i represents the frequency domain data difference between the i-th reference frequency domain pixel point and the corresponding non-reference frequency domain pixel point in the target reference frequency domain image block; represents the correction parameter corresponding to the i-th reference frequency domain pixel point in the target reference frequency domain image block, when the frequency band corresponding to the i-th reference frequency domain pixel point in the target reference frequency domain image block is a predetermined high frequency band, When the frequency band corresponding to the i-th reference frequency domain pixel point in the target reference frequency domain image block is a frequency band other than the predetermined high frequency band in the predetermined frequency band, Noiselevel represents the noise parameter corresponding to the target reference frequency domain image block.

10. The method according to claim 1, characterized in that The step of fusing each of the reference frequency domain pixels with the corresponding non-reference frequency domain pixels according to the adjusted fusion weights to obtain a denoised image corresponding to each of the images to be processed includes: According to the adjusted fusion weight, each of the reference frequency domain pixels and the corresponding non-reference frequency domain pixels are fused to obtain fused frequency domain image blocks corresponding to each of the reference frequency domain image blocks; Performing frequency domain inverse transform processing on each of the fused frequency domain image blocks to obtain denoised image blocks corresponding to each of the reference frequency domain image blocks; The denoised image blocks are spliced ​​together to obtain a denoised image corresponding to each of the images to be processed.

11. The method according to claim 1, characterized in that: The method further comprises: For each reference frequency domain image block, determining the proportion of each frequency band in the reference frequency domain image block according to the frequency bands corresponding to each reference frequency domain pixel point in the reference frequency domain image block, and determining the correction parameter corresponding to the reference frequency domain image block according to the frequency band corresponding to the maximum proportion; Using the correction parameters respectively corresponding to the reference frequency domain image blocks, adjusting the fusion weights between the reference frequency domain image blocks and the matching non-reference frequency domain image blocks; According to the adjusted fusion weights, each of the reference frequency domain image blocks and the matching non-reference frequency domain image blocks are fused to obtain a denoised image corresponding to each of the images to be processed.

12. The method according to claim 1, characterized in that The image to be processed is an image in YUV format, and the YUV format is a coding format in which brightness and chrominance are separated.

13. An image processing device, characterized in that: include: An image acquisition module, used for acquiring more than one image to be processed, and determining a reference image and a non-reference image other than the reference image from each of the images to be processed; a frequency domain transform processing module, configured to perform frequency domain transform processing on each reference image block in the reference image after dividing the reference image and the non-reference image into more than one image block respectively, to obtain each reference frequency domain image block composed of reference frequency domain pixels, and to perform frequency domain transform processing on non-reference image blocks in the non-reference image that match each reference image block, to obtain each non-reference frequency domain image block composed of non-reference frequency domain pixels; A correction parameter determination module is used to determine the correction parameters corresponding to each reference frequency domain pixel point in each reference frequency domain image block according to the frequency bands corresponding to each reference frequency domain pixel point in each reference frequency domain image block; and to set the corresponding correction parameters for each frequency band; A fusion weight adjustment module is used to adjust the fusion weight between each of the reference frequency domain pixels and the corresponding non-reference frequency domain pixels using the correction parameters corresponding to each of the reference frequency domain pixels; the non-reference frequency domain pixels corresponding to the reference frequency domain pixels are non-reference frequency domain pixels in the non-reference frequency domain image block that matches the reference frequency domain image block where the reference frequency domain pixels are located; The fusion denoising module is used to fuse each of the reference frequency domain pixels and the corresponding non-reference frequency domain pixels according to the adjusted fusion weights to obtain a denoised image corresponding to each of the images to be processed.

14. An electronic device comprising a memory and a processor, wherein a computer program is stored in the memory, wherein: When the computer program is executed by the processor, the processor is caused to perform the steps of the image processing method according to any one of claims 1 to 12.

15. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the image processing method according to any one of claims 1 to 12 are implemented.

Citation Information

Patent Citations

  • Method and Apparatus for Image Denoising with Three-Dimensional Block-Matching

    CN104751418A

  • Image processing method, device and equipment

    CN107451978A