Abstract
The Non-Local Means (NLM) algorithm is a fundamental denoising technique widely utilized in various domains of image processing. However, further research is essential to gain a comprehensive understanding of its capabilities and limitations. This includes determining the types of noise it can effectively remove, choosing an appropriate kernel, and assessing its convergence behavior. In this study, we optimize the NLM algorithm for all variations of independent and identically distributed (i.i.d.) variance-stabilized noise and conduct a thorough examination of its convergence behavior. We introduce the concept of the optimal oracle NLM, which minimizes the upper bound of pointwise \(L_{1}\) or \(L_{2}\) risk. We demonstrate that the optimal oracle weights comprise triangular kernels with point-adaptive bandwidth, contrasting with the commonly used Gaussian kernel, which has a fixed bandwidth. The computable optimal weighted NLM is derived from this oracle filter by replacing the similarity function with an estimator based on the similarity patch. We present theorems demonstrating that both the oracle filter and the computable filter achieve optimal convergence rates under minimal regularity conditions. Finally, we conduct numerical experiments to validate the performance, accuracy, and convergence of \(L_{1}\) and \(L_{2}\) risk minimization for NLM. These convergence theorems provide a theoretical foundation for further advancing the study of the NLM algorithm and its practical applications.


















Similar content being viewed by others
Data Availability
Data sets generated during the current study are available from the corresponding author on reasonable request.
References
Buades, A., Coll, B., Morel, J.-M.: A review of image denoising algorithms, with a new one. Multiscale Model. Simul. 4(2), 490–530 (2005). https://doi.org/10.1137/040616024
Brox, T., Kleinschmidt, O., Cremers, D.: Efficient nonlocal means for denoising of textural patterns. IEEE Trans. Image Process. 17(7), 1083–1092 (2008). https://doi.org/10.1109/TIP.2008.924281
Froment, J.: Parameter-free fast pixelwise non-local means denoising. Image Process. On Line 4, 300–326 (2014). https://doi.org/10.5201/ipol.2014.120
Buades, A., Coll, B., Morel, J.-M.: Non-local means denoising. Image Process. On Line 1, 208–212 (2011). https://doi.org/10.5201/ipol.2011.bcm_nlm
Guo, J., Guo, Y., Jin, Q., Ng, M.K.-P., Wang, S.: Gaussian patch mixture model guided low-rank covariance matrix minimization for image denoising. SIAM J. Imaging Sci. 15(4), 1601–1622 (2022). https://doi.org/10.1137/21M1454262
Dabov, K., Foi, A., Katkovnik, V., Egiazarian, K.: Image denoising by sparse 3-d transform-domain collaborative filtering. IEEE Trans. Image Process. 16(8), 2080–2095 (2007). https://doi.org/10.1109/TIP.2007.901238
Makitalo, M., Foi, A.: Optimal inversion of the generalized Anscombe transformation for Poisson–Gaussian noise. IEEE Trans. Image Process. 22(1), 91–103 (2012)
Maggioni, M., Katkovnik, V., Egiazarian, K., Foi, A.: Nonlocal transform-domain filter for volumetric data denoising and reconstruction. IEEE Trans. Image Process. 22(1), 119–133 (2012)
Guo, Y., Davy, A., Facciolo, G., Morel, J.-M., Jin, Q.: Fast, nonlocal and neural: a lightweight high quality solution to image denoising. IEEE Signal Process. Lett. 28, 1515–1519 (2021)
Gilboa, G., Osher, S.: Nonlocal operators with applications to image processing. Multiscale Model. Simul. 7(3), 1005–1028 (2009). https://doi.org/10.1137/070698592
Zhang, X., Burger, M., Bresson, X., Osher, S.: Bregmanized nonlocal regularization for deconvolution and sparse reconstruction. SIAM J. Imaging Sci. 3(3), 253–276 (2010). https://doi.org/10.1137/090746379
Jin, Y., Jiang, X., Jiang, W.: An image denoising approach based on adaptive nonlocal total variation. J. Vis. Commun. Image Represent. 65, 102661 (2019). https://doi.org/10.1016/j.jvcir.2019.102661
Demircan-Tureyen, E., Kamasak, M.E.: Nonlocal adaptive direction-guided structure tensor total variation for image recovery. Signal Image Video Process. 15(7), 1517–1525 (2021). https://doi.org/10.1007/s11760-021-01884-8
Liu, J., Osher, S.: Block matching local SVD operator based sparsity and TV regularization for image denoising. J. Sci. Comput. 78(1), 607–624 (2019). https://doi.org/10.1007/s10915-018-0785-8
Kang, M., Kang, M., Jung, M.: Total generalized variation based denoising models for ultrasound images. J. Sci. Comput. 72(1), 172–197 (2017). https://doi.org/10.1007/s10915-017-0357-3
Shreyamsha Kumar, B.K.: Image denoising based on non-local means filter and its method noise thresholding. Signal Image Video Process. 7(6), 1211–1227 (2013). https://doi.org/10.1007/s11760-012-0389-y
Coupé, P., Hellier, P., Kervrann, C., Barillot, C.: Bayesian non local means-based speckle filtering. In: 2008 5th IEEE International Symposium on Biomedical Imaging: From Nano to Macro, pp. 1291–1294 (2008). https://doi.org/10.1109/ISBI.2008.4541240
Lebrun, M., Buades, A., Morel, J.-M.: A nonlocal Bayesian image denoising algorithm. SIAM J. Imaging Sci. 6(3), 1665–1688 (2013). https://doi.org/10.1137/120874989
Lebrun, M., Buades, A., Morel, J.-M.: Implementation of the “non-local Bayes’’ (NL-Bayes) image denoising algorithm. Image Process. On Line 3, 1–42 (2013). https://doi.org/10.5201/ipol.2013.16
Tasdizen, T.: Principal components for non-local means image denoising. In: 2008 15th IEEE International Conference on Image Processing, pp. 1728–1731 (2008). https://doi.org/10.1109/ICIP.2008.4712108
Salmon, J., Harmany, Z., Deledalle, C.-A., Willett, R.: Poisson noise reduction with non-local PCA. J. Math. Imaging Vis. 48(2), 279–294 (2014). https://doi.org/10.1007/s10851-013-0435-6
Manjón, J.V., Coupé, P., Buades, A.: MRI noise estimation and denoising using non-local PCA. Med. Image Anal. 22(1), 35–47 (2015). https://doi.org/10.1016/j.media.2015.01.004
Manjón, J.V., Carbonell-Caballero, J., Lull, J.J., García-Martí, G., Martí-Bonmatí, L., Robles, M.: MRI denoising using non-local means. Med. Image Anal. 12(4), 514–523 (2008). https://doi.org/10.1016/j.media.2008.02.004
Coupé, P., Yger, P., Prima, S., Hellier, P., Kervrann, C., Barillot, C.: An optimized blockwise nonlocal means denoising filter for 3-d magnetic resonance images. IEEE Trans. Med. Imaging 27(4), 425–441 (2008). https://doi.org/10.1109/TMI.2007.906087
He, L., Greenshields, I.R.: A nonlocal maximum likelihood estimation method for Rician noise reduction in MR images. IEEE Trans. Med. Imaging 28(2), 165–172 (2009). https://doi.org/10.1109/TMI.2008.927338
Jia, Z., Jin, Q., Ng, M.K., Zhao, X.-L.: Non-local robust quaternion matrix completion for large-scale color image and video inpainting. IEEE Trans. Image Process. 31, 3868–3883 (2022)
Xiong, B., Yin, Z.: A universal denoising framework with a new impulse detector and nonlocal means. IEEE Trans. Image Process. 21(4), 1663–1675 (2012). https://doi.org/10.1109/TIP.2011.2172804
Hu, H., Li, B., Liu, Q.: Removing mixture of Gaussian and impulse noise by patch-based weighted means. J. Sci. Comput. 67(1), 103–129 (2016). https://doi.org/10.1007/s10915-015-0073-9
Deledalle, C.-A., Denis, L., Tupin, F.: Iterative weighted maximum likelihood denoising with probabilistic patch-based weights. IEEE Trans. Image Process. 18(12), 2661–2672 (2009). https://doi.org/10.1109/TIP.2009.2029593
Kim, G., Cho, J., Kang, M.: Cauchy noise removal by weighted nuclear norm minimization. J. Sci. Comput. 83(15), 1–21 (2020). https://doi.org/10.1007/s10915-020-01203-2
Jiang, J., Yang, K., Yang, J., Yang, Z.-X., Chen, Y., Luo, L.: A new nonlocal means based framework for mixed noise removal. Neurocomputing 431, 57–68 (2021). https://doi.org/10.1016/j.neucom.2020.12.039
Kindermann, S., Osher, S., Jones, P.W.: Deblurring and denoising of images by nonlocal functionals. Multiscale Model. Simul. 4(4), 1091–1115 (2005). https://doi.org/10.1137/050622249
Peyré, G., Bougleux, S., Cohen, L.: Non-local regularization of inverse problems. In: European Conference on Computer Vision, pp. 57–68 (2008). https://doi.org/10.1007/978-3-540-88690-7_5
Wang, X., Girshick, R., Gupta, A., He, K.: Non-local neural networks. In: 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 7794–7803 (2018). https://doi.org/10.1109/CVPR.2018.00813
Zhu, Z., Xu, M., Bai, S., Huang, T., Bai, X.: Asymmetric non-local neural networks for semantic segmentation. In: 2019 IEEE/CVF International Conference on Computer Vision (ICCV), pp. 593–602 (2019). https://doi.org/10.1109/ICCV.2019.00068
Mei, Y., Fan, Y., Zhang, Y., Yu, J., Zhou, Y., Liu, D., Fu, Y., Huang, T.S., Shi, H.: Pyramid attention networks for image restoration. arXiv:2004.13824 (2020). https://doi.org/10.48550/arXiv.2004.13824
Zhang, K., Gao, X., Tao, D., Li, X.: Single image super-resolution with non-local means and steering kernel regression. IEEE Trans. Image Process. 21(11), 4544–4556 (2012). https://doi.org/10.1109/TIP.2012.2208977
Iqbal, M.Z., Ghafoor, A., Siddiqui, A.M.: Satellite image resolution enhancement using dual-tree complex wavelet transform and nonlocal means. IEEE Geosci. Remote Sens. Lett. 10(3), 451–455 (2013). https://doi.org/10.1109/LGRS.2012.2208616
Rousseau, F.: A non-local approach for image super-resolution using intermodality priors. Med. Image Anal. 14(4), 594–605 (2010). https://doi.org/10.1016/j.media.2010.04.005
Gilboa, G., Osher, S.: Nonlocal linear image regularization and supervised segmentation. Multiscale Model. Simul. 6(2), 595–630 (2007). https://doi.org/10.1137/060669358
Eskildsen, S.F., Coupé, P., Fonov, V., Manjón, J.V., Leung, K.K., Guizard, N., Wassef, S.N., Østergaard, L.R., Collins, D.L., Alzheimer’s Disease Neuroimaging Initiative: BEaSt: brain extraction based on nonlocal segmentation technique. NeuroImage 59(3), 2362–2373 (2012). https://doi.org/10.1016/j.neuroimage.2011.09.012
Juan-Albarracín, J., Fuster-Garcia, E., Juan, A., García-Gómez, J.M.: Non-local spatially varying finite mixture models for image segmentation. Stat. Comput. 31(1), 1–10 (2021). https://doi.org/10.1007/s11222-020-09988-w
Rousselle, F., Knaus, C., Zwicker, M.: Adaptive rendering with non-local means filtering. ACM Trans. Gr. 31(6), 1–11 (2012). https://doi.org/10.1145/2366145.2366214
Zhang, X., Chan, T.F.: Wavelet inpainting by nonlocal total variation. Inverse Probl. Imaging 4(1), 191 (2010). https://doi.org/10.3934/ipi.2010.4.191
Li, Z., Lou, Y., Zeng, T.: Variational multiplicative noise removal by DC programming. J. Sci. Comput. 68(3), 1200–1216 (2016). https://doi.org/10.1007/s10915-016-0175-z
Ma, L., Xu, L., Zeng, T.: Low rank prior and total variation regularization for image deblurring. J. Sci. Comput. 70(3), 1336–1357 (2017). https://doi.org/10.1007/s10915-016-0282-x
Zhang, T., Chen, J., Wu, C., He, Z., Zeng, T., Jin, Q.: Edge adaptive hybrid regularization model for image deblurring. Inverse Probl. 38(6), 065010 (2022). https://doi.org/10.1088/1361-6420/ac60bf
Osher, S., Mao, Y., Dong, B., Yin, W.: Fast linearized Bregman iteration for compressive sensing and sparse denoising. Commun. Math. Sci. 8(1), 93–111 (2010). https://doi.org/10.4310/CMS.2010.v8.n1.a6
Lou, Y., Zhang, X., Osher, S., Bertozzi, A.: Image recovery via nonlocal operators. J. Sci. Comput. 42(2), 185–197 (2010). https://doi.org/10.1007/s10915-009-9320-2
Quan, Y., Ji, H., Shen, Z.: Data-driven multi-scale non-local wavelet frame construction and image recovery. J. Sci. Comput. 63(2), 307–329 (2015). https://doi.org/10.1007/s10915-014-9893-2
Chen, D.-Q.: Data-driven tight frame learning scheme based on local and non-local sparsity with application to image recovery. J. Sci. Comput. 69(2), 461–486 (2016). https://doi.org/10.1007/s10915-016-0205-x
Jin, Q., Grama, I., Liu, Q.: A new Poisson noise filter based on weights optimization. J. Sci. Comput. 58(3), 548–573 (2014). https://doi.org/10.1007/s10915-013-9743-7
Jin, Q., Grama, I., Kervrann, C., Liu, Q.: Nonlocal means and optimal weights for noise removal. SIAM J. Imaging Sci. 10(4), 1878–1920 (2017). https://doi.org/10.1137/16M1080781
Jin, Q., Grama, I., Liu, Q.: Convergence theorems for the non-local means filter. Inverse Probl. Imaging 12(4), 853–881 (2018). https://doi.org/10.3934/ipi.2018036
Jin, Q., Grama, I., Liu, Q.: Poisson shot noise removal by an oracular non-local algorithm. J. Math. Imaging Vis. 63(7), 855–874 (2021). https://doi.org/10.1007/s10851-021-01033-3
Chaudhury, K.N., Singer, A.: Non-local Euclidean medians. IEEE Signal Process. Lett. 19(11), 745–748 (2012). https://doi.org/10.1109/LSP.2012.2217329
Maleki, A., Narayan, M., Baraniuk, R.G.: Anisotropic nonlocal means denoising. Appl. Comput. Harmonic Anal. 35(3), 452–482 (2013). https://doi.org/10.1016/j.acha.2012.11.003
Deledalle, C.-A., Duval, V., Salmon, J.: Non-local methods with shape-adaptive patches (NLM-SAP). J. Math. Imaging Vis. 43(2), 103–120 (2012). https://doi.org/10.1007/s10851-011-0294-y
Li, X., Zhou, Y., Zhang, J., Wang, L.: Multipatch unbiased distance non-local adaptive means with wavelet shrinkage. IEEE Trans. Image Process. 29, 157–169 (2020). https://doi.org/10.1109/TIP.2019.2928644
Chatterjee, P., Milanfar, P.: Patch-based near-optimal image denoising. IEEE Trans. Image Process. 21(4), 1635–1649 (2012). https://doi.org/10.1109/TIP.2011.2172799
Frosio, I., Kautz, J.: Statistical nearest neighbors for image denoising. IEEE Trans. Image Process. 28(2), 723–738 (2019). https://doi.org/10.1109/TIP.2018.2869685
Kervrann, C., Boulanger, J.: Local adaptivity to variable smoothness for exemplar-based image regularization and representation. Int. J. Comput. Vis. 79(1), 45–69 (2008). https://doi.org/10.1007/s11263-007-0096-2
Salmon, J., Strozecki, Y.: Patch reprojections for non-local methods. Signal Process. 92(2), 477–489 (2012). https://doi.org/10.1016/j.sigpro.2011.08.011
Van De Ville, D., Kocher, M.: Sure-based non-local means. IEEE Signal Process. Lett. 16(11), 973–976 (2009). https://doi.org/10.1109/LSP.2009.2027669
Liu, X., Deng, W.: Higher order approximation for stochastic space fractional wave equation forced by an additive space-time Gaussian noise. J. Sci. Comput. 87(11), 1–29 (2021). https://doi.org/10.1007/s10915-021-01415-0
Duval, V., Aujol, J.-F., Gousseau, Y.: A bias-variance approach for the nonlocal means. SIAM J. Imaging Sci. 4(2), 760–788 (2011). https://doi.org/10.1137/100790902
Salmon, J.: On two parameters for denoising with non-local means. IEEE Signal Process. Lett. 17(3), 269–272 (2010). https://doi.org/10.1109/LSP.2009.2038954
Wu, Y., Tracey, B., Natarajan, P., Noonan, J.P.: James-stein type center pixel weights for non-local means image denoising. IEEE Signal Process. Lett. 20(4), 411–414 (2013). https://doi.org/10.1109/LSP.2013.2247755
Nguyen, M.P., Chun, S.Y.: Bounded self-weights estimation method for non-local means image denoising using minimax estimators. IEEE Trans. Image Process. 26(4), 1637–1649 (2017). https://doi.org/10.1109/TIP.2017.2658941
Anscombe, F.J.: The transformation of Poisson, binomial and negative-binomial data. Biometrika 35(3/4), 246–254 (1948). https://doi.org/10.1093/biomet/35.3-4.246
Zhang, B., Fadili, J.M., Starck, J.-L.: Wavelets, ridgelets, and curvelets for Poisson noise removal. IEEE Trans. Image Process. 17(7), 1093–1108 (2008)
Azzari, L., Foi, A.: Variance stabilization for noisy + estimate combination in iterative Poisson denoising. IEEE Signal Process. Lett. 23(8), 1086–1090 (2016)
Hai, N.H., Thanh, D.N., Hien, N.N., Premachandra, C., Prasath, V.S.: A fast denoising algorithm for x-ray images with variance stabilizing transform. In: 2019 11th International Conference on Knowledge and Systems Engineering (KSE), pp. 1–5. IEEE (2019). https://ieeexplore.ieee.org/abstract/document/8919364
Foi, A.: Noise estimation and removal in MR imaging: the variance-stabilization approach. In: 2011 IEEE International Symposium on Biomedical Imaging: From Nano to Macro, pp. 1809–1814. IEEE (2011). https://ieeexplore.ieee.org/abstract/document/5872758
Feller, W.: An Introduction to Probability Theory and Its Applications, vol. 2, 2nd edn. Wiley, New York (1971)
Fan, J., Gijbels, I.: Local Polynomial Modelling and Its Applications. Routledge, New York (1996). https://doi.org/10.1201/9780203748725
Zhang, K., Zuo, W., Chen, Y., Meng, D., Zhang, L.: Beyond a Gaussian denoiser: residual learning of deep CNN for image denoising. IEEE Trans. Image Process. 26(7), 3142–3155 (2017). https://doi.org/10.1109/TIP.2017.2662206
Wang, Z., Bovik, A.C., Sheikh, H.R., Simoncelli, E.P.: Image quality assessment: from error visibility to structural similarity. IEEE Trans. Image Process. 13(4), 600–612 (2004). https://doi.org/10.1109/TIP.2003.819861
Makitalo, M., Foi, A.: Optimal inversion of the Anscombe transformation in low-count Poisson image denoising. IEEE Trans. Image Process. 20(1), 99–109 (2011). https://doi.org/10.1109/TIP.2010.2056693
Acknowledgements
The authors are very grateful to Prof. Jean-Michel Morel for helpful comments and suggestions. This work was supported by the National Natural Science Foundation of China (No. 12061052), Young Talents of Science and Technology in Universities of Inner Mongolia Autonomous Region (No. NJYT22090), Natural Science Foundation of Inner Mongolia Autonomous Region (Nos. 2024LHMS01006, 2024MS01002), Innovative Research Team in Universities of Inner Mongolia Autonomous Region (No. NMGIRT2207), “111 project” of higher education talent training in Inner Mongolia Autonomous Region, Inner Mongolia University Independent Research Project (No. 2022-ZZ004), Inner Mongolia University Postgraduate Research and Innovation Programmes (No. 11200-5223737), Inner Mongolia Science and Technology Achievement Transfer and Transformation Demonstration Zone, University Collaborative Innovation Base, and University Entrepreneurship Training Base” Construction Project (Supercomputing Power Project) (No. 21300-231510) and the network information center of Inner Mongolia University.
Author information
Authors and Affiliations
Corresponding author
Ethics declarations
Conflict of interest
The authors declare that they have no conflict of interest.
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Appendix. Proofs of the Main Results
Appendix. Proofs of the Main Results
1.1 The Proof of Theorem 1
Because the objective function \({\mathcal {J}}_{k,\phi }(\omega )\) defined by (12) is continuously differentiable, and both the equality constraint \(\sum _{x\in {\mathcal {N}}_{x_{0},D}}\omega (x)=1\) and inequality constraints \(\omega (x)\ge 0, x \in {\mathcal {N}}_{x_{0},D}\) are differentiable, we consider the Lagrange function:
where \(k=1,2\), \(\omega , g \in {\mathbb {R}}^{M}\) are vectors whose components are \(\omega (x)\), \(x \in {\mathcal {N}}_{x_{0},D}\), and g(x), \(x \in {\mathcal {N}}_{x_{0},D}\). Moreover, g(x) and \(a(x_{0}) \in {\mathbb {R}}\) are Lagrange multipliers corresponding to inequality and equality constraints, respectively. Let \(\omega ^{*}\) be the optimal solution to the minimization problem (13).
For the case \(k=2\), a similar proof can be found in [53]. In this paper, we only demonstrate the case \(k=1\). To find the solution \((\omega ^*, a(x_{0}), g)\) for the optimization problems mentioned above, the Karush-Kuhn-Tucker conditions must be satisfied. Specifically, the solution should satisfy the following equation, where
and we have the following equations:
First, we prove that the weight expression (14) holds, where \(a(x_{0})\) satisfies (15). From (A.4), if \(g(x)=0\), then \(\omega ^{*}(x)\ge 0\), and substitute them into Eq. (A.2), we get
It is known that \(\sigma > 0\) and \(S(x_{0}) \ge 0\), so \(a(x_{0})-\phi (x,x_{0})\ge 0\) in this case. If \(g(x)>0\), we get \(\omega ^{*}(x) = 0\) from (A.4). Similarly, substituting them into (A.2), we get
Thus
Then, from the equality constraint and expression (A.5), we know that
thereby \(\sum _{x\in {\mathcal {N}}_{x_{0},D}}\sqrt{\frac{\pi }{2}}S(x_{0}) \left[ a(x_{0})-\phi (x,x_{0}) \right] _{+} = \sigma \), and substitute it into (A.6), we get
In addition, by substituting (A.5) into (A.3), we get
and combining (A.7), we get the following equation
Therefore, the relation (14) is proved, and \(a(x_{0})\) satisfies Eq. (A.8).
Next, we prove that \(a(x_{0})\) is the unique solution of Eq. (A.8) and prove the uniqueness of the weights \(\omega ^{*}(x)\). We define the function
which is strictly increasing and continuous on \(\left[ 0,+\infty \right) \). Further, we have \({\mathcal {H}}(0)= 0\) and \(\lim \nolimits _{a(\! x_ {0}\! )\rightarrow +\! \infty }\) \({\mathcal {H}}(a(x_{0}))= +\infty \). So there exists a unique solution on \(\left( 0,+\infty \right) \) of the equation \({\mathcal {H}}(a(x_{0}))= \frac{2\sigma ^{2}}{\pi }\). Moreover, according to the uniqueness of \(a(x_{0})\) and (A.8) the weights \(\omega ^* (x),\ x\in {{\mathcal {N}}_{x_{0},D}}\) are also uniquely determined by \(\phi (x,x_{0}),\) \( x\in {{\mathcal {N}}_{x_{0},D}}\).
1.2 The Proof of Theorem 2
Proof
The theorem with \(k=2\) is similar to that in [53]. In this paper, we only demonstrate the theorem in the case \(k=1\).
In order to solve the problem (17) with \(k=1\), we introduce a series of auxiliary functions \({\mathcal {H}}_{j}(a(x_{0}))\), \(j=0,1,\ldots ,M-1\) defined as follow
Let \(a_{1,j}(x_{0})\), \(j=0,1,\ldots ,M-1\) be the solution of \({\mathcal {H}}_{j}(a(x_{0}))\) respectively. Obviously, \({\mathcal {H}}_{M-1}(a(x_{0}))\) is equal to \({\mathcal {H}}(a(x_{0}))\). For convenience, denote \(\phi (x_{M},x_{0})=+ \infty \).
Since function \({\mathcal {H}}(a(x_{0}))\) is strictly increasing on \(\left( 0,+ \infty \right) \) with \({\mathcal {H}}(0)=0\) and \({\mathcal {H}}(+\infty )=+\infty \), Eq. (17) admits a unique solution \(a(x_{0})\) on \(\left( 0,+ \infty \right) \), which must be located in some interval \( [ \phi (x_{{\overline{\jmath }}},x_{0}),\) \(\phi (x_{{\overline{\jmath }}+1},x_{0}) )\), where \(0\le {\overline{\jmath }} \le M-1\). Hence (17) with \(k=1\) becomes
where \( \phi (x_{{\overline{\jmath }}},x_{0})\le a_{1,{\overline{\jmath }}}(x_{0})<\phi (x_{{\overline{\jmath }}+1},x_{0}) \).
According to Eq. (A.9), it is easy to find that the function \({\mathcal {H}}_{j}(a(x_{0}))\) continuous and strictly increasing on \(\left( 0,+ \infty \right) \) with \({\mathcal {H}}_{j}(0)=0\) and \({\mathcal {H}}_{j}(+ \infty )=+ \infty \). Therefore, there is an unique solution \(a_{1,j}(x_{0})\) of (A.9) in \(\left( 0,+ \infty \right) \) for each j. We first demonstrate that \(a_{1,j}(x_{0})\) is decreasing monotonically with respect to j, i.e. \(a_{1,j}(x_{0})\ge a_{1,j+1}(x_{0})\). \(i=0,1,\ldots , M-1\). The hypothesis \(a_{1,j+1} (x_{0})> a_{1,j}(x_{0}),j=0,1,\ldots ,M-1\) leads to
But \( \sum \nolimits _{i=0}^{j+1} \! \left( \left[ a_{1,j+1}(x_{0})\! - \!\phi (x_{i},x_{0}) \right] _{+} \right) ^{2} =\frac{2{\sigma }^{2}}{\pi }\), so the hypothesis is not true, i.e.\(a_{1,j}(x_{0})\) is decreasing monotonically with respect to j.
We then prove the theorem. When \(j=0\), \( a^2_{1,0}(x_{0}) = \frac{2{\sigma }^{2}}{\pi }\), i.e. \(a_{1,0}(x_{0}) = \sqrt{\frac{2}{\pi }}\sigma >0=\phi (x_{0},x_{0})\). \(a_{1,M}(x_{0})\le a_{1,0}(x_{0})<\phi (x_{M},x_{0})=+\infty \) due to \(a_{1,j}(x_{0})\) is decreasing monotonically and with respect to j. Obviously, there exists \(j^{*}\) that \(j^{*}=\max \{j|\phi (x_{j},x_{0})\le a_{1,j}(x_{0})\}\), \(0< j^{*} \le M-1\).
We now prove that \({\overline{\jmath }}=j^*\). It is sufficient to prove that \( a_{1,j}(x_{0})< \phi (x_{j},x_{0})\) if \({\overline{\jmath }}<j\le M-1\). Since \(a_{1,j}(x_{0})\) is decreasing monotonically and \(\phi (x_{j},x_{0})\) is monotonically increasing respect to j, for \(j>{\overline{\jmath }}\) we have
We finally show that if \(0\le j < M-1\) and \(a_{1,j}(x_{0})<\phi (x_{j},x_{0})\), so that \(j^* = \max \{j|a_{1,j}(x_{0})\ge \phi (x_{j},x_{0})\}\) is the unique integer \(j\in \{1,2,\cdots ,M-1\}\) such that \(a_{1,j}(x_{0})\ge \phi (x_{j},x_{0})\) and \(a_{1,j+1}(x_{0})< \phi (x_{j+1},x_{0})\) if \(0\le j<M-1\). According to \(a_{1,j}(x_{0})\) is decreasing monotonically and \(\phi (x_{j},x_{0})\) is monotonically increasing respect to j, the inequality \(a_{1,j}(x_{0})< \phi (x_{j},x_{0})\) leads to
\(\square \)
1.3 The Proof of Theorem 3
We first prove the Eq. (28) holds for \(x_{0}\in {\Omega }\). The objective function \({\mathcal {J}}_{k,\phi }(\omega ) \) is known to be defined by (12) and the optimal weights \(\omega \) is defined by (14), where \(\phi (x,x_{0}) = \left| u(x)-u(x_{0}) \right| \). According to the Hölder condition (26) we know that for any \(\omega \), we get
where
where \(\theta =\sqrt{\frac{2}{\pi }}\) when \(k=1\), and \(\theta =1\) when \(k=2\). From Theorem 1,
where \({\tilde{a}}(x_{0})> 0\) is the unique solution on \(\left( 0, +\infty \right) \) to the equation
where \(z\ge 0\).
Lemma 1
Suppose that \(c_{1} n^{-\alpha }\le h\le 1\), where \( 0\le \alpha \le \frac{1}{2\beta +2}\) and \(c_{1}> 0\) if \(0 \le \alpha < \frac{1}{2\beta +2}\), \(c_{1}> c_{0} = \left( \frac{\sigma ^{2}(2\beta +2)(\beta + 2)}{R L^{2}} \right) ^{\frac{1}{2\beta + 2}}\) if \(\alpha = \frac{1}{2\beta +2}\). Then
and
where \(k=1,2\). \(R=4\pi \beta ^2\) when \(k=1\), and \(R=8\beta \) when \(k=2\). o(1) denotes an infinite small quantity and \(c_{2}\), \(c_{3}\) are positive constants that depend only on \(\beta \), L and \(\sigma \).
Proof
We first prove that (A.15) holds when \(h = 1\) (that is, \({\mathcal {N}}_{x_{0},D} = {\Omega } \)). According to the definition of \({\tilde{a}}(x_{0})\) (see (A.14)), we have
Let \({\tilde{h}}=\left( \frac{{\tilde{a}}(x_{0})}{L} \right) ^{\frac{1}{\beta }}\), then \({\tilde{a}}(x_{0})= L{\tilde{h}}^{\beta }\), where by we get
According to (A.18) and \({\tilde{a}}(x_{0})= L{\tilde{h}}^{\beta }\), (A.17) becomes
By the definition of the neighbourhood \({\mathcal {N}}_{x_{0},{\tilde{D}}}\) with \( {\tilde{h}}=\frac{{\tilde{D}}-1}{2N}\), we easily know that
where o(1) denotes an infinitely small quantity, this formula also applies to the case where \(2\beta \) is used instead of \(\beta \), so
Thus, (A.19) implies
from which we infer that
where
By (A.23) and the definition of \({\tilde{h}}\), we get
which proves (A.15) in the case when \(h = 1\).
We now prove (A.15) for \(c_{1} n^{-\alpha }\le h< 1\), where \( 0\le \alpha \le \frac{1}{2\beta +2}\) and \(c_{1}> 0\) if \(0 \le \alpha < \frac{1}{2\beta +2}\), \(c_{1}> c_{0}\) if \(\alpha = \frac{1}{2\beta +2}\). It is easy to know that \(h\ge {\tilde{h}}= c_{0}n^{-\frac{1 }{2\beta +2}}(1+o(1))\) for n to be large enough. Using again (A.18), we see that
from this formula it follows that if h satisfies \(c_{1}n^{-\alpha }\le h <1\), then \({\tilde{a}}(x_{0})= c_{2}n^{-\frac{\beta }{2\beta +2}}(1+o(1))\) is also the solution of the Eq. (A.14). This completes the proof of (A.15).
The case \(k=2\) is the same to [53], in this paper, we only prove the case \(k=1\).
By substituting (A.13) in (A.12) and using the equivalence (A.19), we get
where
and the last equality holds from the fact that \({\tilde{a}}(x_{0})=L{\tilde{h}}^{\beta }\). Since
where the last equality is obtained by using (A.19), we have \(\pi L^{2}P_{{\tilde{h}}}= \pi L^{2}{\tilde{h}}^{\beta }Q_{{\tilde{h}}}- 2\sigma ^{2}\). Substituting to (A.24) and using (A.23), we obtain
where \(c_{3}=Lc_0^\beta \) and depends on \(\beta \), L, and \(\sigma \). \(\square \)
See from (11), because \(\sum _{x\in {\mathcal {N}}_{x_{0},D}}\omega (x)\varepsilon (x) \sim N(0, {\sigma }^2\sum _{x\in {\mathcal {N}}_{x_{0},D}} {\omega ^2(x)})\) when \(D\rightarrow +\infty \), we have \(\delta ^{E}_{n}= O(n^{-\frac{\beta }{2\beta +2}})\) for sufficiently large D. It is easy to get
Hence, Lemma 1, (A.11) and (12) indicate that the Eq. (28) holds for \(k=1\) and \(x_{0}\in {\Omega }\), while Lemma 1, (A.11) and (10) imply that the Eq. (28) holds for \(k=2\) and \(x_{0}\in {\Omega }\).
We finally prove that the Eq. (28) holds for all the points on \({\Omega }_{0}\).
Let \(x_{0}\in {\Omega }_{0}\), we have \(x'_{0} = (x'_{0,1},x'_{0,2})= \left( \frac{[N x_{0,1}]}{N},\frac{[N x_{0,2}]}{N}\right) \in {\Omega }\) and \({\hat{u}}_{k,D}^{*}(x_{0}) = {\hat{u}}_{k,D}^{*}(x'_{0})\), \(k=1\) and 2. The local Hölder condition (26) implies that
For inequalities, when \(k=1\), the absolute value inequality clearly holds. When \(k=2\), it can be obtained from the Cauchy-Schwartz inequality. Then for all point \(x_{0}\in {\Omega }_{0}\), the Eq. (28) holds.
1.4 The Proof of Theorem 4
From the condition \(\phi (x,x_{0})\le \alpha \left| u(x)- u(x_{0}) \right| + \varepsilon _{n}\), where \(\alpha > 0\) is a constant, and \(\varepsilon _{n}(x)= O(n^{-\frac{\beta }{2\beta + 2}})\), we know that
where \(k=1,2\). In the case of \(k=1\),
In the case of \(k=2\), as \((a+b)^2 \le 2a^2+2b^2\), the solution of the above equation is
Hence
Setting \({\tilde{\omega }}= \mathop {\arg \min }_{\omega }\tilde{{\mathcal {J}}}_{k,\phi }(\omega )\) and using (10) and (11), we have
So, from Lemma 1, we get
where \(k=1\) or 2.
From the proof of Theorem 3, it is easy to prove that the Eq. (30) holds for all the points on \({\Omega }_{0}\).
1.5 The Proof of Theorem 5
The case \(k=2\) is similar to [53], in this paper, we only prove the case \(k=1\). For simplicity, we shall assume that the kernel \(\kappa \) is rectangular; the proof in the general case can be carried out in the same way. Note that for the rectangular kernel we have \(\left\| v({\mathcal {N}}_{x,d}) - v({\mathcal {N}}_{x_{0},d}) \right\| _{1,\kappa } =\frac{1}{m}\left\| v({\mathcal {N}}_{x,d}) - v({\mathcal {N}}_{x_{0},d}) \right\| _{1}\), where m is the number of points in the similarity patch. Under the Hölder condition (26), for \(x\in {\mathcal {N}}_{x_{0},D}\) we have
Considering \( {\mathbb {E}}\left| \varepsilon (x)-\varepsilon (x_{0}) \right| =\mu \), we get
Because \(\frac{1}{2(\beta +1)^{2}}<\alpha <\frac{1}{2 \beta +2}\), \(n^{2(\alpha -\frac{1}{2\beta +2})}\rightarrow 0\) with \(n\rightarrow \infty \). Hence with high probability, we have
Taking into account that for \( \alpha \) satisfying \(\frac{1}{4 \beta +2} \le \alpha \le \frac{1}{2 \beta +2}\), it holds that \(2 \alpha \beta \ge 1 / 2-\alpha \), we have \(2\,L\eta ^{\beta }\le O(n^{-2\alpha \beta })\le O(n^{\alpha -\frac{1}{2}})=O(n^{-\frac{\beta }{2\beta +2}})\). Then with high probability, Eq. (A.25) becomes
This implies that with a high probability
Rights and permissions
Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.
About this article
Cite this article
Guo, Y., Wu, C., Zhao, Y. et al. The Optimal Weights of Non-local Means for Variance Stabilized Noise Removal. J Sci Comput 101, 28 (2024). https://doi.org/10.1007/s10915-024-02668-1
Received:
Revised:
Accepted:
Published:
DOI: https://doi.org/10.1007/s10915-024-02668-1