An optimized method for WNNM image denoising based on non-dominated sorting
By introducing non-dominated sorting and singular value soft thresholding into the WNNM algorithm, and using the MSE and MAE of image patches for multi-objective optimization, the accuracy problem of the WNNM algorithm under high noise is solved, and the efficiency and effect of image denoising are improved.
Patent Information
- Application Number
- CN202210502585.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-09
- Publication Date
- 2025-08-01
- Estimated Expiration
- 2042-05-09
AI Technical Summary
The existing WNNM algorithm uses only Euclidean distance as the sole criterion for judging image patch similarity when there is a lot of noise. This results in a single judgment condition, which affects the accuracy of the block matching process and thus the denoising effect.
A non-dominated sorting method is adopted. The image blocks are non-dominated by calculating the mean square error (MSE) and mean absolute error (MAE) between the image blocks. Taking advantage of the fact that the similar block matrix of a noiseless image is a low-rank matrix, the singular values of the matrix are soft-thresholded and shrunk by using different λ values to obtain a low-rank matrix.
It improves the efficiency of image noise reduction, effectively finds the best matching image block, and enhances the noise reduction effect.
Smart Images

Figure CN114897727B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of non-dominated sorting and black-and-white image noise reduction optimization, and in particular to a WNNM image noise reduction optimization method based on non-dominated sorting. Background Art
[0002] Image noise is generated during image transmission and compression, interfering with accurate information extraction from images. In today's information age, images have become a crucial information carrier. However, images contaminated by noise can affect the accuracy of information extraction. Therefore, image denoising remains a crucial image processing problem.
[0003] The primary goal of image denoising is to remove noise from a noise-contaminated image while preserving as much of the original information as possible. This means improving the quality of a noisy image. Many image denoising algorithms approach this problem as an inverse problem, aiming to recover the original image from noisy samples.
[0004] Through extensive research, researchers have proposed numerous image denoising algorithms, primarily including the following categories: image filtering algorithms, total variation methods, wavelet-based methods, sparse representation methods, and methods based on non-local similarity. In recent years, methods based on image non-local similarity (the redundancy of image information, where a block has similarities at different locations) have attracted considerable attention. This method was first proposed in 2005 and has achieved promising results. Since then, numerous denoising algorithms based on the principle of non-local similarity have been proposed, including the three-dimensional block matching algorithm (BM3D), the nuclear norm minimization algorithm (NNM), and the weighted nuclear norm minimization algorithm (WNNM).
[0005] Compared to other denoising algorithms, algorithms based on the principle of non-local similarity can achieve better denoising effects, especially the WNNM algorithm. When calculating the similarity between image blocks and performing similar block matching, this algorithm uses the Euclidean distance between image blocks as the criterion for image similarity. In fact, this method is adopted by many denoising algorithms based on non-local similarity due to its simplicity and good results. However, when the noise is large, more noise points will cause large differences between similar blocks, which will have a significant impact on the phase cycle. If only the Euclidean distance between image blocks is used as the sole criterion for judging image block similarity, the judgment condition will be too simplistic and there is a possibility of misclassification, which will affect the accuracy of the algorithm in the block matching process and thus the denoising effect of the algorithm. Summary of the Invention
[0006] The purpose of this invention is to provide a WNNM image denoising optimization method based on non-dominated sorting to solve the following technical problems:
[0007] In the existing WNNM algorithm, when the noise is large, more noise points will cause a large difference between similar blocks, which will affect the phase cycle. If only the Euclidean distance between image blocks is used as the sole criterion for judging the similarity of image blocks, the judgment condition is too single, and there is a possibility of misclassification, which affects the accuracy of the algorithm in the block matching process and further affects the denoising effect of the algorithm.
[0008] The purpose of the present invention can be achieved by the following technical solutions:
[0009] A WNNM image denoising optimization method based on non-dominated sorting, comprising the following steps:
[0010] Read in the original image O_Img, add random noise to the image according to the set noise variance to obtain the image to be denoised N_Img, and set different initial parameters according to the magnitude of the input noise variance;
[0011] Divide the image into image blocks with overlapping pixels according to the variance of the noise, and obtain the image block P i With the rest of the image blocks P j The MSE and MAE between them are used as the evaluation criteria to perform non-dominated sorting on the image blocks;
[0012] The top k image blocks P j Form a matrix, and use different λ values to perform soft threshold shrinkage on the singular values of the matrix to obtain a low-rank matrix;
[0013] Obtain the singular values of the low-rank matrix, filter out the smaller values among the singular values, and merge the obtained denoised image blocks into a complete image.
[0014] As a further solution of the present invention, the process of dividing the image into image blocks is as follows:
[0015] Obtain the total number of image blocks TotalPatNum, create a new matrix Y, and cyclically store the original image matrix of size patsize*patsize into the matrix Y.
[0016] As a further solution of the present invention, each of the image blocks is a basic processing unit. For each image block, take the surrounding image blocks, calculate the MSE and MAE between them and save them, and then perform non-dominated sorting.
[0017] As a further solution of the present invention, a window range wSize is defined centered on the image block P i Calculate the MSE and MAE between the image block P i And the image block P within the window range wSize j MSE and MAE.
[0018] As a further solution of the present invention, the specific calculation processes of MSE and MAE are as follows:
[0019] For the taken image patch P i , first obtain its adjacent image patch P j . Represent the image patch P i in the form of matrix i, and represent the image patch P j in the form of matrix j. The sum of the squares of the differences between the corresponding elements of matrix i and matrix j is divided by the size of the matrix, and the MSE of the adjacent image patch P j and the image patch P i is obtained. The sum of the absolute values of the differences between the corresponding elements of matrix i and matrix j is divided by the size of the matrix, and the MAE of the adjacent image patch P j and the image patch P i is obtained.
[0020] As a further solution of the present invention, the specific process of non-dominated sorting is as follows:
[0021] For each adjacent image patch of the image patch, obtain the MSE i and MAE i of the adjacent image patch and the image patch. If MSE i >MSE j and MAE i >MAE j , then it is said that patch P i dominates patch P j ;
[0022] Set two parameters n(i) and s(i). n(i) is the number of solution individuals in the adjacent image patch P j that dominate the individual P i . s(i) is the set of solution individuals in the adjacent image patch P j that are dominated by the individual i. Find all individuals with n(i)=0 in the adjacent image patches, store them in the current set F(i), and then for each individual P j in the current set F(i), examine the set of individuals S(i) it dominates. Subtract 1 from the n(k) of each individual P k in the set S(i), that is, subtract 1 from the number of solution individuals that dominate individual k. If n(k)-1 = 0, then store the individual P i in another set H.
[0023] As a further solution of the present invention, take F(i) as the first-level non-dominated individual set, and assign the same non-dominated order i(rank) to the individuals in this set. Then perform the above grading operation on the set H and assign the corresponding non-dominated order until all adjacent image patches are graded.
[0024] As a further solution of the present invention, calculate the crowding degree of individuals in the image block, and according to the non-dominated order i (rank) and the crowding degree i d , a partial order relation can be defined: when the condition i (rank) < j (rank), or i (rank) = j (rank) and i d > j d , define That is to say, when the non-dominated sorting of two individuals is different, select the individual with the smaller sorting number. If two individuals are on the same layer, select the individual with the smaller crowding degree, that is, the less crowded individual around.
[0025] As a further solution of the present invention, the process of filtering out smaller singular values is as follows:
[0026]
[0027] ||X i || w,* = ∑ i |w i σ i (X i )|1,
[0028] w i = [w i1 , w i2 , …, w in ,
[0029] Each term of w i is non-negative, and σ i is the singular value of X i .
[0030]
[0031]
[0032] Find the solution of to obtain the denoised image block
[0033] Advantages of the present invention:
[0034] Compared with the existing WNNM algorithm, the present invention starts from the perspective of non-dominated sorting, optimizes the image block matching of WNNM, studies the image denoising optimization technology based on multi-objective optimization for the two norms MSE and MAE in the image block, improves the denoising efficiency, and denoises by performing non-dominated sorting of the two norms on the image block and using the characteristic that the similar block matrix of the noise-free image is a low-rank matrix, and can effectively find the most matching image block, so that the denoising efficiency of the image is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] The present invention will be further described below with reference to the accompanying drawings.
[0036] Figure 1 It is a schematic diagram of an optimized method for WNNM image denoising based on non-dominated sorting of the present invention. Specific embodiments
[0037] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the 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.
[0038] Please refer to Figure 1 As shown, the present invention is an optimized method for WNNM image denoising based on non-dominated sorting, including the following steps:
[0039] Read in the original image O_Img, add random noise to the image according to the set noise variance to obtain the image to be denoised N_Img, and set different initial parameters according to the magnitude of the input noise variance;
[0040] According to the variance of the noise, divide the picture into image blocks with overlapping pixels to obtain image blocks P i and the rest of the image blocks P j Calculate the MSE and MAE between them, and use this as a criterion to perform non-dominated sorting on the image blocks;
[0041] Form a matrix with the top k ranked image blocks P j Use different λ values to perform soft threshold shrinkage on the singular values of the matrix to obtain a low-rank matrix;
[0042] Obtain the singular values of the low-rank matrix, filter out the smaller values among the singular values, and merge the obtained denoised image blocks into a complete image.
[0043] When the WNNM algorithm calculates the similarity between image blocks for similar block matching, it uses the Euclidean distance between image blocks as the judgment criterion for image similarity. In fact, this method has been adopted by many denoising algorithms based on non-local similarity because it is simple and has achieved good results. However, when the noise is large, more noise points will cause large differences between similar blocks, which will affect the phase cycle. If only the Euclidean distance between image blocks is used as the sole criterion for judging the similarity of image blocks, the judgment condition is too single, there is a possibility of misclassification, which affects the accuracy of the algorithm in the block matching process, and further affects the denoising effect of the algorithm;
[0044] The matrix composed of noise-free image patches is a low-rank matrix. The singular values represent the directions of matrix transformation. The sum of the first s singular values accounts for 99% of the sum of the matrix singular values. Therefore, the first s singular values are the main directions of matrix transformation. In the present invention, different λ values are used to perform soft-threshold shrinkage on the singular values of the matrix to obtain a low-rank matrix. Since the image information energy is mainly concentrated on the singular values with large values, to retain the image information, the singular values with large values correspond to smaller λ values, and the singular values with small values are usually noise and need to be filtered out.
[0045] Compared with the existing WNNM algorithm, the present invention starts from the perspective of non-dominated sorting and optimizes the image patch matching of WNNM. For the two norms MSE and MAE in the image patches, it studies the image denoising optimization technology based on multi-objective optimization, improves the denoising efficiency. By performing non-dominated sorting on the two norms of the image patches and using the characteristic that the similar patch matrix of the noise-free image is a low-rank matrix for denoising, it can effectively find the most matching image patches, thus improving the denoising efficiency of the image.
[0046] In a preferred embodiment of the present invention, the process of splitting the picture into image patches is as follows:
[0047] Calculate the total number of image patches TotalPatNum, create a new matrix Y, and cyclically store the original image matrix of size patsize*patsize into Y.
[0048] In another preferred embodiment of the present invention, each image patch is the basic processing unit. For each image patch, take the surrounding image patches, calculate the MSE and MAE between them and save them, and then perform non-dominated sorting.
[0049] The mean square error (MSE) is the most commonly used regression loss function. The calculation method is to find the sum of the squares of the distances between the predicted values and the true values. The formula is as follows:
[0050]
[0051] MAE is the sum of the absolute values of the differences between the target values and the predicted values. It only measures the average modulus length of the prediction error and does not consider the direction. The value range is also from 0 to positive infinity. The formula is as follows:
[0052]
[0053] MSE is more accurate in judging the extreme values at both ends, while MAE is more accurate in judging the smaller differences in the middle. Therefore, by using MAE and MSE respectively, the coverage range and accuracy of the algorithm are improved.
[0054] In another preferred embodiment of the present invention, for the image patch P iDefine a window range wSize centered around it, and calculate the image patch P i Calculate the MSE and MAE between the image patch P and the image patches Pj within the window range wSize.
[0055] However, the time complexity of calculating non-local similar patches is very high, and the time complexity of calculating the similar patches of all image patches is too large. The present invention defines a window range wSize for the image patch P i and calculates the image patch P i Calculate the MSE and MAE between the image patch P and the image patch P j within the window range wSize. This not only reduces the time complexity, but also the similar patches of an image patch usually exist around this image patch, reducing the interference of redundant image patches.
[0056] In another preferred embodiment of the present invention, the specific calculation process of the MSE and MAE is as follows:
[0057] For the taken image patch P i , first obtain its adjacent image patch P j . Represent the image patch P i in the form of matrix i, represent the image patch P j in the form of matrix j. The sum of the squares of the differences between the corresponding elements of matrix i and matrix j is divided by the size of the matrix, and the MSE between the adjacent image patch P j and the image patch P i is obtained. The sum of the absolute values of the differences between the corresponding elements of matrix i and matrix j is divided by the size of the matrix, and the MAE between the adjacent image patch P j and the image patch P i is obtained.
[0058] The existing WNNM algorithm mainly obtains the similarity between image patches by calculating the Euclidean distance. Although this method is simple and has achieved good results, in the case of noisy images, the noise will affect the calculation of the similarity between image patches, and it may occur that a relatively high similarity is calculated between image patches that are not originally similar, which will affect the denoising effect of subsequent image denoising algorithms; the present invention can effectively find the most matching image patches by performing non-dominated sorting on the image patches with two norms MSE and MAE, improving the denoising efficiency of the image.
[0059] In another preferred embodiment of the present invention, the specific process of non-dominated sorting is as follows:
[0060] For each neighbor patch P i of the image patch, there are their MSE i and MAE i with the image patch. If MSE i > MSE j and MAEi >MAE j , then the block P is called i to dominate the block P j ;
[0061] Set two parameters n(i) and s(i). n(i) is the number of solution individuals that dominate the individual P in the adjacent image block P j among them, and s(i) is the set of solution individuals dominated by the individual i in the adjacent image block P i . Find all individuals with n(i)=0 in the adjacent image block and store them in the current set F(i). Then, for each individual P in the current set F(i) j , examine the set of individuals S(i) it dominates. Subtract 1 from the n(k) of each individual P in the set S(i) j , that is, subtract 1 from the number of solution individuals that dominate the individual k. If n(k)-1 = 0, then store the individual P k in another set H. i
[0062] It should be noted that F(1) is used as the first-level non-dominated individual set, and the individuals in this set are given the same non-dominated order i(rank). Then continue to perform the above hierarchical operation on H and assign the corresponding non-dominated order until all adjacent image blocks are hierarchical.
[0063] Non-dominated sorting uses the concept of Pareto optimal solutions to rank the individuals in the set. The higher the non-dominated state of an individual, the more forward its level, and the richer the data information it contains.
[0064] As a preferred case of this embodiment, obtain the crowding degree of the individuals within the image block. According to the non-dominated order i(rank) and the crowding degree i d , a partial order relationship can be defined: when the condition is satisfied, or i(rank)=j(rank) and i d >j d , define That is to say, when the non-dominated rankings of two individuals are different, take the individual with the smaller ranking number, that is, the individual that is separated first in the hierarchical sorting. If two individuals are in the same layer, take the individual with the smaller crowding degree, that is, the less crowded individual around.
[0065] The calculation of crowding degree requires sorting the population in ascending order according to the magnitude of each objective function value (that is, if the first-level non-dominated layer is obtained, it is sorted according to the magnitude of the objective function, and then the crowding degree is calculated). Therefore, for each objective function, the boundary solutions (the solutions with the maximum and minimum values) are assigned infinite distance values. All other intermediate solutions are assigned to be equal to the absolute difference after normalizing the function values of two adjacent solutions. The calculation method is the same for other objective functions. The total crowding coefficient value is calculated by summing the distance values of each objective of the individual, and each objective function will be normalized before calculating the crowding coefficient;
[0066] Furthermore, the calculation steps of the crowding degree are as follows:
[0067] (1) Initialize the crowding degree i of each point d to 0;
[0068] (2) For each objective, perform non-dominated sorting on the population, and set the crowding degrees of the two boundary individuals to infinity, that is, O d = I d = ∞;
[0069] (3) Calculate the crowding degree of other individuals where i d represents the crowding degree of the i-th point, and f j i+1 represents the j-th objective function value of the (i + 1)-th point, and f j i-1 represents the j-th objective function value of the (i - 1)-th point;
[0070] After obtaining the crowding degree, by comprehensively comparing the crowding degree and the sorting number of the individuals in the set, when the sorting number is small, select the individual with the smaller sorting number. When the sorting numbers are equal, use the crowding degree to measure the distribution of the individuals in the set, so as to select those individuals with uniform distribution and the most information obtained.
[0071] In another preferred embodiment of the present invention, since the image information energy is mainly concentrated on the large singular values, to retain the image information, the large singular values correspond to smaller λ values, and the small singular values are usually noise and need to be filtered out. The objective function is as follows: <{
[0072]
[0073] ||X i || w,* = Σ i |w i σ i (X i )|1,
[0074] [[ID=5i = [w i1 , w i2 , …, w in ,
[0075] w i Each term of i is non - negative, and σ i is the singular value of X
[0076]
[0077]
[0078] Finding the solution of
[0079] can obtain the denoised image patch.
[0080] The singular value of a matrix is a concept in a mathematical sense, generally obtained by singular value decomposition (abbreviated as SVD decomposition). A digital image can be regarded as a two - dimensional matrix whose element values are the gray values of pixels at corresponding positions. With the development of related technologies, modern digital cameras can already take photos with tens of millions of pixels. Therefore, the image matrix generally has a large size. However, because there are a large number of regions with similar colors in the image, that is, the correlation between pixels is relatively strong, it can be imagined that this data matrix has a certain degree of redundancy. Such redundancy can be measured by the rank of the matrix: the higher the rank of the image matrix, the lower the correlation degree between columns; the lower the rank of the image matrix, the more serious the mutual dependence between columns. Although the regions with strong similarity in the image are linearly independent in a strict sense, they can be regarded as approximately linearly correlated. This fact will lead to the generation of very small singular values because this linear independence caused by tiny differences between pixels is not important for the overall representation of the image and often corresponds to the noise in the image. [[ID=Another 31]] [[ID=Another 32]]<0000--278> The above has described an embodiment of the present invention in detail, but the content described is only a preferred embodiment of the present invention and cannot be considered as limiting the scope of implementation of the present invention. All equivalent changes and improvements made according to the scope of the present invention application should still fall within the scope covered by the patent of the present invention.
Claims
1. An optimized method for WNNM image denoising based on non-dominated sorting, characterized in that, It includes the following steps: Read in the original image O_Img, add random noise to the image according to the set noise variance to obtain the image to be denoised N_Img, and set different initial parameters according to the magnitude of the input noise variance; Segment the image into image patches with overlapping pixels according to the variance of the noise, obtain the MSE and MAE between the image patches and adjacent image patches, and perform non-dominated sorting on the image patches based on this as the evaluation criterion; The specific process of non-dominated sorting is: For each adjacent image block of the image block, obtain the MSE of the adjacent image block and the image block i and the MAE i , if the MSE i > MSE j and the MAE i > MAE j , then it is said that block P of the adjacent image block i dominates block P of the adjacent image block j ; Set two parameters n(i) and s(i), where n(i) is the number of solution individuals that dominate the adjacent image block P in the adjacent image blocks i and s(i) is the set of solution individuals dominated by the block P of the adjacent image block in the adjacent image blocks i Find all individuals with n(i) = 0 in the adjacent image blocks, store them in the current set F(i), and then for each block P of the adjacent image blocks in the current set F(i) j , examine the set of individuals S(i) it dominates, and subtract 1 from the n(k) of each individual P k in the set S(i), that is, subtract 1 from the number of solution individuals that dominate individual k. If n(k) - 1 = 0, then store the block P of the adjacent image block i in another set H; Block p of the k adjacent image patches with higher ranks j Form a matrix, perform soft-thresholding shrinkage on the singular values of the matrix using different λ values to obtain a low-rank matrix; Obtain the singular values of the low-rank matrix, filter out the smaller values among the singular values, and merge the obtained denoised image patches into a complete image.
2. The optimized method for WNNM image denoising based on non-dominated sorting according to claim 1, wherein, The process of segmenting the image into image patches is: Obtain the total number of image patches TotalPatNum, create a new matrix Y, and cyclically store the original image matrix of size patsize*patsize into matrix Y.
3. The optimized method for WNNM image denoising based on non-dominated sorting according to claim 2, wherein Each image patch is the basic processing unit. For each image patch, take its surrounding image patches, calculate the MSE and MAE between them and save them, and then perform non-dominated sorting.
4. A method for optimizing WNNM image denoising based on non-dominated sorting according to claim 3, characterized in that, Define a window range wSize centered on the image patch, and calculate the MSE and MAE between the image patch and the image patches within the window range wSize.
5. A method for optimizing WNNM image denoising based on non-dominated sorting according to claim 4, characterized in that, The specific calculation process of MSE and MAE is: For the selected image patch, first obtain its adjacent image patches. Represent the image patch in the form of matrix i, and represent the adjacent image patches in the form of matrix j. The sum of the squares of the differences between the corresponding elements of matrix i and matrix j is divided by the size of the matrix to obtain the MSE between the adjacent image patch and the image patch. The sum of the absolute values of the differences between the corresponding elements of matrix i and matrix j is divided by the size of the matrix to obtain the MAE between the adjacent image patch and the image patch.
6. A method for optimizing WNNM image denoising based on non - dominated sorting according to claim 5, characterized in that, Take F(i) as the first-level non-dominated individual set, and assign the same non-dominated order i(rank) to the individuals within this set. Then perform non-dominated sorting, grading, and assign the corresponding non-dominated order to the set H until all adjacent image patches are graded.
7. A method for optimizing WNNM image denoising based on non-dominated sorting according to claim 6, characterized in that, Calculate the crowding degree of individuals in the image block, according to the non-dominated order i (rank) and the crowding degree i d , a partial order relation can be defined: when the condition i (rank) < j (rank) is satisfied, or i (rank) = j (rank) and i d > j d , define .
Citation Information
Patent Citations
Non-local image denoising method based on similar block matrix rank minimization
CN103049892A
Two-stage image denoising method based on adaptive singular value threshold
CN110349112A