Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

Q.

Reduce the noise level in the X-ray


image of a circuit board (Fig0335(a)
(ckt_board_saltpep_prob_pt05)) corrupted by
salt-and-pepper noise. (a)3 X 3 averaging mask
(b)3 X 3 median filter
clc
clear all
close all
I = imread('Fig0335(a)(ckt_board_saltpep_prob_pt05).tif');
subplot(1,3,1);
imshow(I);
title('Xray image of a circuit board');
avgmask = imBoxFilter(I,3) ;
medianfilt = medfilt2(I,[3,3]);
subplot(1,3,2);
imshow(avgmask);
title('Averaging filter ')
subplot(1,3,3);
imshow(medianfilt);
title('Median filter');

1
Published with MATLAB® R2014a

You might also like