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

📄 nearneighbors.m

📁 Nearest neighbors is a semi deconvolution algorithm. I m a newbie in matlab but I hope this helps so
💻 M
字号:
function k = nearneigh(filename1, filename2, filename3, weight, sigma)

%      Nearest is a function that given three images as input, it will blur 
%      a copy of two of them using a gaussian function with parameters
%      determined by the user - radius and sigma - and then subtract both 
%      of them to the original (first) image, by a weighting variable,
%      composing a shapened image.
%
%      NEAREST('filename.xxx', 'filename+1.xxx', 'filename-1.xxx', weight, 
%               radius, sigma) 
%      


fname_temp = imresize(imread(filename1), 0.35);
fname = 255 - fname_temp; 
temp1 = blur(filename2, sigma); 
temp2 = blur(filename3, sigma); 
z1 = 255 - (fname - weight*temp1);
k = z1 - weight*temp2;

⌨️ 快捷键说明

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