perform_tv_correction.m

来自「image denoising toolbox in matlab」· M 代码 · 共 42 行

M
42
字号
function y = perform_tv_correction(x,T)% perform_tv_correction - perform correction of the image to that it minimizes the TV norm.%%   y = perform_tv_correction(x,T);%%   Perform correction using thresholding of haar wavelet coefficients on 1%   scale.%%   Copyright (c) 2006 Gabriel Peyren = size(x,1);Jmin = log2(n)-1;% do haar transformoptions.wavelet_type = 'daubechies';options.wavelet_vm = 1;y = perform_atrou_transform(x,Jmin,options);% perform soft thesholdingy = perform_soft_tresholding(y,T);% do reconstructiony = perform_atrou_transform(y,Jmin,options);%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%function y = perform_soft_tresholding(x,t)if iscell(x)    for i=1:length(x)        y{i} = perform_soft_tresholding(x{i},t);    end    return;ends = abs(x) - t;s = (s + abs(s))/2;y = sign(x).*s;

⌨️ 快捷键说明

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