I am looking for a good example that showing the different between Guided and Gaussian Filters. The example need to show the benefit of Guided filter, (for example: preserving edge...). Could you give me some example for that task? Thanks in advance
I tried some example, but it did not show benefit of Guided comparison with Gaussian
% example: edge-preserving smoothing % figure 1 in our paper close all; I = double(imread('.\img_smoothing\cat.bmp')) / 255; I = imnoise(I,'gaussian',0.1,0); p = I; r = 4; % try r=2, 4, or 8 eps = 0.2^2; % try eps=0.1^2, 0.2^2, 0.4^2 q = guidedfilter(I, p, r, eps); std_Gb=1; beta=0.1; %% Initialization Ng=ceil(3*std_Gb)+1; Gaussian = fspecial('gaussian',[Ng Ng],std_Gb); imsm = conv2(I,Gaussian,'same'); [Gx,Gy] = gradient(q ); NormGrad = sqrt(Gx.^2 + Gy.^2); Gb1 = 1./ (1 + 1* NormGrad.^2); [Gx,Gy] = gradient(imsm); NormGrad = sqrt(Gx.^2 + Gy.^2); Gb2= 1./ (1 + 1* NormGrad.^2); figure(); subplot(2,1,1);imshow([I, q,imsm],[]); subplot(2,1,2);imshow([Gb1,Gb2],[]); 





