Jump to content

Gabor filter: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
Raucanum (talk | contribs)
No edit summary
Line 53: Line 53:
*{{cite web |url=http://matlabserver.cs.rug.nl |title=Online Gabor filter demo |accessdate=2009-05-25}}
*{{cite web |url=http://matlabserver.cs.rug.nl |title=Online Gabor filter demo |accessdate=2009-05-25}}
*{{cite web |url=http://mplab.ucsd.edu/tutorials/gabor.pdf |title=Tutorial on Gabor Filters |last=Movellan |first=Javier R. |accessdate=2008-05-14}}
*{{cite web |url=http://mplab.ucsd.edu/tutorials/gabor.pdf |title=Tutorial on Gabor Filters |last=Movellan |first=Javier R. |accessdate=2008-05-14}}
*{{cite web |url=http://www.cs.kuleuven.be/~graphics/publications/LLDD09PNSGC/ |title=Procedural Noise using Sparse Gabor Convolution |accessdate=2009-09-12}}


[[Category:Linear filters]]
[[Category:Linear filters]]

Revision as of 22:29, 12 September 2009

Example of a two-dimensional Gabor filter

A Gabor filter is a linear filter whose impulse response is defined by a harmonic function multiplied by a Gaussian function. Because of the multiplication-convolution property (Convolution theorem), the Fourier transform of a Gabor filter's impulse response is the convolution of the Fourier transform of the harmonic function and the Fourier transform of the Gaussian function.

where

and

In this equation, represents the wavelength of the cosine factor, represents the orientation of the normal to the parallel stripes of a Gabor function, is the phase offset, is the sigma of the Gaussian envelope and is the spatial aspect ratio, and specifies the ellipticity of the support of the Gabor function.

Wavelet space

Gabor filters are directly related to Gabor wavelets, since they can be designed for number of dilations and rotations. However, in general, expansion is not applied for Gabor wavelets, since this requires computation of biorthogonal wavelets, which may be very time-consuming. Therefore, usually, a filter bank consisting of Gabor filters with various scales and rotations is created. The filters are convolved with the signal, resulting in a so-called Gabor space. This process is closely related to processes in the primary visual cortex.[1]

The Gabor space is very useful in image processing applications such as iris recognition and fingerprint recognition. Relations between activations for a specific spatial location are very distinctive between objects in an image. Furthermore, important activations can be extracted from the Gabor space in order to create a sparse object representation.

Example implementation

This is an example implementation in MATLAB:

function gb=gabor_fn(sigma,theta,lambda,psi,gamma)

sigma_x = sigma;
sigma_y = sigma/gamma;

% Bounding box
nstds = 3;
xmax = max(abs(nstds*sigma_x*cos(theta)),abs(nstds*sigma_y*sin(theta)));
xmax = ceil(max(1,xmax));
ymax = max(abs(nstds*sigma_x*sin(theta)),abs(nstds*sigma_y*cos(theta)));
ymax = ceil(max(1,ymax));
xmin = -xmax; ymin = -ymax;
[x,y] = meshgrid(xmin:xmax,ymin:ymax);

% Rotation 
x_theta=x*cos(theta)+y*sin(theta);
y_theta=-x*sin(theta)+y*cos(theta);

gb=exp(-.5*(x_theta.^2/sigma_x^2+y_theta.^2/sigma_y^2)).*cos(2*pi/lambda*x_theta+psi);

See also

References

  1. ^ Daugman, J.G. (1980), "Two-dimensional spectral analysis of cortical receptive field profiles", Vision Res., 20 (10): 847–56, PMID 7467139

Further reading