compare_nla.m
来自「脊波工具和相关实验以及有关实验数据」· M 代码 · 共 48 行
M
48 行
% Compare NLA between FRIT and WAVE2% Object image of size 257x257im = imread('obj.png'); im = double(im) / 256;% Parameterswname = 'sym4';nlevs = 8;ncoefs = 2.^[5:8];% FRIT frit_im = frit_nla(im, wname, ncoefs); % WAVE2wave_im = wave2_nla(im(1:end-1,1:end-1), wname, nlevs, ncoefs);% range = [0, 1];range = [-0.5, 1];for k = 1:length(ncoefs) % WAVE2 figure(1), clf; set(gcf, 'Name', 'DWT2') colormap('gray'); imagesc(wave_im{k}, range); axis image, axis off, title(sprintf('%d coefficients (SNR = %0.2f dB)', ... ncoefs(k), SNR(im(1:end-1,1:end-1), wave_im{k}))); % FRIT figure(2), clf; set(gcf, 'Name', 'FRIT') colormap('gray'); imagesc(frit_im{k}, range); axis image, axis off, title(sprintf('%d coefficients (SNR = %0.2f dB)', ... ncoefs(k), SNR(im, frit_im{k}))); disp('Hit any key to continue'); pauseend
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?