diff options
author | Daniil Kazantsev <dkazanc@hotmail.com> | 2019-03-16 23:39:29 +0000 |
---|---|---|
committer | Daniil Kazantsev <dkazanc@hotmail.com> | 2019-03-16 23:39:29 +0000 |
commit | 9633c5d701c164c3ff8f4d870624f87744d186bd (patch) | |
tree | 23fd9a110436318aa55cbb46a6f86824940b5478 /demos/demoMatlab_denoise.m | |
parent | 1740fb91c1842dc174492857fad88c03420f74eb (diff) | |
download | regularization-9633c5d701c164c3ff8f4d870624f87744d186bd.tar.gz regularization-9633c5d701c164c3ff8f4d870624f87744d186bd.tar.bz2 regularization-9633c5d701c164c3ff8f4d870624f87744d186bd.tar.xz regularization-9633c5d701c164c3ff8f4d870624f87744d186bd.zip |
matlab demos updated
Diffstat (limited to 'demos/demoMatlab_denoise.m')
-rw-r--r-- | demos/demoMatlab_denoise.m | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/demos/demoMatlab_denoise.m b/demos/demoMatlab_denoise.m index 377a447..9d89138 100644 --- a/demos/demoMatlab_denoise.m +++ b/demos/demoMatlab_denoise.m @@ -83,17 +83,18 @@ fprintf('Denoise using the TGV model (CPU) \n'); lambda_TGV = 0.035; % regularisation parameter alpha1 = 1.0; % parameter to control the first-order term alpha0 = 2.0; % parameter to control the second-order term -iter_TGV = 20; % number of Primal-Dual iterations for TGV +L2 = 12.0; % convergence parameter +iter_TGV = 1200; % number of Primal-Dual iterations for TGV epsil_tol = 0.0; % tolerance -tic; [u_tgv,infovec] = TGV(single(u0), lambda_TGV, alpha1, alpha0, iter_TGV, epsil_tol); toc; +tic; [u_tgv,infovec] = TGV(single(u0), lambda_TGV, alpha1, alpha0, iter_TGV, L2, epsil_tol); toc; +figure; imshow(u_tgv, [0 1]); title('TGV denoised image (CPU)'); rmseTGV = (RMSE(u_tgv(:),Im(:))); fprintf('%s %f \n', 'RMSE error for TGV is:', rmseTGV); [ssimval] = ssim(u_tgv*255,single(Im)*255); fprintf('%s %f \n', 'MSSIM error for TGV is:', ssimval); -figure; imshow(u_tgv, [0 1]); title('TGV denoised image (CPU)'); %% % fprintf('Denoise using the TGV model (GPU) \n'); -% tic; u_tgv_gpu = TGV_GPU(single(u0), lambda_TGV, alpha1, alpha0, iter_TGV, epsil_tol); toc; +% tic; u_tgv_gpu = TGV_GPU(single(u0), lambda_TGV, alpha1, alpha0, iter_TGV, L2, epsil_tol); toc; % figure; imshow(u_tgv_gpu, [0 1]); title('TGV denoised image (GPU)'); %% fprintf('Denoise using the ROF-LLT model (CPU) \n'); |