need code for Image processing for noise removal

조회 수: 2 (최근 30일)
Samia Ahmed
Samia Ahmed 2018년 4월 22일
편집: Walter Roberson 2018년 4월 22일
I need to remove the keep the spot in the middle and remove the bright element on the right and the other gray element on the left. Please help me. I used erosion and other filtering, couldn't come up correctly. Image size is 640x512 pixel
  댓글 수: 2
Samia Ahmed
Samia Ahmed 2018년 4월 22일
편집: Walter Roberson 2018년 4월 22일

here is the code. Please help me

I = imread ('image 6.jpg');
I2 = rgb2gray(I);
se1 = strel([0 1 1 0;  1 1 1 1;1 1 1 1; 0 1 1 0]);
se2 = ones(4,4)/16;
se3 = strel('disk', 10);
e = imerode(I2,se1);
fo = imopen(e, se3);
favg = filter2(fspecial('average',4),fo)/255;
fim = imfilter(favg, se2);
% fi2 = imfilter(e, se2);
% fi3 = imfilter(fi2, se2);
% fi4 = imfilter(fi3, se2);
% fi5 = medfilt2(fi4);
subplot (2, 2, 1); 
imshow (I); 
title ('Input'); 
subplot (2, 2, 2); 
imshow (e); 
title ('Erosion');
subplot (2, 2, 3); 
imshow (favg);
title ('Thresholding'); 
subplot (2, 2, 4); 
imshow (fim);
title ('Median Filter');

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Images에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by