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

📄 gfcreatefilterf.m

📁 gaobor滤波工具 先转到频域再转回时域
💻 M
字号:
%GFCREATEFILTERF Create normalized 1-D Gabor filter in the frequency domain.%%   [G] = GFCREATEFILTERF(F0,GAMMA,N,...) creates a normalized Gabor%   filter G of size N with central frequency F0, normalized width GAMMA.%%   G = GFCREATEFILTER(...,'PF',PF) determines that at least%   P percent of the Gaussian envelope of the filter must be%   included in the filter in frequency domain. For default,%   PF=0.998. %%   G = GFCREATEFILTER(...,'PT',PT) determines that at least%   P percent of the Gaussian envelope of the filter must be%   included in the filter in time domain. For default,%   PT=0.998. %%   Examples%%   See also GFCREATEFILTER, GFCHECKFILTER.%% References:%   [1] Kamarainen, J.-K., Kyrki, V., Kalviainen, H., Gabor%       Features for Invariant Object Recognition, Research%       report 79, Department of Information Technology,%       Lappeenranta University of Technology %% Author(s):%    Joni Kamarainen <Joni.Kamarainen@lut.fi>%    Ville Kyrki <Ville.Kyrki@lut.fi>%% Copyright:%%   The Gabor Features in Signal and Image Processing Toolbox is%   Copyright (C) 2000 by Joni Kamarainen and Ville Kyrki.%function [g]=gfcreatefilterf(f0,gamma,N,varargin)%% Setting default valuesalpha = f0/gamma;PT = 0.998;PF = 0.998;%% Parameter parsingcurrentarg = 1;while (length(varargin) > currentarg)  [param,value]=deal(varargin{currentarg:currentarg+1});  switch lower(param)   case 'pt'    PT = value;   case 'pf'    PF = value;   otherwise    error(['Unknown parameter ''' param '''.']);  end;  currentarg=currentarg+2;end;% Check filter constraintsgfcheckfilter(f0,gamma,N,PT,PF);% Creating the bankn = -N:1:N;nyqf = 0.5; % Nyquist frequency u = n/N; % frequencies that bank contains% Create filter valuesg = zeros(1,N);gf = exp(-(pi^2/alpha^2)*(u-f0).^2); g = gf((N+1):(2*N)); % frequencies from 0 to (N-1)/Ng = g+gf(1:N); % aliased frequencies

⌨️ 快捷键说明

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