440 likes | 598 Views
An Edge-preserving Filtering Framework for Visibility Restoration. Linchao Bao, Yibing Song, Qingxiong Yang (City University of Hong Kong) and Narendra Ahuja (University of Illinois at Urbana-Champaign). Contents. Proposed Edge-preserving Filtering Framework
E N D
An Edge-preserving Filtering Framework for Visibility Restoration Linchao Bao, Yibing Song, Qingxiong Yang (City University of Hong Kong) and NarendraAhuja(University of Illinois at Urbana-Champaign)
Contents • Proposed Edge-preserving Filtering Framework • Application on Dehazing
From Gaussian to Bilateral • Gaussian filtering • p, q: pixel location • Ω: the neighborhood of pixel p • Gσ: Gaussian function p q
From Gaussian to Bilateral • Bilateral filtering • Gσ_s ,Gσ_r: Gaussian function • Wp: Weight normalization factor p q [Tomasi and Manduchi ICCV’98]
Edge-preserving Filtering Applications • Detail enhancement [Farbmanet al. 08] • HDR tone mapping [Durand and Dorsey 02] • Image abstraction/stylization [Winnemoller et al. 06] • Joint filtering (upsampling, colorization) [Kopf et al. 07] • Photo-look transferring [Bae et al. 06] • Video enhancement [Bennett and McMillan 05] • Haze removal (Dehazing) [Tarel and Hautiere 09] • Shadow Removal [Yang et al. 12]
Bilateral Filtering σr 0.1 0.2 0.4 0.01 σs 0.05 0.1
σr 0.1 0.2 0.4 σs 0.01 0.05 0.1
Bilateral Filtering Smaller σr Larger σr Edge blurred Not smoothed
Our Filtering Framework Our bilateral filtered
Idea Find the optimal filtered value for each pixel, such that Weighting function Cost function • Ω: The neighboring pixels ofp • Perform aggregations on costs of neighboring pixels w.r.t. different x values, and then select the optimal x* as the output filtered value! • Reminder: Gaussian and bilateral filter are just aggregations using different weighting functions!
First example Neighborhood of p p Where is x*? q
First example Neighborhood of p p Where is x*? q
First example Neighborhood of p α= 2.0 x* q
First example Neighborhood of p α= 2.0 α= 1.0 x* x* q
First example Neighborhood of p α= 2.0 α= 1.0 α= 0.5 x* x* x* q
First example Box filter (Mean filter) α= 2.0 α= 1.0 Median filter α= 0.5 ?
Our Framework Find the optimal filtered value for each pixel, such that Weighting function Cost function ( can be anylocal-neighborhood-aggregation-based filter)
Specific Form (power cost function) • Box filter • Gaussian filter • Bilateral filter • Guided filter • … α= 2.0 Original filter α< 2.0 Edge-preserving can be
Examples Gaussian filtered Input
Examples Ƒ is Gaussian filter, α= 0.5 Input
Examples Bilateral filtered Input
Examples Ƒ is bilateral filter, α= 0.5 Input
Examples Ƒ is bilateral filter, α= 0.5 Original bilateral filter
Edge-preserving Filtering Applications • Detail enhancement [Farbmanet al. 08] • HDR tone mapping [Durand and Dorsey 02] • Image abstraction/stylization [Winnemoller et al. 06] • Joint filtering (upsampling, colorization) [Kopf et al. 07] • Photo-look transferring [Bae et al. 06] • Video enhancement [Bennett and McMillan 05] • Haze removal (Dehazing) [Tarel and Hautiere 09] • Shadow Removal [Yang et al. 12]
Haze Removal (Dehazing) The widely adopted model [Narasimhan and Nayar 02] Atmospheric light (global constant) Transmission map (haze attenuation) Haze image (input) Dehazed image (desired result)
Haze Removal (Dehazing) The widely adopted model [Narasimhan and Nayar 02] • First estimate A and transmission map t • Ill-posed – additional assumption/prior needed • Dark channel prior [He et al. 09] => Rough estimate of • Smoothness [Fattal08] [Tan et al. 08] • White balanced input image [Tarel and Hautiere 09] => A = (1, 1, 1) • We prefer fast filtering-based method [Tarel and Hautiere 09]
Filtering-based Method [Tarel and Hautiere 09] Haze image I (input)
Filtering-based Method [Tarel and Hautiere 09] 1) 2) 3) 4) J
Filtering-based Method [Tarel and Hautiere 09] 1) 2) 3) 4)
Edge-preserving Filtering W Bilateral filtered Median filtered (Tarel’s method)
Edge-preserving Filtering W Bilateral filtered Ours (F is BLF, α=1) Median filtered (Tarel’s method)
Replace the filtering step 1) 2) 3) 4)
Replace the filtering step 1) 2) 3) 4)
Result Input Our result (0.78 sec 1-megapixel@CPU) Tarel’s method (0.35 sec 1-megapixel@CPU)
Thank you! Presented by Linchao Bao (@ City University of Hong Kong)
Implementation • Straightforward implementation: FUNCTION J = OurFilteringFramework(I, F, α) init output image J; init image MinMap with maximum cost value; FOREACHoutput candidate value x, calculate intermediate image Ȋ=|x-I|^α; obtain M by filteringȊ using F; FOREACH pixel p, if M(p)<MinMap(p) then MinMap(p)=M(p), J(p)=x; ENDFOR ENDFOR ENDFUNC
Fast Algorithm • Fast approximation algorithm: (see paper for details) • Do not filter for each candidate x value • Sampling and interpolation: • Assume local pixels are similar, then for each pixel p, filtered follows curve , and • Filter at N sampling intensity levels, then use three x values and their costs to calculate x* using the above curve (choose three points near the bottom of the curve) • Experiments show that can usually generate good results • N>=16 can generally produce high-quality results (PSNR>40dB)