欢迎来到装配图网! | 帮助中心 装配图网zhuangpeitu.com!
装配图网
ImageVerifierCode 换一换
首页 装配图网 > 资源分类 > DOC文档下载
 

matlab对图片加入噪声

  • 资源ID:108664759       资源大小:884.50KB        全文页数:24页
  • 资源格式: DOC        下载积分:10积分
快捷下载 游客一键下载
会员登录下载
微信登录下载
三方登录下载: 微信开放平台登录 支付宝登录   QQ登录   微博登录  
二维码
微信扫一扫登录
下载资源需要10积分
邮箱/手机:
温馨提示:
用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)
支付方式: 支付宝    微信支付   
验证码:   换一换

 
账号:
密码:
验证码:   换一换
  忘记密码?
    
友情提示
2、PDF文件下载后,可能会被浏览器默认打开,此种情况可以点击浏览器菜单,保存网页到桌面,就可以正常下载了。
3、本站不支持迅雷下载,请使用电脑自带的IE浏览器,或者360浏览器、谷歌浏览器下载即可。
4、本站资源下载后的文档和图纸-无水印,预览文档经过压缩,下载后原文更清晰。
5、试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。

matlab对图片加入噪声

Four short words sum up what has lifted most successful individuals above the crowd: a little bit more.-author-datematlab对图片加入噪声matlab对图片加入噪声图片去噪:对一幅图像加入不同的噪声(随机点噪声、椒盐噪声等),选取不同的方法去噪,比如说邻域平均、中值滤波、图像迭加等,比较对于不同的噪声,不同的方法哪种更好。A加入随机点噪声进行邻域平均、中值滤波、图像迭加邻域平均>> I=imread('D:gem.bmp');>> snoise=0.1*randn(size(I);>> J1=imadd(I,im2uint8(snoise); % 受随机噪声干扰>> M4=0 1 0; 1 0 1; 0 1 0;>> M4=M4/4; % 4邻域平均滤波>> I_filter1=filter2(M4,J1);>> M8=1 1 1; 1 0 1; 1 1 1; % 8邻域平均滤波>> M8=M8/8;>> I_filter2=filter2(M8,J1);>> subplot(2,2,1),imshow(I);title('原始图像 Gem');>> subplot(2,2,2),imshow(J1);title('加随机噪声后图像');>> subplot(2,2,3),imshow(I_filter1,map);title('4邻域平均滤波');>> subplot(2,2,4),imshow(I_filter2,map);title('8邻域平均滤波');均值滤波>> G=imread('D:gem.bmp');>> I=rgb2gray(G);>> snoise=0.1*randn(size(I);>> A=imadd(I,im2uint8(snoise);>> B1=filter2(fspecial('average',3),A)/255;>> B2=filter2(fspecial('average',5),A)/255;>> B3=filter2(fspecial('average',10),A)/255;>> subplot(2,2,1),imshow(A);title('加随机噪声后图像');>> subplot(2,2,2),imshow(B1);title('平均3后图像');>> subplot(2,2,3),imshow(B2);title('平均5后图像');>> subplot(2,2,4),imshow(B3);title('平均10后图像'); 原图B .加入椒盐噪声进行邻域平均、中值滤波、图像迭加邻域平均>>I=imread('moon.tif');>>J=imnoise(I,'salt & pepper',0.02); >>subplot(1,2,1),imshow(I);title('原图');>>subplot(1,2,2),imshow(J);title('加噪');>>K1=filter2(fspecial('average',7),J);>>K2=filter2(fspecial('average',9),J);>>figure,subplot(1,2,1),imshow(uint8(K1);title('3x3');>> subplot(1,2,2),imshow(uint8(K1);title('5x5')>>subplot(1,2,1),imshow(uint8(K1);title('7x7');>>subplot(1,2,2),imshow(uint8(K1);title('9x9')中值滤波>>I=imread('moon.tif');>>J=imnoise(I,'salt & pepper',0.02);>>K1=medfilt2(J);>> K2=medfilt2(J,5 5);>> K3=medfilt2(J,7 7);>>K4=medfilt2(J,9 9);>> subplot(1,2,1),imshow(K1);title('3x3');>> subplot(1,2,2),imshow(K2);title('5x5');>>subplot(1,2,1),imshow(K3);title('7x7');>>subplot(1,2,2),imshow(K4);title('9x9');C.加入高斯噪声进行邻域平均、中值滤波、图像迭加邻域平均>> G=imread('D:gem.bmp');>> I=rgb2gray(G);>> J1=imnoise(I,'gaussian',0,0.02); % 受高斯噪声干扰>> M4=0 1 0; 1 0 1; 0 1 0;>> M4=M4/4; % 4邻域平均滤波>> I_filter1=filter2(M4,J1);>> M8=1 1 1; 1 0 1; 1 1 1; % 8邻域平均滤波>> M8=M8/8;>> I_filter2=filter2(M8,J1);>> subplot(2,2,1),imshow(I);title('原始图像 Gem');>> subplot(2,2,2),imshow(J1);title('加高斯噪声后图像');>> subplot(2,2,3),imshow(I_filter1,map);title('4邻域平均滤波');>> subplot(2,2,4),imshow(I_filter2,map);title('8邻域平均滤波');>> subplot(2,2,3),imshow(B2);title('平均5后图像');>> subplot(2,2,4),imshow(B3);title('平均7后图像');均值滤波>> I=imread('D:gem.bmp');>> A=imnoise(I,'gaussian',0.01);>> B1=filter2(fspecial('average',3),A)/255;>> B2=filter2(fspecial('average',5),A)/255;>> B3=filter2(fspecial('average',7),A)/255;>> subplot(2,2,1),imshow(A);title('加高斯噪声后图像');>> subplot(2,2,2),imshow(B1);title('平均3后图像');>> subplot(2,2,3),imshow(B2);title('平均5后图像');>> subplot(2,2,4),imshow(B3);title('平均7后图像');D.图像迭加滤波 >>I=imread('pout.tif');>> m n=size(I);>>J1(m,n)=0;J2(m,n)=0;J3(m,n)=0;>>for i=1:10 temp=imnoise(I,'gaussian',0,0.01); J1=J1+double(temp)/10;end>>for i=1:20 temp=imnoise(I,'gaussian',0,0.01); J2=J2+double(temp)/20;end>>for i=1:50 temp=imnoise(I,'gaussian',0,0.01); J3=J3+double(temp)/50;end>>figure;subplot(2,2,1),imshow(I),title('原图象');>>subplot(2,2,2),imshow(mat2gray(J1),title('10次迭加滤波');>>subplot(2,2,3),imshow(mat2gray(J2),title('20次迭加滤波');>>subplot(2,2,4),imshow(mat2gray(J3),title('50次迭加滤波')-

注意事项

本文(matlab对图片加入噪声)为本站会员(痛***)主动上传,装配图网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知装配图网(点击联系客服),我们立即给予删除!

温馨提示:如果因为网速或其他原因下载失败请重新下载,重复下载不扣分。




关于我们 - 网站声明 - 网站地图 - 资源地图 - 友情链接 - 网站客服 - 联系我们

copyright@ 2023-2025  zhuangpeitu.com 装配图网版权所有   联系电话:18123376007

备案号:ICP2024067431-1 川公网安备51140202000466号


本站为文档C2C交易模式,即用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。装配图网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知装配图网,我们立即给予删除!