noise removal by setting a threshold
Ältere Kommentare anzeigen
I have a RGB image ,i have to remove noise in it by setting a theshold value please help
Akzeptierte Antwort
Weitere Antworten (1)
Wayne King
am 22 Dez. 2012
Bearbeitet: Wayne King
am 22 Dez. 2012
What do you mean by remove noise by setting a threshold. Normally, in a noisy image model, the value at a particular pixel is assumed to be signal plus noise. To simply set the threshold in the image domain, would therefore remove signal. The usual practice for denoising images is to threshold in a different representation of the image (wavelet domain or frequency domain), then invert the thresholded values. For example, if you have the Wavelet Toolbox, you can denoise an RGB image by obtaining the 2-D wavelet transform, thresholding the wavelet coefficients and inverting.
Below is an example with an image which isn't noisy but the general process is illustrated. There are utilities in the Wavelet Toolbox fo determing "optimal" thresholds.
X = imread('arms.jpg');
wname = 'sym4';
level = 4;
sorh = 's'; % Specified soft or hard thresholding
thrSettings = [...
4.658112694014694 4.374202852603576 4.092379407660262 3.815939516130920 ; ...
4.658112694014694 4.374202852603576 4.092379407660262 3.815939516130920 ; ...
4.658112694014694 4.374202852603576 4.092379407660262 3.815939516130920 ...
];
roundFLAG = true;
[coefs,sizes] = wavedec2(X,level,wname);
[XDEN,cfsDEN,dimCFS] = wdencmp('lvd',coefs,sizes, ...
wname,level,thrSettings,sorh);
if roundFLAG , XDEN = round(XDEN); end
if isequal(class(X),'uint8') , XDEN = uint8(XDEN); end
2 Kommentare
Era Islam
am 25 Mai 2018
Sir, can you please send me the full code with explanation? I really need this
Wehad Alshehri
am 17 Feb. 2020
Can you send it to me please?
Kategorien
Mehr zu Adaptive Filters finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!