Improved BM3D denoising method
By using singular value decomposition and Canny edge detection in the BM3D algorithm, the image is decomposed and edge information retention processing is solved, and the edge information loss problem of BM3D algorithm during the denoising process is achieved, and better noise suppression and detail retention effects are achieved.
Patent Information
- Application Number
- CN202510450085.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-11
- Publication Date
- 2025-07-01
AI Technical Summary
The existing BM3D algorithm ignores edge information during the denoising process, resulting in the image edge texture information being erased. Hard threshold filtering is prone to losing high-frequency information and creating artifacts, which cannot meet the needs of industrial visual recognition for clear edges and detailed details.
The singular value decomposition method is used to perform preliminary denoising on the image, decompose it into low-frequency and high-frequency components, and process it separately in the basic estimation and final estimation stage of BM3D. Block matching is performed in combination with the Canny edge detection algorithm, the search strategy is adjusted to retain edge information, and Gaussian high-pass filtering is added in the final estimation stage to enhance high-frequency information.
While removing noise, it better preserves the edge information of the image, reduces the degree of blurring of the image edges, improves the performance of denoising and edge preservation, and is suitable for industries and other fields that require high image accuracy.
Smart Images

Figure CN120235782A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image denoising, and particularly to an improved BM3D denoising method. Background Art
[0002] The original BM3D algorithm is divided into two stages. The first stage is to perform denoising processing on the original noisy image to form a basic estimated image; the second stage is to use the basic estimated image to perform denoising processing on the original noisy image to form a final estimated image. During the basic estimation process, since the original BM3D algorithm ignores the processing of edge information during the search process of similar blocks and only moves the search window along the horizontal and vertical directions of the image, this process will cause the edge texture information to be erased, thereby affecting the overall visual effect of the image. The hard threshold filtering used in the final estimation of the original BM3D algorithm is also prone to losing high-frequency information and generating artifacts. In the fields of electronic components, mechanical parts, and other industrial vision recognition, the requirements for clear edges and detailed details are very high, and the traditional BM3D algorithm cannot meet these requirements.
[0003] Chinese Patent Application CN118864297A discloses an adaptive image denoising method based on absolute median difference and BM3D. This method divides the input image into a set of tiles with specific sizes, uses local variance to iteratively screen out uniform tiles, and then corrects the main dimension eigenvalues through the absolute median difference to obtain the noise standard deviation of the current image. According to the obtained noise intensity estimation, some parameter settings of the BM3D filtering algorithm are completed. In the basic estimation of the BM3D algorithm, noise is initially removed by setting a hard threshold, and then the final estimation is used as an improvement means. The result of the basic estimation is used for matching similar blocks, and the processed image result is used to improve the accuracy of block matching to obtain a more ideal noise reduction result. The purpose of this patent is to improve the existing tile-based noise estimation algorithm and BM3D filtering algorithm, obtain a more accurate noise standard deviation, achieve a balance between noise suppression and detail preservation, and prevent over-filtering of the image or retaining too much noise. The processing principle of the BM3D algorithm is to balance rather than focus on details, and it is not applicable to the denoising scenario of industrial part images with high requirements for retaining edge texture information and high-frequency information.
[0004] In summary, there is currently a need for an improved BM3D algorithm that can restore more detailed textures of the image and better retain the edge information of the image on the premise of effectively removing image noise. Summary of the Invention
[0005] The object of the present invention is to overcome the defects of the above-mentioned existing technologies and provide an improved BM3D denoising method, which can better retain the edge information of the image while removing noise and reduce the degree of blurring of the image edges.
[0006] The object of the present invention can be achieved by the following technical solutions:
[0007] An improved BM3D denoising method, the method comprising:
[0008] Obtain a noisy image, and perform preliminary denoising on the noisy image by using the singular value decomposition method to obtain a preliminary denoising matrix of the noisy image;
[0009] Perform sine-cosine decomposition on the preliminary denoising matrix to obtain a first matrix and a second matrix, where the first matrix is the low-frequency component of the preliminary denoising matrix after sine-cosine decomposition, and the second matrix is the high-frequency component of the preliminary denoising matrix after sine-cosine decomposition;
[0010] Process the first matrix by using the basic estimation stage of BM3D to obtain a basic estimation image;
[0011] Process the second matrix by using the final estimation stage of BM3D, and perform weighted average aggregation on the processing result and the basic estimation image to obtain a final denoised image.
[0012] Further, the preliminary denoising includes:
[0013] Perform singular value decomposition on the noisy image to obtain a left singular vector matrix, a right singular vector matrix, and a singular value matrix;
[0014] Obtain a preset singular value threshold, set the singular values in the singular value matrix that are less than the singular value threshold to 0, and obtain a singular value matrix filtered by the singular value threshold;
[0015] Use the left singular vector matrix, the right singular vector matrix, and the singular value matrix filtered by the singular value threshold to construct a low-rank approximation matrix, and output the low-rank approximation matrix as the preliminary denoising matrix of the noisy image.
[0016] Further, the basic estimation stage of BM3D includes: improved block matching, first three-dimensional transformation, hard threshold filtering, and first weighted average.
[0017] Still further, the improved block matching includes:
[0018] Obtain a first matrix, and identify the edge region and the smooth region of the first matrix by using the Canny edge detection algorithm;
[0019] In the edge region, block matching is performed with the search window moving along the edge contour direction, and in the smooth region, block matching is performed with the search window moving in the horizontal and vertical directions.
[0020] Furthermore, the edge region is the part with rich details, and the smooth region is the part with gentle pixel changes.
[0021] Furthermore, the expression of the first weighted average is:
[0022]
[0023] where i is the row coordinate of the pixel in the image, w i represents the weight corresponding to the estimated value of the i-th pixel, N represents the number of non-zero coefficients after the hard threshold filtering of the 3D patch group, and σ represents the standard deviation of the noise.
[0024] Further, the final estimation stage of the BM3D includes: Gaussian high-pass filtering, second block matching, second 3D transform, Wiener filtering, and second weighted average.
[0025] Furthermore, the expression of the Gaussian high-pass filtering is:
[0026]
[0027] T = μ Y + σ Y ,
[0028]
[0029] where Y′(i) represents the 3D transform domain coefficient after Gaussian threshold filtering, Y(i) is the original 3D transform domain coefficient, is the Gaussian attenuation factor, T is the set threshold, μ Y is the mean of Y(i), σ Y represents the standard deviation of Y(i), and N represents the total number of coefficients in the current calculation window.
[0030] Furthermore, the expression of the second weighted average is:
[0031]
[0032] where i is the row coordinate of the pixel in the image, w i represents the weight corresponding to the estimated value of the i-th pixel, represents the shrinkage coefficient of the Wiener filtering, and σ represents the standard deviation of the noise.
[0033] Further, the expression of the weighted average aggregation is:
[0034]
[0035] Among them, k is the number of stages of BM3D, (i, j) is the pixel value coordinate, and P k (i, j) is the estimated value of the k-th stage of the pixel value, and w k is the weight of the k-th stage.
[0036] Compared with the prior art, the beneficial effects of the present invention include:
[0037] 1. Before performing BM3D algorithm denoising, this application uses singular value decomposition to perform preliminary denoising on the image, performs sine-cosine decomposition on the denoised image, and decomposes it into two parts: a first matrix and a second matrix. The first matrix is used for basic estimation, and the second matrix is used for final estimation. The two sets of estimations are performed independently at the same time. Compared with two consecutive stages, the processing speed is faster, and the processing and retention of edge and high-frequency information are also better.
[0038] 2. This application adds the Canny edge detection algorithm before the block matching step of the first matrix to identify the edge region (part with rich details) and the smooth region (part with gentle pixel changes), aiming to accurately distinguish different characteristics of the image; then adjusts the search strategy during block matching: for the edge region, the search window moves along the edge contour direction to ensure that more edge-similar blocks are correctly grouped into the three-dimensional array, thereby improving the performance of denoising and edge preservation, while the smooth region maintains the original horizontal and vertical search directions to maintain computational efficiency.
[0039] 3. This application adds Gaussian high-pass filtering in the final estimation stage to enhance high-frequency information (such as fine textures and sharp edges) and reduce the loss of high-frequency details.
[0040] 4. This application can better retain the edge information of the image while removing noise, reduce the degree of blurring of the image edges, and is applicable to industrial fields with high requirements for image accuracy and fineness. Description of the Drawings
[0041] Figure 1 is the flowchart of the method of the present invention;
[0042] Figure 2 is the un-denoised picture;
[0043] Figure 3 is the picture after denoising using the existing BM3D denoising method;
[0044] Figure 4 is the picture after denoising using the improved BM3D denoising method of the present invention. Detailed Embodiments
[0045] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.
[0046] Embodiment 1
[0047] This embodiment aims to disclose an improved BM3D denoising method. The method flow is as Figure 1 . The original BM3D algorithm is divided into two stages. The first stage is to perform denoising on the original noisy image to form a basic estimation image. The second stage is to use the basic estimation image to perform denoising on the original noisy image to form a final estimation image. This method aims to improve the original BM3D algorithm. The image to be denoised is divided into two groups and input into the BM3D algorithm respectively. First, in the basic stage, the low-frequency components are used for processing to avoid high-frequency noise interfering with block matching. In the final estimation stage, the original high-frequency components are combined, and real details are restored while suppressing noise through weighted fusion. Finally, the images obtained in the two stages are weighted and fused to obtain a complete denoised image.
[0048] The method disclosed in this embodiment specifically includes:
[0049] S1. Obtain a noisy image, and perform preliminary denoising on the noisy image using the singular value decomposition method to obtain a preliminary denoising matrix of the noisy image;
[0050] S2. Perform sine-cosine decomposition on the preliminary denoising matrix to obtain a first matrix and a second matrix. The first matrix is the low-frequency component of the preliminary denoising matrix after sine-cosine decomposition, and the second matrix is the high-frequency component of the preliminary denoising matrix after sine-cosine decomposition;
[0051] S3. Process the first matrix using the basic estimation stage of BM3D to obtain a basic estimation image;
[0052] S4. Process the second matrix using the final estimation stage of BM3D, and weighted-average aggregate the processing result with the basic estimation image to obtain a final denoised image.
[0053] In step S1, the preliminary denoising includes:
[0054] Perform singular value decomposition on the noisy image to obtain a left singular vector matrix, a right singular vector matrix, and a singular value matrix;
[0055] Obtain a preset singular value threshold, set the singular values in the singular value matrix that are less than the singular value threshold to 0, and obtain a singular value matrix filtered by the singular value threshold;
[0056] Construct a low-rank approximation matrix using the left singular vector matrix, the right singular vector matrix, and the singular value matrix filtered by the singular value threshold, and output the low-rank approximation matrix as the preliminary denoising matrix of the noisy image.
[0057] The matrix after singular value decomposition is in the form of:
[0058] U O Σ O V O T = O,
[0059] where U O is the left singular vector matrix, containing the basis vectors of the row space of O; V O is the right singular vector matrix, containing the basis vectors of the column space of O; ∑ O is the singular value matrix, and the elements on its diagonal are the singular values of O (non-negative and arranged in descending order).
[0060] Specifically, the singular value matrix is denoted as m1 = diag(Σ O ). By setting the singular value threshold and setting the smaller singular values to 0, a new singular value matrix m' can be obtained. Subsequently, using the original U O and V O to reconstruct the low-rank approximation matrix in the form of O' = U0diag(m')V0 T , thus realizing preliminary denoising and providing a cleaner input for subsequent sine-cosine decomposition and BM3D processing.
[0061] In step S2, the image is decomposed into two groups through sine-cosine decomposition. The first matrix is the low-frequency component of the SVD denoising matrix, that is, the cosine part, and the second matrix is the high-frequency component of the SVD denoising matrix, that is, the sine part. The two matrices are respectively input into the basic estimation stage and the final estimation stage, but the input order cannot be reversed. The basic stage uses the low-frequency component for processing, avoiding high-frequency noise interference in block matching. The final estimation stage combines the original high-frequency component, and through weighted fusion, it restores the real details while suppressing noise. If the grouping order is reversed and the high-frequency is processed first, the result of the first step will be distorted due to too much noise, and the low-frequency component cannot compensate for the loss of high-frequency details, resulting in a decline in denoising performance.
[0062] The main steps of each stage of the original BM3D algorithm are block matching, joint filtering, and aggregation.
[0063] The basic estimation stage of the improved BM3D in this embodiment includes: improved block matching, first three-dimensional transformation, hard threshold filtering, and first weighted average.
[0064] In the original BM3D algorithm, during the block matching process, the search window only moves mechanically in the horizontal and vertical directions, ignoring the processing of edge information, resulting in the erasure of edge texture information and affecting the overall visual effect.
[0065] In this embodiment, the improved block matching process includes:
[0066] Obtain the first matrix, and identify the edge region and smooth region of the first matrix through the Canny edge detection algorithm;
[0067] In the edge region, perform block matching with the search window moving along the edge contour direction. In the smooth region, perform block matching with the search window moving in the horizontal and vertical directions.
[0068] Among them, the edge region is the part with rich details, and the smooth region is the part with gentle pixel changes. The purpose of such division is to accurately distinguish different characteristics of the image and facilitate the implementation of subsequent block matching strategies.
[0069] In the block matching strategy, for the edge region, the search window moves along the edge contour direction, which can ensure that more edge-similar blocks are correctly grouped into the three-dimensional array, thereby improving the performance of denoising and edge preservation. While in the smooth region, maintaining the original horizontal and vertical search directions can maintain the computational efficiency.
[0070] The specific process of the Canny edge detection algorithm identifying the edge region and smooth region of the first matrix includes:
[0071] 1. Use the Gaussian filtering formula for image preprocessing;
[0072] The Gaussian filtering formula is:
[0073]
[0074] where (x, y) are the coordinates of pixels in the image, and σ is the standard deviation of the Gaussian distribution, representing the degree of divergence of values;
[0075] 2. Calculate the gradient (including magnitude and direction) of pixel points to obtain the gradient map;
[0076] The specific formulas for gradient calculation include:
[0077]
[0078]
[0079] G x = (-f(x, y) + f(x, y + 1) - f(x + 1, y) + f(x + 1, y + 1)) / 2,
[0080] G y= (-f(x,y) - f(x,y + 1) + f(x + 1,y) + f(x + 1,y + 1)) / 2
[0081] where s x and s y are Canny convolution templates. The result of the Canny operator's convolution operation on the image is the gradient value of each pixel point. If the gradient value of a pixel point is greater than the detection threshold, it indicates that the pixel point is an edge point; otherwise, it is a non-edge point;
[0082] 3. Use non-maximum suppression for edge thinning. The specific approach is to only retain the pixel points corresponding to the local maximum gradient along the positive and negative gradient directions, aiming to select a single maximum value along the edge width and reduce the edge width to a single pixel width. Among them, the gradient direction has 8 directions: up, down, left, right, upper left, lower left, upper right, and lower right;
[0083] 4. Use high and low double thresholds to detect strong edge points (real edges) and weak edge points (potential edges), aiming to connect strong and weak edges to form a continuous edge curve.
[0084] After obtaining the edge curve, it is superimposed on the original Group A to retain more edge region information of the image.
[0085] In the basic estimation stage, the steps of the three-dimensional transformation include:
[0086] After block matching, a three-dimensional array can be obtained. First, perform a two-dimensional discrete cosine transform (DCT transform) on the two-dimensional blocks in each three-dimensional matrix and then perform a one-dimensional transform in the third dimension of the matrix. During the process of using the three-dimensional transformation to process the three-dimensional array, in the transform domain, use the threshold filtering method to achieve noise reduction for the image blocks, and perform an inverse three-dimensional transformation on the noise-reduced image blocks. Finally, obtain the estimated value of the block matching set through the inverse three-dimensional transformation. Generally speaking, the whole process is to stack the similar blocks obtained by block matching, perform orthogonal transformation on the third dimension based on the first two-dimensional transformation, and then use the hard threshold filtering method to filter out the components with small coefficients in the third-dimensional transformation.
[0087] The expression of the overall three-dimensional transformation process is:
[0088]
[0089] where O sanwei refers to the three-dimensional block group obtained by block matching, Γ 3D and respectively refer to the three-dimensional transformation and the inverse three-dimensional transformation, W yuzhi represents the hard threshold filtering, is the set of estimated values in the basic stage obtained after the three-dimensional transformation in the basic stage.
[0090] The formula of DCT transform (two-dimensional discrete cosine transform) is as follows:
[0091]
[0092] Among them, i and j are the horizontal and vertical coordinates in the spatial domain, u and v are the horizontal and vertical coordinates in the frequency domain, N is the side length of the image, f(i, j) is the spatial domain image, and F(u, ν) is the frequency domain image.
[0093] In the basic estimation stage, the specific process of hard threshold filtering includes: performing hard thresholding on the array formed by the three-dimensional transform through the transform coefficients to attenuate noise, setting the coefficients below the threshold to 0, and retaining the coefficients above the threshold. Finally, record the number of non-zeros to calculate the weight of the estimated value of each image block, preparing for the subsequent aggregation and weighting.
[0094] The expression of hard threshold filtering is:
[0095] Hard(x,T) = {0, if |x| ≤ T; x, if |x| > T},
[0096] Among them, x is the input signal, T is the threshold, and Hard(x,T) refers to the hard threshold function;
[0097] In the basic estimation stage, the expression of the first weighted average is:
[0098]
[0099] Among them, i is the row coordinate of the pixel in the image, w i represents the weight corresponding to the estimated value of the i-th pixel, N represents the number of non-zero coefficients after the three-dimensional block group passes through hard threshold filtering, and σ represents the standard deviation of the noise.
[0100] The final estimation stage of BM3D includes: Gaussian high-pass filtering processing, second block matching, second three-dimensional transform, Wiener filtering, and second weighted average.
[0101] Because the original BM3D algorithm is prone to losing high-frequency information and generating artifacts when using hard threshold filtering in the final estimation, so in the final estimation stage, the present invention adds Gaussian high-pass filtering to enhance high-frequency information (such as fine textures and sharp edges), thereby reducing the artifacts and discontinuities generated during the denoising process, and at the same time can better adapt to the changes in the image content, because it can dynamically adjust the threshold according to the statistical characteristics of the local area. Provide a smoother visual effect, making the denoised image visually closer to the original image. More effectively suppress noise, while reducing the damage to the signal during the final estimation process.
[0102] The expression of Gaussian high-pass filtering processing is:
[0103]
[0104] T = μ Y + σ Y ,
[0105]
[0106] Among them, Y′(i) represents the three-dimensional transform domain coefficient after Gaussian threshold filtering, and Y(i) is the original three-dimensional transform domain coefficient. is the Gaussian decay factor, T is the set threshold, μ Y is the mean value of Y(i), and σ Y represents the standard deviation of Y(i), and N represents the total number of coefficients in the current calculation window.
[0107] The specific process of the second block matching includes:
[0108] Select reference blocks from the image in sequence, search for similar blocks according to the reference blocks, and form a three-dimensional block group. The specific implementation steps are as follows: First, select image blocks of the same size as reference blocks in sequence according to a fixed step size. Second, search for similar blocks according to the reference blocks. Usually, the Euclidean distance calculation formula is used to judge the similarity between two image blocks. When the distance between the matching block and the reference block is less than the preset fixed threshold, the matching block is considered a similar block; otherwise, it is not a similar block. According to this judgment criterion, and select the maximum Euclidean distance between similar blocks as the threshold; finally, form a three-dimensional block group with the reference block and all its similar blocks.
[0109] The Euclidean distance calculation formula in this embodiment is:
[0110]
[0111] Among them, O is the reference block in the neighborhood (i, j) of the image, and O i,j is the matching block, and Ω×Ω is the image size.
[0112] The second three-dimensional transform in the final estimation stage is similar to the first three-dimensional transform in the basic stage. After block matching to obtain a three-dimensional array, first perform a two-dimensional transform (DCT transform) on the two-dimensional blocks in each three-dimensional matrix and then perform a one-dimensional transform in the third dimension of the matrix.
[0113] The processing after the three-dimensional transform in the final estimation stage is different from that in the basic stage, and Wiener filtering is used instead of hard thresholding.
[0114] The Wiener filtering expression in the final estimation stage is as follows:
[0115]
[0116] Among them, σ represents the standard deviation of the noise, and y iRepresents the pixel points of the real image.
[0117] The three-dimensional matrix formed by the noise map is scaled by Wiener Filtering, and the expression is as follows:
[0118]
[0119] Among them, O sanwei Refers to the three-dimensional patch group obtained by block matching, Γ 3D And Respectively refer to three-dimensional transformation and three-dimensional inverse transformation, W wei Represents the Wiener filtering operation.
[0120] The expression of the second weighted average is:
[0121]
[0122] Among them, i is the row coordinate of the pixel in the image, w i Represents the weight corresponding to the estimated value of the i-th pixel, Represents the shrinkage coefficient of Wiener filtering, and σ represents the standard deviation of the noise.
[0123] Finally, the processed first matrix and the second matrix are weighted and averaged and aggregated, and its expression is:
[0124]
[0125] Among them, k is the stage number of BM3D, (i, j) is the pixel value coordinate, P k (i, j) is the estimated value of the k-th stage of the pixel value, w k Is the weight of the k-th stage.
[0126] Use the existing BM3D denoising method and the improved BM3D method in this embodiment to Figure 2 The un-denoised pictures of the mechanical parts shown are denoised respectively. The picture after denoising by the existing BM3D denoising method is as Figure 3 Shown, the improved BM3D method in this embodiment and the picture after denoising are as Figure 4 Shown. By comparison, it can be seen that in the image processed by the improved BM3D method in this embodiment, the part edges and the overall texture will be clearer.
[0127] Embodiment 2
[0128] Based on Embodiment 1, this embodiment provides an electronic device, including: one or more processors and a memory. The memory stores one or more programs, and the one or more programs include instructions for executing the improved BM3D denoising method as described above.
[0129] At the hardware level, the electronic device includes a processor, an internal bus, a network interface, a memory, and a non-volatile memory. Of course, it may also include other hardware required for other services. The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it to implement the improved BM3D denoising method described above. Of course, in addition to the software implementation, the present invention does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc. That is to say, the execution subject of the following processing flow is not limited to each logic unit, and can also be hardware or a logic device.
[0130] The memory may include non-permanent memory in a computer-readable medium, in the form of random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash memory (flash RAM). The memory is an example of a computer-readable medium.
[0131] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information by any method or technology. The information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic disk storage or other magnetic storage devices, or any other non-transitory media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include transitory computer-readable media such as modulated data signals and carrier waves.
[0132] The above is only the specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art within the technical scope disclosed by the present invention can easily think of various equivalent modifications or substitutions, and these modifications or substitutions should all be covered within the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.
Claims
1. An improved BM3D denoising method, characterized in that: The method comprises: Acquire a noisy image, perform preliminary denoising on the noisy image using a singular value decomposition method, and acquire a preliminary denoising matrix of the noisy image; Decomposing the preliminary denoising matrix by sine and cosine to obtain a first matrix and a second matrix, wherein the first matrix is a low-frequency component of the preliminary denoising matrix after sine and cosine decomposition, and the second matrix is a high-frequency component of the preliminary denoising matrix after sine and cosine decomposition; Processing the first matrix using the basic estimation stage of BM3D to obtain a basic estimation image; The second matrix is processed by the final estimation stage of BM3D, and the processing result is weighted averaged and aggregated with the basic estimated image to obtain the final denoised image.
2. The improved BM3D denoising method according to claim 1, characterized in that: The preliminary denoising includes: Performing singular value decomposition on the noise image to obtain a left singular vector matrix, a right singular vector matrix and a singular value matrix; Obtain a preset singular value threshold, set the singular values in the singular value matrix that are smaller than the singular value threshold to 0, and obtain a singular value matrix filtered by the singular value threshold; A low-rank approximation matrix is constructed using the left singular vector matrix, the right singular vector matrix and the singular value matrix filtered by the singular value threshold, and the low-rank approximation matrix is output as a preliminary denoising matrix of the noisy image.
3. The improved BM3D denoising method according to claim 1, characterized in that: The basic estimation stage of BM3D includes: improved block matching, first three-dimensional transformation, hard threshold filtering and first weighted averaging.
4. The improved BM3D denoising method according to claim 3, characterized in that: The improved block matching includes: Obtain a first matrix, and identify edge areas and smooth areas of the first matrix using a Canny edge detection algorithm; In the edge area, block matching is performed with the search window moving along the edge contour direction, and in the smooth area, block matching is performed with the search window moving horizontally and vertically.
5. The improved BM3D denoising method according to claim 4, characterized in that: The edge area is a part with rich details, and the smooth area is a part with smooth pixel changes.
6. The improved BM3D denoising method according to claim 3, characterized in that: The expression of the first weighted average is: Where i is the row coordinate of the pixel in the image, w i represents the weight corresponding to the estimated value of the i-th pixel, N represents the number of non-zero coefficients of the 3D tile group after hard threshold filtering, and σ represents the standard deviation of the noise.
7. The improved BM3D denoising method according to claim 1, characterized in that: The final estimation stage of the BM3D includes: Gaussian high-pass filtering, second block matching, second three-dimensional transformation, Wiener filtering and second weighted averaging.
8. The improved BM3D denoising method according to claim 7, characterized in that: The expression of the Gaussian high-pass filtering process is: T=μ Y +s Y , Among them, Y′(i) represents the three-dimensional transform domain coefficient after Gaussian threshold filtering, and Y(i) is the original three-dimensional transform domain coefficient. is the Gaussian attenuation factor, T is the set threshold, μ Y is the mean of Y(i), σ Y represents the standard deviation of Y(i), and N represents the total number of coefficients in the current calculation window.
9. The improved BM3D denoising method according to claim 7, characterized in that: The expression of the second weighted average is: Where i is the row coordinate of the pixel in the image, w i represents the weight corresponding to the estimated value of the i-th pixel, represents the shrinkage coefficient of the Wiener filter, and σ represents the standard deviation of the noise.
10. The improved BM3D denoising method according to claim 1, characterized in that: The expression of the weighted average aggregation is: Among them, k is the stage number of BM3D, (i, j) is the pixel value coordinate, P k (i,j) is the estimated value of the pixel value at stage k, w k is the weight of the k stage.
Citation Information
Patent Citations
Adaptive image denoising method based on absolute median difference and BM3D
CN118864297A