⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dfbdecdemo.m

📁 This toolbox contains Matlab files that implement the nonsubsample contourlet transform and its util
💻 M
字号:
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Image decomposition by nonsubsampled contourlet transform (NSSC).% This is the iterated filter bank that computes the nonsubsampled% contourlet transform.  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Parameteters:nlevels = 4 ;        % Decomposition level%pfilter = 'pkva' ;              % Pyramidal filterdfilter = 'dmaxflat7'; %'cd' ;              % Directional filter% Nonsubsampled Contourlet decompositioncoeffs = nssdfbdec( double(im), dfilter, nlevels );disp( nlevels); disp(dfilter);% Display the coefficients%disp('Displaying the contourlet coefficients...') ;%shownssc( coeffs ) ;%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Nonsubsampled Contourlet transform (NSSC) reconstruction.% This is the inverse of nsscdec, i.e.% imrec = nsscrec(coeffs, dfilter, pfilter);% would reconstruct imrec = im%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Reconstruct imageimrec = nssdfbrec( coeffs, dfilter ) ;% Show the reconstruction image and the original imageif 0figure;subplot(1,2,1), imagesc( im, [0, 255] ); title('Original image' ) ;colormap(gray);axis image off;subplot(1,2,2), imagesc( imrec, [0, 255] );title('Reconstructed image' ) ;colormap(gray);axis image off;endmse = sum( sum( (imrec - double(im)).^2 ) );mse = mse / prod(size(im));disp( sprintf('The mean square error is: %f', mse ) );disp(' ');

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -