lookup.m

来自「这个MATLAB程序是用于对音频信号进行降噪处理」· M 代码 · 共 27 行

M
27
字号
function H = lookup(GT,x,y,z)
% LOOKUP - STSA gain determination using table lookup interpolation
%
% This function should just take the input parameters of interest (m,
% xihat, gamma) and the table in question, and sort the rest out.

% Author: Patrick J. Wolfe
%         Signal Processing Group
%         Cambridge University Engineering Department
%         p.wolfe@ieee.org
%
% Copyright (c) 2000 by Patrick J. Wolfe
% $Revision: 1.2 $  $Date: 2001/01/24 13:09:01 $

% Confine gamma and xihat to within table bounds
%
xmax = min(GT.x(1,end,1)); xmin = max(GT.x(1,1,1));
ymax = min(GT.y(end,1,1)); ymin = max(GT.x(1,1,1));
zmax = min(GT.z(1,1,end)); zmin = max(GT.z(1,1,1));
x = limiter(xmin,xmax,x);
y = limiter(ymin,ymax,y);
z = limiter(zmin,zmax,z);

% Look up values in gain table (note strange x,y,z ordering)
%
H = interp3(GT.x,GT.y,GT.z,GT.gain_table,z,y,x,GT.method);

⌨️ 快捷键说明

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