如何免费注册企业邮箱,谷歌seo排名工具,达内网站开发学习培训,企业网站开发韵茵内容#xff1a;matlab编程小波变换进行图像去噪处理#xff0c;包括各种软硬阈值的选取函数#xff0c;%小波阈值去噪clear allclc;fimread(graylena.bmp);fdouble(f);ssize(f);rimnoise2(gaussian,s(1),s(2),0,20);%填加高斯白噪声fnoisyfr;%对图像进行三层小波分解[c,s]w…内容matlab编程小波变换进行图像去噪处理包括各种软硬阈值的选取函数%小波阈值去噪clear allclc;fimread(graylena.bmp);fdouble(f);ssize(f);rimnoise2(gaussian,s(1),s(2),0,20);%填加高斯白噪声fnoisyfr;%对图像进行三层小波分解[c,s]wavedec2(fnoisy,3,db8);%cA3appcoef2(c,s,db8,3);[cH3,cV3,cD3]detcoef2(all,c,s,3);c3[cH3,cV3,cD3];[cH2,cV2,cD2]detcoef2(all,c,s,2);c2[cH2,cV2,cD2];[cH1,cV1,cD1]detcoef2(all,c,s,1);c1[cH1,cV1,cD1];%固定阈值(VisuShrink阈值)thrdelta*sqrt(2*log(n));deltamedian(abs(cD1(:)))/0.6745;thr1cdelta*thselect(c,minimaxi);%thr1cdelta*3.5;%thr1c3delta*thselect(c3,sqtwolog);%thr1c2delta*thselect(c2,sqtwolog);%thr1c1delta*thselect(c1,sqtwolog);n[1 2 3];p[thr1c thr1c thr1c];dnc0wthcoef2(h,c,s,n,p,s);dnc0wthcoef2(v,dnc0,s,n,p,s);dnc0wthcoef2(d,dnc0,s,n,p,s);dnf0waverec2(dnc0,s,db8);%基于Stein的无偏似然估计原理的自适应阈值(SUREShrink阈值)%thr1cA3thselect(cA3,rigrsure);%thr1surethr(c,delta);%最优预测变量阈值%极大极小阈值thr0.39360.1829*(log(n)/log(2));%figure,subplot(221),imshow(dnf0,[]), (VisuShrink阈值)origifcacupsnr(fnoisy,f)%VSf0cacupsnr(dnf0,f)figure,subplot(121),imshow(f,[]), (原始图像)subplot(122),imshow(fnoisy,[]), (加噪图像)dnc1wthresfunc(c,s,hard,thr1c);dnf1waverec2(dnc1,s,db8);figure,subplot(221),imshow(dnf1,[]), (硬阈值函数)VSf1cacupsnr(dnf1,f)dnc2wthresfunc(c,s,soft,thr1c);dnf2waverec2(dnc2,s,db8);subplot(222),imshow(dnf2,[]), (软阈值函数)VSf2cacupsnr(dnf2,f)dnc3wthresfunc(c,s,semisoft,thr1c);dnf3waverec2(dnc3,s,db8);subplot(224),imshow(dnf3,[]), (折中阈值函数)VSf3cacupsnr(dnf3,f)dnc4wthresfunc(c,s,halfsoft,thr1c);dnf4waverec2(dnc4,s,db8);subplot(223),imshow(dnf4,[]), (半软阈值函数)VSf4cacupsnr(dnf4,f)dnc1wthresfunc(c,s,upsoft,thr1c);dnf1waverec2(dnc1,s,db8);figure,subplot(221),imshow(dnf1,[]), (改进软阈值函数)VSf1cacupsnr(dnf1,f)dnc2wthresfunc(c,s,hfsmsoft,thr1c);dnf2waverec2(dnc2,s,db8);subplot(222),imshow(dnf2,[]), (新阈值函数)VSf2cacupsnr(dnf2,f)dnc3wthresfunc(c,s,newthr1,thr1c);dnf3waverec2(dnc3,s,db8);subplot(223),imshow(dnf3,[]), (改进阈值函数一)VSf3cacupsnr(dnf3,f)dnc4wthresfunc(c,s,newthr2,thr1c);dnf4waverec2(dnc4,s,db8);subplot(224),imshow(dnf4,[]), (改进阈值函数二)VSf4cacupsnr(dnf4,f)