发布网友 发布时间:2022-04-23 15:26
共1个回答
热心网友 时间:2023-10-09 08:00
由于没有指明降低噪声类型,就以椒盐噪声为例
I = imread('cameraman.tif');
J = imnoise(I,'salt & pepper',0.02);
subplot(1,3,1), imshow(I),title(' 原始图像')
subplot(1,3,2), imshow(J),title(' 噪声图像')
H = fspecial('average',[5 5]);
Blur = imfilter(J,H,'replicate');
subplot(1,3,3),imshow(Blur);title(' 平滑后图像')