I am applying a median filter to a noisy image and them subplot them for comparison. It works fine, except that there's a dark block on the top left corner of my image. When I zoom in further, I see a face of a boy.
Here's an uploaded screenshot and the zoomed image:
Is this some Halloween prank? Has anyone encountered this? How can I remove it?
Here's my code:
dirty = importdata('dirtytabur.jpg');if size(dirty,3) == 3 dirty = rgb2gray(dirty);endfiltered = medfilt2(dirty);% display image
scrsz = get(0, 'ScreenSize');figure('Position', [1 1 scrsz(3) scrsz(4)]);subplot(1,2,1); imshow(dirty);title('Before Processing'); axis equal;axis tight;subplot(1,2,2); imshow(filtered);title('After Processing'); axis equal;axis tight;% figure(filtered);
imwrite(image,[filename '.jpg'], 'jpg');
Thanks, Yu Ang
Best Answer