全局阈值:
>> load woman
>> subplot(221);image(X);
>> colormap(map);
>> title('原始图像')
>> axis square
>> init=2055615866;rand('seed',init);
>> x1=X+38*rand(size(X));
>> subplot(222);image(x1);colormap(map);
>> axis square
>> [thr,sorh,keepapp]=ddencmp('den','wv',x1);
>> xd=wdencmp('gbl',x1,'sym4',2,thr,sorh,keepapp);
>> subplot(224);image(xd);colormap(map);
>> title('消噪图像')
>> axis square
>> err1=norm(xd-X)
err1 =
2.0680e+003
load woman
subplot(221);image(X);
colormap(map);
评论17