[{"@context":"http:\/\/schema.org\/","@type":"BlogPosting","@id":"https:\/\/wiki.edu.vn\/en\/wiki7\/bilateral-filter-wikipedia\/#BlogPosting","mainEntityOfPage":"https:\/\/wiki.edu.vn\/en\/wiki7\/bilateral-filter-wikipedia\/","headline":"Bilateral filter – Wikipedia","name":"Bilateral filter – Wikipedia","description":"before-content-x4 From Wikipedia, the free encyclopedia Left: original image. Right: image processed with bilateral filter after-content-x4 A bilateral filter is","datePublished":"2016-09-02","dateModified":"2016-09-02","author":{"@type":"Person","@id":"https:\/\/wiki.edu.vn\/en\/wiki7\/author\/lordneo\/#Person","name":"lordneo","url":"https:\/\/wiki.edu.vn\/en\/wiki7\/author\/lordneo\/","image":{"@type":"ImageObject","@id":"https:\/\/secure.gravatar.com\/avatar\/c9645c498c9701c88b89b8537773dd7c?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/c9645c498c9701c88b89b8537773dd7c?s=96&d=mm&r=g","height":96,"width":96}},"publisher":{"@type":"Organization","name":"Enzyklop\u00e4die","logo":{"@type":"ImageObject","@id":"https:\/\/wiki.edu.vn\/wiki4\/wp-content\/uploads\/2023\/08\/download.jpg","url":"https:\/\/wiki.edu.vn\/wiki4\/wp-content\/uploads\/2023\/08\/download.jpg","width":600,"height":60}},"image":{"@type":"ImageObject","@id":"https:\/\/upload.wikimedia.org\/wikipedia\/commons\/thumb\/b\/b0\/Bilateral_Filter.jpg\/270px-Bilateral_Filter.jpg","url":"https:\/\/upload.wikimedia.org\/wikipedia\/commons\/thumb\/b\/b0\/Bilateral_Filter.jpg\/270px-Bilateral_Filter.jpg","height":"179","width":"270"},"url":"https:\/\/wiki.edu.vn\/en\/wiki7\/bilateral-filter-wikipedia\/","wordCount":6587,"articleBody":" (adsbygoogle = window.adsbygoogle || []).push({});before-content-x4From Wikipedia, the free encyclopedia Left: original image. Right: image processed with bilateral filter (adsbygoogle = window.adsbygoogle || []).push({});after-content-x4A bilateral filter is a non-linear, edge-preserving, and noise-reducing smoothing filter for images. It replaces the intensity of each pixel with a weighted average of intensity values from nearby pixels. This weight can be based on a Gaussian distribution. Crucially, the weights depend not only on Euclidean distance of pixels, but also on the radiometric differences (e.g., range differences, such as color intensity, depth distance, etc.). This preserves sharp edges. (adsbygoogle = window.adsbygoogle || []).push({});after-content-x4Table of ContentsDefinition[edit]Parameters[edit]Limitations[edit]Implementations[edit]Related models[edit]See also[edit]External links[edit]References[edit]Definition[edit]The bilateral filter is defined as[1][2] (adsbygoogle = window.adsbygoogle || []).push({});after-content-x4Ifiltered(x)=1Wp\u2211xi\u2208\u03a9I(xi)fr(\u2016I(xi)\u2212I(x)\u2016)gs(\u2016xi\u2212x\u2016),{displaystyle I^{text{filtered}}(x)={frac {1}{W_{p}}}sum _{x_{i}in Omega }I(x_{i})f_{r}(|I(x_{i})-I(x)|)g_{s}(|x_{i}-x|),}and normalization term, Wp{displaystyle {W_{p}}}, is defined asWp=\u2211xi\u2208\u03a9fr(\u2016I(xi)\u2212I(x)\u2016)gs(\u2016xi\u2212x\u2016){displaystyle W_{p}=sum _{x_{i}in Omega }{f_{r}(|I(x_{i})-I(x)|)g_{s}(|x_{i}-x|)}}whereIfiltered{displaystyle I^{text{filtered}}} is the filtered image;I{displaystyle I} is the original input image to be filtered;x{displaystyle x} are the coordinates of the current pixel to be filtered;\u03a9{displaystyle Omega } is the window centered in x{displaystyle x}, so xi\u2208\u03a9{displaystyle x_{i}in Omega } is another pixel;fr{displaystyle f_{r}} is the range kernel for smoothing differences in intensities (this function can be a Gaussian function);gs{displaystyle g_{s}} is the spatial (or domain) kernel for smoothing differences in coordinates (this function can be a Gaussian function).The weight Wp{displaystyle W_{p}} is assigned using the spatial closeness (using the spatial kernel gs{displaystyle g_{s}}) and the intensity difference (using the range kernel fr{displaystyle f_{r}}).[2] Consider a pixel located at (i,j){displaystyle (i,j)} that needs to be denoised in image using its neighbouring pixels and one of its neighbouring pixels is located at (k,l){displaystyle (k,l)}. Then, assuming the range and spatial kernels to be Gaussian kernels, the weight assigned for pixel (k,l){displaystyle (k,l)} to denoise the pixel (i,j){displaystyle (i,j)} is given byw(i,j,k,l)=exp\u2061(\u2212(i\u2212k)2+(j\u2212l)22\u03c3d2\u2212\u2016I(i,j)\u2212I(k,l)\u201622\u03c3r2),{displaystyle w(i,j,k,l)=exp left(-{frac {(i-k)^{2}+(j-l)^{2}}{2sigma _{d}^{2}}}-{frac {|I(i,j)-I(k,l)|^{2}}{2sigma _{r}^{2}}}right),}where \u03c3d and \u03c3r are smoothing parameters, and I(i, j) and I(k, l) are the intensity of pixels (i,j){displaystyle (i,j)} and (k,l){displaystyle (k,l)} respectively.After calculating the weights, normalize them:ID(i,j)=\u2211k,lI(k,l)w(i,j,k,l)\u2211k,lw(i,j,k,l),{displaystyle I_{D}(i,j)={frac {sum _{k,l}I(k,l)w(i,j,k,l)}{sum _{k,l}w(i,j,k,l)}},}where ID{displaystyle I_{D}} is the denoised intensity of pixel (i,j){displaystyle (i,j)}.Parameters[edit]As the range parameter \u03c3r increases, the bilateral filter gradually approaches Gaussian convolution more closely because the range Gaussian widens and flattens, which means that it becomes nearly constant over the intensity interval of the image.As the spatial parameter \u03c3d increases, the larger features get smoothened.Limitations[edit]The bilateral filter in its direct form can introduce several types of image artifacts:Staircase effect \u2013 intensity plateaus that lead to images appearing like cartoons[3]Gradient reversal \u2013 introduction of false edges in the image.[4]There exist several extensions to the filter that deal with these artifacts, like the scaled bilateral filter that uses downscaled image for computing the weights.[5] Alternative filters, like the guided filter,[6] have also been proposed as an efficient alternative without these limitations.Implementations[edit]Adobe Photoshop implements a bilateral filter in its surface blur tool. GIMP implements a bilateral filter in its Filters \u2192 Blur tools; and it is called Selective Gaussian Blur. The free G’MIC plugin Repair \u2192 Smooth [bilateral] for GIMP adds more control.[7]A simple trick to efficiently implement a bilateral filter is to exploit Poisson-disk subsampling.[1]Related models[edit]The bilateral filter has been shown to be an application of the short time kernel of the Beltrami flow[8][9][10] that was introduced as an edge preserving selective smoothing mechanism before the bilateral filter.Other edge-preserving smoothing filters include: anisotropic diffusion,[11] weighted least squares,[12] edge-avoiding wavelets,[13] geodesic editing,[14] guided filtering,[15] iterative guided filtering [16] and domain transforms.[17]See also[edit]External links[edit]Kaiming He: Guided image filtering (faster than bilateral filter and avoids staircasing and gradient reversal artifacts)Haarith Devarajan, Harold Nyikal, Bilateral Filters, in: Image Scaling and Bilateral Filtering 2006 courseSylvain Paris, Pierre Kornprobst, Jack Tumblin, Fr\u00e9do Durand, Bilateral Filtering: Theory and Applications, preprintSylvain Paris, Pierre Kornprobst, Jack Tumblin, Fr\u00e9do Durand, A Gentle Introduction to Bilateral Filtering and its Applications, SIGGRAPH 2008 classBen Weiss, Fast Median and Bilateral Filtering, SIGGRAPH 2006 preprintCarlo Tomasi, Roberto Manduchi, Bilateral Filtering for Gray and Color Images (shorter HTML version), proceedings of the ICCV 1998Qingxiong Yang, Kar-Han Tan, Narendra Ahuja, Real-Time O(1) Bilateral FilteringReferences[edit]^ a b Banterle, F.; Corsini, M.; Cignoni, P.; Scopigno, R. (2011). “A Low-Memory, Straightforward and Fast Bilateral Filter Through Subsampling in Spatial Domain”. Computer Graphics Forum. 31 (1): 19\u201332. doi:10.1111\/j.1467-8659.2011.02078.x. S2CID\u00a018288647.^ a b Tomasi, C; Manduchi, R (1998). Bilateral filtering for gray and color images (PDF). Sixth International Conference on Computer Vision. Bombay. pp.\u00a0839\u2013846. doi:10.1109\/ICCV.1998.710815.^ Kornprobst, Pierre (2007). “Limitations? – A Gentle Introductionto Bilateral Filteringand its Applications” (PDF). Retrieved 7 May 2017.^ He, Kaiming; Sun, Jian; Tang, Xiaoou. “Guided Image Filtering” (PDF). Retrieved 7 May 2017.^ Aswatha, Shashaank M.; Mukhopadhyay, Jayanta; Bhowmick, Partha (December 2011). “Image Denoising by Scaled Bilateral Filtering”. 2011 Third National Conference on Computer Vision, Pattern Recognition, Image Processing and Graphics: 122\u2013125. doi:10.1109\/NCVPRIPG.2011.33. ISBN\u00a0978-1-4577-2102-1. S2CID\u00a025738863.^ He, Kaiming. “Guided Image Filtering”. Retrieved 7 May 2017.^ “G’MIC – GREYC’s Magic for Image Computing: An Open and Full-Featured Framework for Image Processing”. gmic.eu. Archived from the original on 2014-12-27. ^ R. Kimmel, R. Malladi, and N. Sochen. Images as embedding maps and minimal surfaces: Movies, color, and volumetric medical images. IEEE CVPR’97, pp. 350-355, Puerto Rico, June 17\u201319, 1997. https:\/\/www.cs.technion.ac.il\/~ron\/PAPERS\/cvpr97.pdf^ R. Kimmel, R. Malladi, and N. Sochen. Images as Embedded Maps and Minimal Surfaces: Movies, Color, Texture, and Volumetric Medical Images. International Journal of Computer Vision, 39(2):111-129, Sept. 2000. https:\/\/www.cs.technion.ac.il\/~ron\/PAPERS\/KimMalSoc_IJCV2000.pdf^ N. Sochen, R. Kimmel, and A.M. Bruckstein. Diffusions and confusions in signal and image processing, Journal of Mathematical Imaging and Vision, 14(3):195-209, 2001.https:\/\/www.cs.technion.ac.il\/~ron\/PAPERS\/SocKimBru_JMIV2001.pdf^ Durand, Fr\u00e9do and Dorsey, Julie. “Fast Bilateral Filteringfor the Display of High-Dynamic-Range Images” In ACM Transactions on Graphics, Volume 21, Issue 3, pp 257\u2013266. https:\/\/people.csail.mit.edu\/fredo\/PUBLI\/Siggraph2002\/DurandBilateral.pdf^ Farbman, Zeev, Raanan Fattal, Dani Lischinski, and Richard Szeliski. “Edge-preserving decompositions for multi-scale tone and detail manipulation.” In ACM Transactions on Graphics, vol. 27, no. 3 (2008): 67. http:\/\/www.cs.huji.ac.il\/~danix\/epd\/^ Fattal, Raanan. “Edge-avoiding wavelets and their applications.” In ACM Transactions on Graphics vol. 28, no. 3 (2009): 22. http:\/\/www.cs.huji.ac.il\/~raananf\/projects\/eaw\/^ Criminisi, Antonio, Toby Sharp, Carsten Rother, and Patrick P\u00e9rez. “Geodesic image and video editing.” In ACM Transactions on Graphphics (TOG), vol. 29, no. 5 (2010): 134. http:\/\/research.microsoft.com\/apps\/pubs\/default.aspx?id=81528^ He, Kaiming, Jian Sun, and Xiaoou Tang. “Guided image filtering.” In Computer Vision\u2013ECCV 2010, pp. 1-14. Springer Berlin Heidelberg, 2010. http:\/\/kaiminghe.com\/eccv10\/index.html^ Tatar, Nurollah, et al. “High-Resolution Satellite Stereo Matching by Object-Based Semiglobal Matching and Iterative Guided Edge-Preserving Filter.” IEEE Geoscience and Remote Sensing Letters (2020): 1-5.^ Gastal, Eduardo S. L., and Manuel M. Oliveira. “Domain transform for edge-aware image and video processing.” In ACM Transactions on Graphics, vol. 30, no. 4 (2011): 69. http:\/\/inf.ufrgs.br\/~eslgastal\/DomainTransform\/ (adsbygoogle = window.adsbygoogle || []).push({});after-content-x4"},{"@context":"http:\/\/schema.org\/","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"item":{"@id":"https:\/\/wiki.edu.vn\/en\/wiki7\/#breadcrumbitem","name":"Enzyklop\u00e4die"}},{"@type":"ListItem","position":2,"item":{"@id":"https:\/\/wiki.edu.vn\/en\/wiki7\/bilateral-filter-wikipedia\/#breadcrumbitem","name":"Bilateral filter – Wikipedia"}}]}]