CN112053295B - Image noise reduction method, device, computer equipment and storage medium - Google Patents

Image noise reduction method, device, computer equipment and storage medium Download PDF

Info

Publication number
CN112053295B
CN112053295B CN202010847831.8A CN202010847831A CN112053295B CN 112053295 B CN112053295 B CN 112053295B CN 202010847831 A CN202010847831 A CN 202010847831A CN 112053295 B CN112053295 B CN 112053295B
Authority
CN
China
Prior art keywords
dimensional
image
image block
threshold
noise reduction
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010847831.8A
Other languages
Chinese (zh)
Other versions
CN112053295A (en
Inventor
杨远飞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhuhai Jieli Technology Co Ltd
Original Assignee
Zhuhai Jieli Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhuhai Jieli Technology Co Ltd filed Critical Zhuhai Jieli Technology Co Ltd
Priority to CN202010847831.8A priority Critical patent/CN112053295B/en
Publication of CN112053295A publication Critical patent/CN112053295A/en
Application granted granted Critical
Publication of CN112053295B publication Critical patent/CN112053295B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/70Denoising; Smoothing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Image Processing (AREA)
  • Facsimile Image Signal Circuits (AREA)

Abstract

The application relates to an image noise reduction method, an image noise reduction device, computer equipment and a storage medium. Obtaining a plurality of fixed image blocks from an image to be noise reduced, performing 2D conversion to obtain two-dimensional coefficients corresponding to each image block, performing 1D conversion on three-dimensional coefficients formed by the two-dimensional coefficients of the image blocks to obtain corresponding first one-dimensional coefficients, performing reduction processing on the first one-dimensional coefficients smaller than a one-dimensional threshold to obtain second one-dimensional coefficients corresponding to each image block, performing 1D inverse conversion on the second one-dimensional coefficients to obtain new two-dimensional coefficients corresponding to each image block, performing 2D inverse conversion on the new two-dimensional coefficients to obtain corresponding noise reduction image blocks, and restoring each noise reduction image block to the position of the fixed image block position parameter in the image to obtain the noise reduced image. Compared with the traditional noise reduction method, the method utilizes the transformation of the fixed image block and the plurality of dimension coefficients to reduce noise of the image, and improves the noise reduction effect of the image.

Description

Image noise reduction method, device, computer equipment and storage medium
Technical Field
The present disclosure relates to the field of image processing technologies, and in particular, to an image noise reduction method, an image noise reduction device, a computer device, and a storage medium.
Background
The image is usually shot by the image acquisition equipment, in real life, due to the environment or the sensor, noise is introduced into the shot image, and noise is also introduced into the digital image in the transmission process, so that the quality of the acquired image is low, the visual effect of a user is influenced, the subsequent processing of the image is also influenced, and therefore noise reduction processing is required to be carried out on the image.
Current methods for denoising images typically utilize spatial domain processing or transform domain processing, such as gaussian filtering, mean filtering, wavelet denoising, CNN image denoising, and the like. However, none of these methods remove noise well.
Therefore, the current image noise reduction method has the defect of poor noise reduction effect.
Disclosure of Invention
In view of the foregoing, it is desirable to provide an image noise reduction method, apparatus, computer device, and storage medium capable of improving noise reduction effects.
A method of image denoising, the method comprising:
acquiring an image to be noise reduced and an image noise reduction parameter; the image noise reduction parameters comprise one-dimensional threshold values and fixed image block position parameters;
acquiring a plurality of image blocks from the image according to the fixed image block position parameters;
2D conversion is respectively carried out on the plurality of image blocks, and two-dimensional coefficients corresponding to the image blocks are obtained; performing 1D conversion on three-dimensional coefficients formed by the two-dimensional coefficients of the plurality of image blocks to obtain first one-dimensional coefficients corresponding to each image block; performing reduction processing on the first one-dimensional coefficients smaller than the one-dimensional threshold value to obtain second one-dimensional coefficients corresponding to each image block;
performing 1D inverse transformation on a plurality of second one-dimensional coefficients corresponding to the plurality of image blocks, and obtaining new two-dimensional coefficients corresponding to the plurality of image blocks respectively according to the coefficients after the 1D inverse transformation; performing 2D inverse transformation on the new two-dimensional coefficients corresponding to each image block to obtain noise reduction image blocks corresponding to each image block;
and restoring each noise reduction image block to a position corresponding to the fixed image block position parameter in the image to obtain a noise reduction image.
In one embodiment, the obtaining a plurality of image blocks from the image according to the fixed image block position parameter includes:
traversing the image to be noise reduced by moving a search window; the size of the search window is not larger than the size of the image to be noise reduced;
extracting a plurality of corresponding image blocks from the current traversal position of the search window according to the fixed image block position parameters; the plurality of image blocks are the same size and include overlapping pixels; the size of the image block is not greater than the size of the search window.
In one embodiment, the reducing the first one-dimensional coefficient smaller than the one-dimensional threshold to obtain the second one-dimensional coefficient corresponding to each image block includes:
and setting the first one-dimensional coefficient smaller than the one-dimensional threshold value to 0 to obtain a second one-dimensional coefficient corresponding to each image block.
In one embodiment, the reducing the first one-dimensional coefficient smaller than the one-dimensional threshold to obtain a second one-dimensional coefficient corresponding to each image block includes:
according to the transition distance corresponding to the one-dimensional threshold, performing reduction processing on a first one-dimensional coefficient which is smaller than the one-dimensional threshold and has a distance smaller than or equal to the transition distance, and setting a first one-dimensional coefficient which is smaller than the one-dimensional threshold and has a distance larger than the transition distance to 0, so as to obtain a second one-dimensional coefficient of each image block; the transition distance is a section smaller than the one-dimensional threshold value and is a preset length.
In one embodiment, the reducing the first one-dimensional coefficient smaller than the one-dimensional threshold and having a distance from the one-dimensional threshold smaller than or equal to the transition distance according to the transition distance corresponding to the one-dimensional threshold, and setting the first one-dimensional coefficient smaller than the one-dimensional threshold and having a distance from the one-dimensional threshold larger than the transition distance to 0, to obtain the second one-dimensional coefficient corresponding to each image block, includes:
If the first one-dimensional coefficient is larger than or equal to the one-dimensional threshold, the first one-dimensional coefficient is used as a corresponding second one-dimensional coefficient;
if the first one-dimensional coefficient is smaller than the one-dimensional threshold value and the distance between the first one-dimensional coefficient and the one-dimensional threshold value is smaller than or equal to the transition distance, obtaining a quotient of the one-dimensional threshold value and the transition distance and a difference between the first one-dimensional coefficient and a minimum value in the transition distance, obtaining a product of the quotient and the difference, and obtaining a second one-dimensional coefficient corresponding to the first one-dimensional coefficient;
and if the first one-dimensional coefficient is smaller than the one-dimensional threshold value and the distance between the first one-dimensional coefficient and the one-dimensional threshold value is larger than the transition distance, setting the first one-dimensional coefficient to 0 to obtain a second one-dimensional coefficient corresponding to the first one-dimensional coefficient.
In one embodiment, the image noise reduction parameters further include: a two-dimensional threshold, a texture threshold, and a second weight; the value range of the second weight is 0 to 1;
the step of restoring each noise reduction image block to a position corresponding to the fixed image block position parameter in the image to obtain a noise reduction image comprises the following steps:
acquiring texture blocks in each fixed image block; the texture block is obtained based on the two-dimensional coefficient corresponding to each image block, the two-dimensional threshold value and the texture threshold value;
And compensating the pixel value into the fixed image block position parameter according to the pixel value in the texture block, the pixel value corresponding to the noise reduction image block and the second weight to obtain a noise reduction image.
In one embodiment, the acquiring texture blocks in each of the fixed image blocks includes:
counting the number of two-dimensional coefficients larger than the two-dimensional threshold value in the two-dimensional coefficients corresponding to each image block;
and if the number is greater than the texture threshold, taking the image block as a texture block.
In one embodiment, the image noise reduction parameters further include: a texture window threshold and a first weight; the first weight has a value ranging from 0 to 1;
if the total number of the two-dimensional coefficients in each texture block is larger than a texture window threshold value, determining that a region formed by each texture block is a texture window; if it is determined that the area formed by each texture block is a texture window, the step of performing a reduction process on a first one-dimensional coefficient that is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold smaller than or equal to the transition distance according to the transition distance corresponding to the one-dimensional threshold, and setting a first one-dimensional coefficient that is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold larger than the transition distance to 0, and before obtaining a second one-dimensional coefficient corresponding to each image block, the step of:
Acquiring the product of the one-dimensional threshold value and the first weight as a new one-dimensional threshold value;
and obtaining the product of the transition distance and the first weight as a new transition distance.
In one embodiment, the compensating the pixel value to the fixed image block position parameter according to the pixel value in the texture block, the pixel value corresponding to the noise reduction image block, and the second weight to obtain the noise reduction image includes:
obtaining the product of the pixel value corresponding to the noise reduction image block and the second weight to be used as a first compensation pixel value;
obtaining the product of the pixel value in the texture block and the third weight to be used as a second compensation pixel value; the sum of the third weight and the second weight is 1;
and compensating the sum of the first compensation pixel value and the second compensation pixel value into the fixed image block position parameter to obtain the image after noise reduction.
An image noise reduction apparatus, the apparatus comprising:
the first acquisition module is used for acquiring an image to be noise reduced and image noise reduction parameters; the image noise reduction parameters comprise one-dimensional threshold values and fixed image block position parameters;
the second acquisition module is used for acquiring a plurality of image blocks from the image according to the fixed image block position parameters;
The first transformation module is used for respectively carrying out 2D transformation on the plurality of image blocks to obtain two-dimensional coefficients corresponding to each image block; performing 1D conversion on three-dimensional coefficients formed by the two-dimensional coefficients of the plurality of image blocks to obtain first one-dimensional coefficients corresponding to each image block; performing reduction processing on the first one-dimensional coefficients smaller than the one-dimensional threshold value to obtain second one-dimensional coefficients corresponding to each image block;
the second transformation module is used for carrying out 1D inverse transformation on a plurality of second one-dimensional coefficients corresponding to the plurality of image blocks, and obtaining new two-dimensional coefficients corresponding to the plurality of image blocks respectively according to the coefficients after the 1D inverse transformation; performing 2D inverse transformation on the new two-dimensional coefficients corresponding to each image block to obtain noise reduction image blocks corresponding to each image block;
and the restoration module is used for restoring each noise reduction image block to a position corresponding to the fixed image block position parameter in the image to obtain a noise reduction image.
A computer device comprising a memory storing a computer program and a processor implementing the steps of the method described above when the processor executes the computer program.
A computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method described above.
According to the image noise reduction method, the device, the computer equipment and the storage medium, the image blocks are obtained from the image to be noise reduced by utilizing the fixed image block position parameters, the 2D conversion is carried out on the image blocks to obtain the two-dimensional coefficients corresponding to the image blocks, the 1D conversion is carried out on the three-dimensional coefficients formed by the two-dimensional coefficients of the image blocks to obtain the first one-dimensional coefficients corresponding to the image blocks, the first one-dimensional coefficients smaller than the one-dimensional threshold value are subjected to the reduction processing to obtain the second one-dimensional coefficients corresponding to the image blocks, the 1D inverse conversion is carried out on the second one-dimensional coefficients corresponding to the image blocks to obtain the new two-dimensional coefficients corresponding to the image blocks, the 2D inverse conversion is carried out on the new two-dimensional coefficients to obtain the noise reduction image blocks corresponding to the image blocks, and the noise reduction image blocks are restored to the positions corresponding to the fixed image block position parameters in the image to obtain the noise reduction image. Compared with the traditional noise reduction method, the method utilizes the transformation of the fixed image block and the plurality of dimension coefficients to reduce noise of the image, and improves the noise reduction effect of the image.
Drawings
FIG. 1 is a diagram of an application environment for an image denoising method in one embodiment;
FIG. 2 is a flow chart of an image denoising method according to one embodiment;
FIG. 3 is a schematic diagram of the structure of a search window and image block in one embodiment;
FIG. 4 is a schematic diagram of transition distances in one embodiment;
FIG. 5 is a flowchart of an image denoising method according to another embodiment;
FIG. 6 is a flow chart of a method of image denoising according to yet another embodiment;
FIG. 7 is a block diagram of an image noise reduction device in one embodiment;
fig. 8 is an internal structural diagram of a computer device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
The image noise reduction method provided by the application can be applied to an application environment shown in fig. 1. Wherein the terminal 102 communicates with the server 104 via a network. The terminal 102 may obtain an image to be noise reduced and an image noise reduction parameter from the server 104, and the terminal 102 may further obtain a plurality of image blocks from the image according to a fixed image block position parameter in the image noise reduction parameter, perform 2D conversion, 1D inverse conversion and 2D inverse conversion based on the plurality of image blocks, obtain noise reduction image blocks corresponding to each image block, and restore each noise reduction image block to a position corresponding to the fixed image block position parameter in the image, so as to realize noise reduction of the image. The terminal 102 may be, but not limited to, various personal computers, notebook computers, smartphones, tablet computers, and portable wearable devices, and the server 104 may be implemented by a stand-alone server or a server cluster composed of a plurality of servers.
In one embodiment, as shown in fig. 2, an image noise reduction method is provided, and the method is applied to the terminal in fig. 1 for illustration, and includes the following steps:
step S202, obtaining an image to be noise reduced and image noise reduction parameters; the image noise reduction parameters include one-dimensional thresholds and fixed image block position parameters.
The image to be noise reduced may be obtained from the server 104, or may be obtained locally from the terminal 102; the image to be denoised may be an image with noise data or noise points, the image to be denoised may be any size, and the terminal 102 may further obtain image denoising parameters, including a one-dimensional threshold and fixed image block position parameters. The one-dimensional threshold may be a threshold used when performing thresholding on a one-dimensional coefficient, where thresholding may be a process of dividing an interesting foreground and an uninteresting background of an image, and the one-dimensional coefficient may be a coefficient obtained after 1D conversion of the image, and may be used for noise reduction processing of the image; the fixed image block position parameter may be a fixed image block divided based on the image to be noise reduced, each image block may be a block not larger than the image to be noise reduced, and there may also be a corresponding position parameter. The position parameters of the fixed image block can be determined through preset parameter configuration of the upper computer, and the position parameters of the fixed image block can be adjusted according to practical situations, for example, the upper left corner, the upper right corner, the lower left corner, the lower right corner, the middle and the like in the search window. It should be noted that the number of fixed image blocks in the search window may be set according to the actual situation. In some embodiments, the image to be noise-reduced may be an image that is subjected to a certain pre-processing, and specifically, the terminal 102 may first acquire a captured image, and perform graying processing on the image to obtain a gray-scale image, and perform image noise reduction based on the gray-scale image.
In addition, the terminal 102 may also denoise the R, G, B components and the Y, U, V components. In general, many image pickup apparatuses store YUV component data.
Step S204, a plurality of image blocks are acquired from the image according to the fixed image block position parameters.
The fixed image block position parameter may be a position parameter of a plurality of fixed image blocks determined from the image to be noise reduced, and the terminal 102 may obtain a plurality of image blocks from the image according to the position parameters, where the image blocks may be blocks not larger than the image.
Specifically, the terminal 102 may traverse the image to be noise reduced by moving a search window; wherein the size of the search window is not larger than the size of the image to be noise reduced; extracting a plurality of corresponding image blocks from the current traversal position of the search window according to the fixed image block position parameters; wherein the plurality of image blocks are the same size and include overlapping pixels; the size of the image block is not larger than the size of the search window. The image block may be a block determined from a search window with a preset size, as shown in fig. 3, and fig. 3 is a schematic structural diagram of the search window and the image block in an embodiment. The search window may be an area not larger than a preset size of the image, the terminal 102 may determine a plurality of image blocks from the search window, the positions of the image blocks may be fixed with respect to the search window, as shown in fig. 3, the size of each image block in the search window may be 8x8, each image block may be composed of a plurality of small blocks, the size of each small block may be 4x4,4 small blocks may constitute one image block, and 16 small blocks may constitute the search window. The image blocks within a search window may be in the upper left corner, upper right corner, lower left corner, lower right corner, and middle, respectively. Where the position of the image blocks may be set according to the actual situation, there is only one overlap of small blocks between each block and the middle block, such as the dark shaded portion in fig. 3. The terminal 102 may traverse the image using the search window, and the moving step length of the search window in the image may be 4 each time, so as to reduce the number of times of the search window stroking. And as can be seen from a review of fig. 3, the image blocks corresponding to the upper left corner and the lower left corner in the third search window are actually the image blocks of the upper right corner and the lower right corner in the first search window, so that the number of intra-window dimensional transformations can be further reduced.
Step S206, respectively performing 2D conversion on the plurality of image blocks to obtain two-dimensional coefficients corresponding to the image blocks; performing 1D conversion on three-dimensional coefficients formed by two-dimensional coefficients of a plurality of image blocks to obtain first one-dimensional coefficients corresponding to each image block; and performing reduction processing on the first one-dimensional coefficients smaller than the one-dimensional threshold value to obtain second one-dimensional coefficients corresponding to each image block.
The 2D transform may be a transform method for image processing, and the 2D transform may be a transform using a DCT method, i.e., a 2D DCT transform, which may also be referred to as a two-dimensional discrete cosine transform. The terminal 102 may perform 2D conversion on the plurality of image blocks in the search window to obtain two-dimensional coefficients corresponding to each image block.
The terminal 102 may further perform 1D conversion on a three-dimensional coefficient formed by two-dimensional coefficients of the plurality of image blocks to obtain a first one-dimensional coefficient corresponding to each image block, specifically, the terminal 102 may establish a 3D matrix with the 5 fixed image blocks through the two-dimensional coefficients, where the size may be 5x8x8, and perform 1D conversion, for example, 1D DCT conversion, on a third dimension of the 3D matrix, that is, a Z-axis direction of XYZ, to obtain a first one-dimensional coefficient.
The terminal 102 may perform the threshold processing on the first one-dimensional coefficient, for example, the scaling processing may be performed based on the one-dimensional threshold, or may be performed based on the one-dimensional threshold. The hard threshold may be reduced by setting a first one-dimensional coefficient smaller than a one-dimensional threshold to 0 to obtain a second one-dimensional coefficient corresponding to each image block, and specifically, the processing formula may be as follows: Wherein C (u, v) is a first one-dimensional coefficient C (in) after 1D conversion, T2 is the one-dimensional threshold, and C' (u, v) is a second one-dimensional coefficient after thresholding.
Step S208, performing 1D inverse transformation on a plurality of second one-dimensional coefficients corresponding to the plurality of image blocks, and obtaining new two-dimensional coefficients corresponding to the plurality of image blocks respectively according to the coefficients after the 1D inverse transformation; and carrying out 2D inverse transformation on the new two-dimensional coefficients corresponding to each image block to obtain the noise reduction image block corresponding to each image block.
The second one-dimensional coefficient may be a one-dimensional coefficient obtained by performing 1D transform and thresholding, the terminal 102 may perform 1D inverse transform, for example, 1D DCT inverse transform, on the second one-dimensional coefficients corresponding to the image blocks to obtain new two-dimensional coefficients corresponding to the image blocks after 1D inverse transform, and the terminal 102 may further perform 2D inverse transform, for example, 2D DCT inverse transform, on the new two-dimensional coefficients corresponding to the image blocks to obtain noise reduction image blocks corresponding to the image blocks. Specifically, the number of the obtained noise reduction image blocks may be 5.
And step S210, restoring each noise reduction image block to a position corresponding to the fixed image block position parameter in the image to obtain a noise reduction image.
The noise-reduced image block may be a noise-reduced image block corresponding to an image block in the search window obtained after the 1D inverse transformation and the 2D inverse transformation, for example, 5 noise-reduced image blocks may be obtained, the terminal 102 may restore each noise-reduced image block to a position corresponding to a fixed image block position parameter in the image, obtain a noise-reduced image, for example, may determine a texture region in the image block based on a plurality of thresholds and weights, and restore the noise-reduced image block to the texture region. Because the image blocks in one search window overlap or different image block keys overlap, the terminal 102 may restore the noise reduction image block to the initial position according to the preset weight, that is, the position corresponding to the fixed image block position parameter, the terminal 102 may traverse the whole image through moving the search window, and after each movement, perform noise reduction and restoration on the image block in the search window until the noise reduction of the whole image is completed.
In the image noise reduction method, a plurality of image blocks are obtained from an image to be noise reduced by using fixed image block position parameters, 2D conversion is carried out on the plurality of image blocks to obtain two-dimensional coefficients corresponding to the image blocks, 1D conversion is carried out on three-dimensional coefficients formed by the two-dimensional coefficients of the plurality of image blocks to obtain first one-dimensional coefficients corresponding to the image blocks, reduction processing is carried out on the first one-dimensional coefficients smaller than a one-dimensional threshold to obtain second one-dimensional coefficients corresponding to the image blocks, 1D inverse conversion is carried out on the plurality of second one-dimensional coefficients corresponding to the plurality of image blocks to obtain new two-dimensional coefficients corresponding to the image blocks, 2D inverse conversion is carried out on the new two-dimensional coefficients to obtain noise reduction image blocks corresponding to the image blocks, and the noise reduction image blocks are reduced to positions corresponding to the fixed image block position parameters in the image to obtain the noise reduction image. Compared with the traditional noise reduction method, the method utilizes the transformation of the fixed image block and the plurality of dimension coefficients to reduce noise of the image, and improves the noise reduction effect of the image.
In one embodiment, the reducing the first one-dimensional coefficient smaller than the one-dimensional threshold value to obtain the second one-dimensional coefficient corresponding to each image block includes: according to the transition distance corresponding to the one-dimensional threshold, performing reduction processing on a first one-dimensional coefficient which is smaller than the one-dimensional threshold and has a distance smaller than or equal to the transition distance from the one-dimensional threshold, and setting a first one-dimensional coefficient which is smaller than the one-dimensional threshold and has a distance larger than the transition distance from the one-dimensional threshold to 0, so as to obtain a second one-dimensional coefficient of each image block; the transition distance is a section smaller than the one-dimensional threshold value and of a preset length.
In this embodiment, the above-described reduction process for the first one-dimensional coefficient may be a reduction process based on a weight threshold value. The terminal 102 may perform the reduction processing on the first one-dimensional coefficient that is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold that is smaller than or equal to the transition distance according to the transition distance corresponding to the one-dimensional threshold, or may set the first one-dimensional coefficient that is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold that is greater than the transition distance to 0. The transition distance may be a section smaller than the one-dimensional threshold and having a length equal to a preset length. Fig. 4 is a schematic diagram of a transition distance in an embodiment, as shown in fig. 4. FIG. 4 is a schematic diagram showing one-dimensional coefficients after the scaling process based on the weight threshold, a first one-dimensional coefficient input by a horizontal axis C (in), a second one-dimensional coefficient output by a vertical axis C (out), a hard threshold function as shown by a solid line on the upper right of T2, the second one-dimensional coefficient being unchanged when the first one-dimensional coefficient is greater than or equal to T2, and being 0 when the first one-dimensional coefficient is less than T2; in the reduction processing based on the weight threshold, an improved threshold function adds a transition zone with a value r on the left side of T2, namely a transition distance, on the basis of a hard threshold, so that the continuity of the threshold processing is maintained, and meanwhile, the image detail of the transition zone is maintained.
Through the embodiment, the terminal 102 may perform the reduction processing on the first one-dimensional coefficient based on the transition distance, so that more image details may be retained in the transition zone region, and the noise reduction effect of image noise reduction is improved.
In one embodiment, according to the transition distance corresponding to the one-dimensional threshold, performing reduction processing on a first one-dimensional coefficient smaller than the one-dimensional threshold and having a distance smaller than or equal to the transition distance from the one-dimensional threshold, and setting a first one-dimensional coefficient smaller than the one-dimensional threshold and having a distance greater than the transition distance from the one-dimensional threshold to 0, to obtain a second one-dimensional coefficient corresponding to each image block, including: if the first one-dimensional coefficient is larger than or equal to the one-dimensional threshold, the first one-dimensional coefficient is used as a corresponding second one-dimensional coefficient; if the first one-dimensional coefficient is smaller than the one-dimensional threshold value and the distance between the first one-dimensional coefficient and the one-dimensional threshold value is smaller than or equal to the transition distance, obtaining a quotient of the one-dimensional threshold value and the transition distance and a difference between the first one-dimensional coefficient and the minimum value in the transition distance, and obtaining a product of the quotient and the difference to obtain a second one-dimensional coefficient corresponding to the first one-dimensional coefficient; and if the first one-dimensional coefficient is smaller than the one-dimensional threshold value and the distance between the first one-dimensional coefficient and the one-dimensional threshold value is larger than the transition distance, setting the first one-dimensional coefficient to 0 to obtain a second one-dimensional coefficient corresponding to the first one-dimensional coefficient.
In this embodiment, the terminal 102 may perform the reduction processing on the first one-dimensional coefficient based on the transition distance and the one-dimensional threshold.
Specifically, the formula of the reduction process may be as follows:wherein C (u, v) is a first one-dimensional coefficient C (in) after 1D conversion, T2 is a one-dimensional threshold, r is the distance of a transition zone, namely the transition distance, and C' (u, v) is a second one-dimensional coefficient C (out) after thresholding. The terminal 102 may retain the original first one-dimensional coefficient when the first one-dimensional coefficient is greater than or equal to the one-dimensional threshold, i.e., the original first one-dimensional coefficient is used as the corresponding second one-dimensional coefficient; the terminal 102 may further obtain a quotient of the one-dimensional threshold and the transition distance when the first one-dimensional coefficient is smaller than the one-dimensional threshold and the distance between the first one-dimensional coefficient and the one-dimensional threshold is smaller than or equal to the transition distance, and obtain a difference between the first one-dimensional coefficient and a minimum value in the transition distance, where the minimum value in the transition distance may be a value corresponding to the (T2-r), and obtain a product of the obtained quotient and the difference, to obtain a second one-dimensional coefficient corresponding to the first one-dimensional coefficient; the terminal 102 may further set the first one-dimensional coefficient to 0 when the first one-dimensional coefficient is smaller than the one-dimensional threshold and the distance between the first one-dimensional coefficient and the one-dimensional threshold is greater than the transition distance, so as to obtain a second one-dimensional coefficient corresponding to the first one-dimensional coefficient.
Through the embodiment, the terminal 102 may utilize the transition distance and the one-dimensional threshold to perform the reduction processing on the first one-dimensional coefficient, so that the coefficient is continuous at the one-dimensional threshold, so that more image details are maintained to a certain extent, and the noise reduction effect of image noise reduction is improved.
In one embodiment, restoring each noise-reduced image block to a position corresponding to a fixed image block position parameter in the image to obtain a noise-reduced image includes: obtaining texture blocks in each fixed image block; the texture block is obtained based on the two-dimensional coefficient, the two-dimensional threshold value and the texture threshold value corresponding to each image block; and compensating the pixel value into the fixed image block position parameter according to the pixel value in the texture block, the pixel value corresponding to the noise reduction image block and the second weight to obtain the noise reduction image.
In this embodiment, the image noise reduction parameters may further include: a two-dimensional threshold, a texture threshold, and a second weight, wherein the second weight has a value ranging from 0 to 1. The texture threshold may be a threshold for determining a texture block, and the second weight may be a weight used for image restoration, and the texture block may be an area where a texture in the image to be noise reduced is located. The terminal 102 may determine and acquire the texture block in each image block based on the two-dimensional coefficient corresponding to each image block, the two-dimensional threshold, and the texture threshold.
Specifically, the step of obtaining texture blocks includes: counting the number of two-dimensional coefficients larger than a two-dimensional threshold value in the two-dimensional coefficients corresponding to each image block; and if the number is greater than the texture threshold, taking the image block as a texture block. The terminal 102 may calculate the number of the two-dimensional coefficients whose absolute value is greater than the first threshold N1, that is, the number of the two-dimensional thresholds, traverse the 5 fixed blocks in the search window, and calculate the number of the two-dimensional coefficients satisfying the condition as count1, count2, count3, count4, and count5, and sum the 5 values as count, where count is the total number of the coefficients counted by the current search window, and determine whether the count is greater than the texture window threshold, and if the count is greater than the texture window threshold, the current search window may be determined as the texture window, and the terminal 102 may determine whether the image block belongs to the texture block in the search window belonging to the texture window according to count1, count2, count3, count4, and count 5. Specifically, taking count1 as an example, it is determined whether count1 is greater than the texture threshold, and if so, the image block corresponding to count1 may be determined to be a texture block.
After the terminal 102 obtains the texture block, the pixel value compensation value may be included in the fixed image block position parameter according to the pixel value in the texture block, the pixel value corresponding to the noise reduction image block, and the second weight, so as to obtain the noise reduction image. Specifically, the terminal 102 may compensate the pixel value in the noise reduction image block to the pixel value corresponding to the fixed image block position parameter by using a preset pixel compensation formula, so as to restore the pixel value of the texture block, thereby implementing the noise reduction processing on the image.
With this embodiment, the terminal 102 may determine the texture region from the image block, and may perform pixel value compensation on the texture region by using the second weight, so as to implement noise reduction processing on the image, thereby improving the noise reduction effect of the image.
In one embodiment, if the total number of two-dimensional coefficients in each texture block is greater than a texture window threshold, determining that the region formed by each texture block is a texture window; if it is determined that the area formed by each texture block is a texture window, performing reduction processing on a first one-dimensional coefficient which is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold smaller than or equal to the transition distance according to the transition distance corresponding to the one-dimensional threshold, and setting the first one-dimensional coefficient which is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold larger than the transition distance to 0, so as to obtain a second one-dimensional coefficient corresponding to each image block, wherein the method further comprises: acquiring the product of the one-dimensional threshold value and the first weight as a new one-dimensional threshold value; and obtaining the product of the transition distance and the first weight as a new transition distance.
In this embodiment, the image noise reduction parameters further include: a texture window threshold and a first weight; the first weight has a value in the range of 0 to 1. The texture window threshold may be a threshold for determining whether the search window corresponding to the image block is a texture window, the texture window threshold may be a threshold for comparing with the Scount, and when the value of the Scount is greater than the texture window threshold, the terminal 102 may determine that the search window where the texture block is located is a texture window, and the first weight may be a weight for thresholding the texture window. The terminal 102 may perform corresponding thresholding on a texture window corresponding to the texture block, if the terminal 102 determines that the image block is the texture window, the product of the one-dimensional threshold and the first weight may be obtained as a new one-dimensional threshold, and the product of the transition distance and the first weight may be obtained as a new transition threshold, so that the terminal 102 may perform corresponding reduction processing on the first one-dimensional coefficient according to the new one-dimensional threshold and the new transition threshold. Specifically, the acquisition formulas of the new transition threshold and the new one-dimensional threshold may be as follows:
Wherein T2 may be the one-dimensional threshold, r may be the transition distance, and W1 may be the first weight.
Through the embodiment, the terminal 102 can reduce the one-dimensional threshold and the transition distance by using the first weight, so that the reduced one-dimensional threshold and the reduced transition distance are used for reducing the noise of the image, more image details can be reserved, and the noise reduction effect of the image noise reduction is improved.
In one embodiment, according to a pixel value in a texture block, a pixel value corresponding to a noise reduction image block, and a second weight, the pixel value is compensated to a fixed image block position parameter to obtain a noise reduction image, including: obtaining the product of the pixel value corresponding to the noise reduction image block and the second weight to be used as a first compensation pixel value; obtaining the product of the pixel value in the texture block and the third weight to be used as a second compensation pixel value; the sum of the third weight and the second weight is 1; and compensating the sum of the first compensation pixel value and the second compensation pixel value into the fixed image block position parameter to obtain the image after noise reduction.
In this embodiment, the pixel value in the texture block may be the pixel value corresponding to the image block belonging to the texture block in the search window, the noise reduction image block may be the image block after noise reduction, where the second weight has a corresponding relationship with the position information of the image block in the search window, and the value of the second weight may be between 0 and 1.
The terminal 102 may obtain a product of a pixel value corresponding to the noise reduction image block and a second weight, as a first compensation pixel value, may also obtain a product of a pixel value in the texture block and a third weight, as a second compensation pixel value, where a sum of the third weight and the second weight may be 1, and the terminal 102 may further compensate a sum of the first compensation pixel value and the second compensation pixel value to the fixed image block position parameter, so as to obtain the noise reduction image. The texture block may be determined according to the texture threshold, and the pixel value of the noise reduction image block and the pixel value of the texture block may each include position information of the pixel value, for example, coordinate information of the pixel value.
Specifically, the above formula for pixel value compensation may be as follows: i 3(x,y) =I 1(x,y) W 2 +I 2(x,y) (1-W 2 ) The method comprises the steps of carrying out a first treatment on the surface of the Wherein I1 may be a pixel value after denoising at the (x, y) position in the noise-reduced image block, I2 may be a pixel value at the (x, y) position in the texture block, I3 may be a total pixel value after texture block compensation at the (x, y) position, W2 may be the second weight, and the range is 0-1, and the third weight may be 1-W2. After completing the pixel value compensation of the current search window, the terminal 102 may also perform pixel value compensation on the image in the new position by moving the search window to the new position in the image to be noise reduced until the whole image is traversed, so as to complete the noise reduction of the whole image.
Through the embodiment, the terminal 102 may perform pixel value compensation on the texture block in the image by using the second weight, so that the image may be denoised, and the noise reduction effect of image noise reduction is improved.
In one embodiment, as shown in fig. 5, fig. 5 is a flow chart of an image denoising method according to another embodiment. In this embodiment, the terminal 102 may acquire an image to be noise reduced by using an image acquisition unit, for example, the image to be noise reduced is obtained by capturing through the terminal 102; the terminal 102 may further perform denoising on the image to be denoised by using an image denoising unit, where the image denoising unit may at least include a fixed image block determining unit and a threshold processing unit, the fixed image block determining unit may be a unit for determining a plurality of fixed image blocks in a search window in the image to be denoised, the terminal 102 may perform denoising on the image to be denoised based on the fixed image blocks, for example, may perform threshold processing on the image in the fixed image blocks by using the threshold processing unit, so as to obtain a denoised image, and the terminal 102 may further display the denoised image by using a display unit, for example, may display the denoised image by using a screen of the terminal 102.
Specifically, the specific denoising process of the image denoising unit may be as shown in fig. 6, and fig. 6 is a schematic flow chart of an image denoising method in yet another embodiment. The terminal 102 may set a search window of a preset size, where the search window may be an area smaller than the size of the image, and a preset number of fixed image blocks are acquired in the search window, and the setting positions of the fixed image blocks may be as shown in fig. 3; the terminal 102 may sequentially perform 2D conversion processing on the fixed image blocks to obtain two-dimensional coefficients, and may calculate the number of the two-dimensional coefficients greater than a first threshold, that is, the two-dimensional threshold; the terminal 102 may further sequentially perform 1D conversion on the two-dimensional coefficients to obtain a first one-dimensional coefficient, and perform threshold processing on the first one-dimensional coefficient to obtain a second one-dimensional coefficient, for example, may perform reduction processing on the first one-dimensional coefficient smaller than the threshold to obtain the second one-dimensional coefficient; the terminal 102 may further perform 1D inverse transformation on the second one-dimensional coefficient, perform 2D inverse transformation to obtain a target pixel block, that is, a denoised image block, and restore the denoised image block to a position corresponding to the fixed image block in the original image by using a weight rule, where after the terminal 102 performs denoising in a search window at the current position, the terminal 102 may further move the search window, traverse the whole image, until denoising the whole image is completed, thereby obtaining a denoised image.
Through the embodiment, the terminal 102 can utilize the fixed image block in the search window to reduce the noise of the image through multiple dimension transformation, so as to improve the noise reduction effect of the image noise reduction.
It should be understood that, although the steps in the flowcharts of fig. 2, 5-6 are shown in order as indicated by the arrows, these steps are not necessarily performed in order as indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least a portion of the steps of fig. 2, 5-6 may include multiple steps or stages that are not necessarily performed at the same time, but may be performed at different times, nor does the order in which the steps or stages are performed necessarily performed in sequence, but may be performed alternately or alternately with at least a portion of the steps or stages in other steps or other steps.
In one embodiment, as shown in fig. 7, there is provided an image noise reduction apparatus including: a first acquisition module 500, a second acquisition module 502, a first transformation module 504, a second transformation module 506, and a reduction module 508, wherein:
The first obtaining module 500 is configured to obtain an image to be noise reduced and an image noise reduction parameter; the image noise reduction parameters include one-dimensional thresholds and fixed image block position parameters.
The second obtaining module 502 is configured to obtain a plurality of image blocks from the image according to the fixed image block position parameter.
A first transform module 504, configured to perform 2D transform on a plurality of image blocks, to obtain two-dimensional coefficients corresponding to each image block; performing 1D conversion on three-dimensional coefficients formed by two-dimensional coefficients of a plurality of image blocks to obtain first one-dimensional coefficients corresponding to each image block; and performing reduction processing on the first one-dimensional coefficients smaller than the one-dimensional threshold value to obtain second one-dimensional coefficients corresponding to each image block.
A second transform module 506, configured to perform 1D inverse transform on a plurality of second one-dimensional coefficients corresponding to the plurality of image blocks, and obtain new two-dimensional coefficients corresponding to the plurality of image blocks respectively according to the coefficients after the 1D inverse transform; and carrying out 2D inverse transformation on the new two-dimensional coefficients corresponding to each image block to obtain the noise reduction image block corresponding to each image block.
And the restoration module 508 is configured to restore each noise-reduced image block to a position corresponding to the fixed image block position parameter in the image, so as to obtain a noise-reduced image.
In one embodiment, the second obtaining module 502 is specifically configured to traverse the image to be noise reduced by moving a search window; the size of the search window is not larger than the size of the image to be noise reduced; extracting a plurality of corresponding image blocks from the current traversal position of the search window according to the fixed image block position parameters; the plurality of image blocks are the same size and include overlapping pixels; the size of the image block is not larger than the size of the search window.
In one embodiment, the first transform module 504 is specifically configured to set a first one-dimensional coefficient smaller than a one-dimensional threshold to 0, so as to obtain a second one-dimensional coefficient corresponding to each image block.
In one embodiment, the first transform module 504 is specifically configured to perform a reduction process on a first one-dimensional coefficient that is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold smaller than or equal to the transition distance according to the transition distance corresponding to the one-dimensional threshold, and set the first one-dimensional coefficient that is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold larger than the transition distance to 0, so as to obtain a second one-dimensional coefficient of each image block; the transition distance is a section smaller than the one-dimensional threshold value and of a preset length.
In one embodiment, the first transform module 504 is specifically configured to take the first one-dimensional coefficient as the corresponding second one-dimensional coefficient if the first one-dimensional coefficient is greater than or equal to the one-dimensional threshold; if the first one-dimensional coefficient is smaller than the one-dimensional threshold value and the distance between the first one-dimensional coefficient and the one-dimensional threshold value is smaller than or equal to the transition distance, obtaining a quotient of the one-dimensional threshold value and the transition distance and a difference between the first one-dimensional coefficient and the minimum value in the transition distance, and obtaining a product of the quotient and the difference to obtain a second one-dimensional coefficient corresponding to the first one-dimensional coefficient; and if the first one-dimensional coefficient is smaller than the one-dimensional threshold value and the distance between the first one-dimensional coefficient and the one-dimensional threshold value is larger than the transition distance, setting the first one-dimensional coefficient to 0 to obtain a second one-dimensional coefficient corresponding to the first one-dimensional coefficient.
In one embodiment, the restoring module 508 is specifically configured to obtain texture blocks in each fixed image block; the texture block is obtained based on the two-dimensional coefficient, the two-dimensional threshold value and the texture threshold value corresponding to each image block; and compensating the pixel value into the fixed image block position parameter according to the pixel value in the texture block, the pixel value corresponding to the noise reduction image block and the second weight to obtain the noise reduction image.
In one embodiment, the restoring module 508 is specifically configured to count the number of two-dimensional coefficients greater than a two-dimensional threshold among two-dimensional coefficients corresponding to each image block; and if the number is greater than the texture threshold, taking the image block as a texture block.
In one embodiment, the first transform module 504 is specifically configured to determine that the region formed by each texture block is a texture window if the total number of two-dimensional coefficients in each texture block is greater than a texture window threshold; if the area formed by each texture block is determined to be a texture window, obtaining the product of a one-dimensional threshold value and a first weight to be used as a new one-dimensional threshold value; and obtaining the product of the transition distance and the first weight as a new transition distance.
In one embodiment, the restoring module 508 is specifically configured to obtain, as the first compensated pixel value, a product of a pixel value corresponding to the noise reduction image block and the second weight; obtaining the product of the pixel value in the texture block and the third weight to be used as a second compensation pixel value; the sum of the third weight and the second weight is 1; and compensating the sum of the first compensation pixel value and the second compensation pixel value into the fixed image block position parameter to obtain the image after noise reduction.
For specific limitations of the image noise reduction device, reference may be made to the above limitations of the image noise reduction method, and no further description is given here. The respective modules in the image noise reduction apparatus described above may be implemented in whole or in part by software, hardware, and combinations thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a terminal, and the internal structure thereof may be as shown in fig. 8. The computer device includes a processor, a memory, a communication interface, a display screen, and an input device connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The communication interface of the computer device is used for carrying out wired or wireless communication with an external terminal, and the wireless mode can be realized through WIFI, an operator network, NFC (near field communication) or other technologies. The computer program is executed by a processor to implement a method of image denoising. The display screen of the computer equipment can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, can also be keys, a track ball or a touch pad arranged on the shell of the computer equipment, and can also be an external keyboard, a touch pad or a mouse and the like.
It will be appreciated by those skilled in the art that the structure shown in fig. 8 is merely a block diagram of some of the structures associated with the present application and is not limiting of the computer device to which the present application may be applied, and that a particular computer device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In one embodiment, a computer device is provided that includes a memory having a computer program stored therein and a processor that implements the image denoising method described above when the computer program is executed.
In one embodiment, a computer readable storage medium is provided having a computer program stored thereon, which when executed by a processor implements the image denoising method described above.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, or the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples merely represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the invention. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application is to be determined by the claims appended hereto.

Claims (12)

1. A method of image denoising, the method comprising:
acquiring an image to be noise reduced and an image noise reduction parameter; the image noise reduction parameters comprise a one-dimensional threshold, a two-dimensional threshold, a texture threshold, a second weight and fixed image block position parameters; the fixed image block position parameter represents the position parameter of a fixed image block in the image to be noise reduced; the fixed image block is configured in the image to be noise reduced based on preset parameters and is obtained by dividing the fixed image block in the image to be noise reduced;
Acquiring a plurality of image blocks from the image according to the fixed image block position parameters;
2D conversion is respectively carried out on the plurality of image blocks, and two-dimensional coefficients corresponding to the image blocks are obtained; performing 1D conversion on three-dimensional coefficients formed by the two-dimensional coefficients of the plurality of image blocks to obtain first one-dimensional coefficients corresponding to each image block; performing reduction processing on the first one-dimensional coefficients smaller than the one-dimensional threshold value to obtain second one-dimensional coefficients corresponding to each image block;
performing 1D inverse transformation on a plurality of second one-dimensional coefficients corresponding to the plurality of image blocks, and obtaining new two-dimensional coefficients corresponding to the plurality of image blocks respectively according to the coefficients after the 1D inverse transformation; performing 2D inverse transformation on the new two-dimensional coefficients corresponding to each image block to obtain noise reduction image blocks corresponding to each image block;
restoring each noise reduction image block to a position corresponding to the fixed image block position parameter in the image to obtain a noise reduction image, wherein the noise reduction image comprises the following steps: acquiring texture blocks in each fixed image block; the texture block is obtained based on the two-dimensional coefficient corresponding to each image block, the two-dimensional threshold value and the texture threshold value; and compensating the pixel value into the fixed image block position parameter according to the pixel value in the texture block, the pixel value corresponding to the noise reduction image block and the second weight to obtain a noise reduction image.
2. The method of claim 1, wherein said obtaining a plurality of tiles from said image based on said fixed tile location parameter comprises:
traversing the image to be noise reduced by moving a search window; the size of the search window is not larger than the size of the image to be noise reduced;
extracting a plurality of corresponding image blocks from the current traversal position of the search window according to the fixed image block position parameters; the plurality of image blocks are the same size and include overlapping pixels; the size of the image block is not greater than the size of the search window.
3. The method of claim 1, wherein the performing the scaling down on the first one-dimensional coefficients that are smaller than the one-dimensional threshold to obtain the second one-dimensional coefficients corresponding to each image block comprises:
and setting the first one-dimensional coefficient smaller than the one-dimensional threshold value to 0 to obtain a second one-dimensional coefficient corresponding to each image block.
4. The method according to claim 1, wherein the reducing the first one-dimensional coefficients smaller than the one-dimensional threshold to obtain the second one-dimensional coefficients corresponding to each image block includes:
according to the transition distance corresponding to the one-dimensional threshold, performing reduction processing on a first one-dimensional coefficient which is smaller than the one-dimensional threshold and has a distance smaller than or equal to the transition distance, and setting a first one-dimensional coefficient which is smaller than the one-dimensional threshold and has a distance larger than the transition distance to 0, so as to obtain a second one-dimensional coefficient corresponding to each image block; the transition distance is a section smaller than the one-dimensional threshold value and is a preset length.
5. The method according to claim 4, wherein the step of performing a reduction process on a first one-dimensional coefficient smaller than the one-dimensional threshold and having a distance from the one-dimensional threshold smaller than or equal to the transition distance according to the transition distance corresponding to the one-dimensional threshold, and setting a first one-dimensional coefficient smaller than the one-dimensional threshold and having a distance from the one-dimensional threshold larger than the transition distance to 0, to obtain a second one-dimensional coefficient corresponding to each image block, includes:
if the first one-dimensional coefficient is larger than or equal to the one-dimensional threshold, the first one-dimensional coefficient is used as a corresponding second one-dimensional coefficient;
if the first one-dimensional coefficient is smaller than the one-dimensional threshold value and the distance between the first one-dimensional coefficient and the one-dimensional threshold value is smaller than or equal to the transition distance, obtaining a quotient of the one-dimensional threshold value and the transition distance and a difference between the first one-dimensional coefficient and a minimum value in the transition distance, obtaining a product of the quotient and the difference, and obtaining a second one-dimensional coefficient corresponding to the first one-dimensional coefficient;
and if the first one-dimensional coefficient is smaller than the one-dimensional threshold value and the distance between the first one-dimensional coefficient and the one-dimensional threshold value is larger than the transition distance, setting the first one-dimensional coefficient to 0 to obtain a second one-dimensional coefficient corresponding to the first one-dimensional coefficient.
6. The method of claim 4, wherein the image noise reduction parameters further comprise: a texture window threshold and a first weight; the first weight has a value ranging from 0 to 1;
if the total number of the two-dimensional coefficients in each texture block is larger than a texture window threshold value, determining that a region formed by each texture block is a texture window; if it is determined that the area formed by each texture block is a texture window, the step of performing a reduction process on a first one-dimensional coefficient that is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold smaller than or equal to the transition distance according to the transition distance corresponding to the one-dimensional threshold, and setting a first one-dimensional coefficient that is smaller than the one-dimensional threshold and has a distance from the one-dimensional threshold larger than the transition distance to 0, and before obtaining a second one-dimensional coefficient corresponding to each image block, the step of:
acquiring the product of the one-dimensional threshold value and the first weight as a new one-dimensional threshold value;
and obtaining the product of the transition distance and the first weight as a new transition distance.
7. The method of claim 1, wherein the second weight has a value in the range of 0 to 1.
8. The method of claim 1, wherein the acquiring texture blocks in each of the fixed image blocks comprises:
Counting the number of two-dimensional coefficients larger than the two-dimensional threshold value in the two-dimensional coefficients corresponding to each image block;
and if the number is greater than the texture threshold, taking the image block as a texture block.
9. The method according to claim 1, wherein the compensating the pixel value into the fixed image block location parameter according to the pixel value in the texture block, the pixel value corresponding to the noise reduction image block, and the second weight, to obtain the noise reduction image, includes:
obtaining the product of the pixel value corresponding to the noise reduction image block and the second weight to be used as a first compensation pixel value;
obtaining the product of the pixel value in the texture block and the third weight to be used as a second compensation pixel value; the sum of the third weight and the second weight is 1;
and compensating the sum of the first compensation pixel value and the second compensation pixel value into the fixed image block position parameter to obtain the image after noise reduction.
10. An image noise reduction device, the device comprising:
the first acquisition module is used for acquiring an image to be noise reduced and image noise reduction parameters; the image noise reduction parameters comprise a one-dimensional threshold, a two-dimensional threshold, a texture threshold, a second weight and fixed image block position parameters; the fixed image block position parameter represents the position parameter of a fixed image block in the image to be noise reduced; the fixed image block is configured in the image to be noise reduced based on preset parameters and is obtained by dividing the fixed image block in the image to be noise reduced;
The second acquisition module is used for acquiring a plurality of image blocks from the image according to the fixed image block position parameters;
the first transformation module is used for respectively carrying out 2D transformation on the plurality of image blocks to obtain two-dimensional coefficients corresponding to each image block; performing 1D conversion on three-dimensional coefficients formed by the two-dimensional coefficients of the plurality of image blocks to obtain first one-dimensional coefficients corresponding to each image block; performing reduction processing on the first one-dimensional coefficients smaller than the one-dimensional threshold value to obtain second one-dimensional coefficients corresponding to each image block;
the second transformation module is used for carrying out 1D inverse transformation on a plurality of second one-dimensional coefficients corresponding to the plurality of image blocks, and obtaining new two-dimensional coefficients corresponding to the plurality of image blocks respectively according to the coefficients after the 1D inverse transformation; performing 2D inverse transformation on the new two-dimensional coefficients corresponding to each image block to obtain noise reduction image blocks corresponding to each image block;
the restoring module is used for restoring each noise reduction image block to a position corresponding to the fixed image block position parameter in the image to obtain a noise reduction image, and is specifically used for: acquiring texture blocks in each fixed image block; the texture block is obtained based on the two-dimensional coefficient corresponding to each image block, the two-dimensional threshold value and the texture threshold value; and compensating the pixel value into the fixed image block position parameter according to the pixel value in the texture block, the pixel value corresponding to the noise reduction image block and the second weight to obtain a noise reduction image.
11. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any one of claims 1 to 9 when the computer program is executed.
12. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 9.
CN202010847831.8A 2020-08-21 2020-08-21 Image noise reduction method, device, computer equipment and storage medium Active CN112053295B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010847831.8A CN112053295B (en) 2020-08-21 2020-08-21 Image noise reduction method, device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010847831.8A CN112053295B (en) 2020-08-21 2020-08-21 Image noise reduction method, device, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112053295A CN112053295A (en) 2020-12-08
CN112053295B true CN112053295B (en) 2024-04-05

Family

ID=73599771

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010847831.8A Active CN112053295B (en) 2020-08-21 2020-08-21 Image noise reduction method, device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112053295B (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101510305A (en) * 2008-12-15 2009-08-19 四川虹微技术有限公司 Improved self-adapting histogram equilibrium method
CN101582984A (en) * 2009-04-14 2009-11-18 公安部物证鉴定中心 Method and device for eliminating image noise
JP2010211552A (en) * 2009-03-11 2010-09-24 Rohm Co Ltd Image processing method and computer program
CN103093433A (en) * 2013-01-25 2013-05-08 西安电子科技大学 Natural image denoising method based on regionalism and dictionary learning
CN106934398A (en) * 2017-03-09 2017-07-07 西安电子科技大学 Image de-noising method based on super-pixel cluster and rarefaction representation
CN107292851A (en) * 2017-07-14 2017-10-24 重庆理工大学 A kind of BM3D image denoising methods converted based on pseudo- 3D
CN107451981A (en) * 2017-08-15 2017-12-08 四川长虹电器股份有限公司 Picture noise level estimation method based on DCT and gradient covariance matrix
CN108259774A (en) * 2018-01-31 2018-07-06 珠海市杰理科技股份有限公司 Image combining method, system and equipment
CN110458206A (en) * 2019-07-24 2019-11-15 东北师范大学 A kind of attention behavior model based on deep learning
CN111476735A (en) * 2020-04-13 2020-07-31 厦门美图之家科技有限公司 Face image processing method and device, computer equipment and readable storage medium

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190045193A1 (en) * 2018-06-29 2019-02-07 Intel Corporation Region-based motion estimation and modeling for accurate region-based motion compensation for efficient video processing or coding

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101510305A (en) * 2008-12-15 2009-08-19 四川虹微技术有限公司 Improved self-adapting histogram equilibrium method
JP2010211552A (en) * 2009-03-11 2010-09-24 Rohm Co Ltd Image processing method and computer program
CN101582984A (en) * 2009-04-14 2009-11-18 公安部物证鉴定中心 Method and device for eliminating image noise
CN103093433A (en) * 2013-01-25 2013-05-08 西安电子科技大学 Natural image denoising method based on regionalism and dictionary learning
CN106934398A (en) * 2017-03-09 2017-07-07 西安电子科技大学 Image de-noising method based on super-pixel cluster and rarefaction representation
CN107292851A (en) * 2017-07-14 2017-10-24 重庆理工大学 A kind of BM3D image denoising methods converted based on pseudo- 3D
CN107451981A (en) * 2017-08-15 2017-12-08 四川长虹电器股份有限公司 Picture noise level estimation method based on DCT and gradient covariance matrix
CN108259774A (en) * 2018-01-31 2018-07-06 珠海市杰理科技股份有限公司 Image combining method, system and equipment
CN110458206A (en) * 2019-07-24 2019-11-15 东北师范大学 A kind of attention behavior model based on deep learning
CN111476735A (en) * 2020-04-13 2020-07-31 厦门美图之家科技有限公司 Face image processing method and device, computer equipment and readable storage medium

Also Published As

Publication number Publication date
CN112053295A (en) 2020-12-08

Similar Documents

Publication Publication Date Title
KR101643672B1 (en) Optical flow tracking method and apparatus
JP5007228B2 (en) Image cleanup and precoding
CN108921800B (en) Non-local mean denoising method based on shape self-adaptive search window
Zhang et al. Low-rank decomposition-based restoration of compressed images via adaptive noise estimation
KR102144994B1 (en) Method for decreasing noise of image and image processing apparatus using thereof
CN106709928B (en) fast two-dimensional maximum inter-class variance threshold method for noisy images
US10254854B2 (en) Tracker for cursor navigation
JP2015225665A (en) Image noise removal method and image noise removal device
JP6726060B2 (en) Image processing apparatus, control method thereof, and program
US8823777B2 (en) Real-time depth extraction using stereo correspondence
US9449371B1 (en) True motion based temporal-spatial IIR filter for video
CN106952314B (en) Recursive prediction method for compressing image based on frequency domain direction filter
WO2014070273A1 (en) Recursive conditional means image denoising
Lee et al. Fast 3D video stabilization using ROI-based warping
CN112053295B (en) Image noise reduction method, device, computer equipment and storage medium
CN115797194A (en) Image denoising method, image denoising device, electronic device, storage medium, and program product
JP2005339535A (en) Calculation of dissimilarity measure
CN112784828B (en) Image detection method and device based on direction gradient histogram and computer equipment
CN113362338B (en) Rail segmentation method, device, computer equipment and rail segmentation processing system
Kamilov et al. Motion-adaptive depth superresolution
CN112150532A (en) Image processing method and device, electronic equipment and computer readable medium
WO2015128302A1 (en) Method and apparatus for filtering and analyzing a noise in an image
CN111260590A (en) Image noise reduction method and related product
Jiji et al. Enhancement of underwater deblurred images using gradient guided filter
CN113497886B (en) Video processing method, terminal device and computer-readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 519000 No. 333, Kexing Road, Xiangzhou District, Zhuhai City, Guangdong Province

Applicant after: ZHUHAI JIELI TECHNOLOGY Co.,Ltd.

Address before: Floor 1-107, building 904, ShiJiHua Road, Zhuhai City, Guangdong Province

Applicant before: ZHUHAI JIELI TECHNOLOGY Co.,Ltd.

GR01 Patent grant
GR01 Patent grant