GaborFilter

GaborFilter[data,r,k]

filters data by convolving with a Gabor kernel of pixel radius r and wave vector k.

GaborFilter[data,r,k,ϕ]

uses a Gabor kernel with phase shift ϕ.

GaborFilter[data,{r,σ},]

uses a Gabor kernel with radius r and standard deviation σ.

Details and Options

  • GaborFilter is a linear, spatially directional and frequency-selective filter commonly used in image processing for texture analysis and segmentation. In the spatial domain, a 2D Gabor filter kernel is a Gaussian function modulated by a sinusoidal plane wave.
  • The data can be any of the following:
  • listarbitrary-rank numerical array
    tseriestemporal data such as TimeSeries, TemporalData,
    imagearbitrary Image or Image3D object
    audioan Audio object
  • GaborFilter[data,r,k] is equivalent to GaborFilter[data,{r,r/2},k,0].
  • Either of the r or σ can be lists, specifying different values for different directions.
  • GaborFilter[image,] by default gives an image of a real type of the same dimensions as image.
  • The following options can be specified:
  • Padding "Fixed"padding method
    StandardizedTruewhether to rescale the Gabor kernel to account for truncation
    WorkingPrecision Automaticthe precision to use
  • With a setting Padding->None, GaborFilter[data,] normally gives a result smaller than data.

Examples

open allclose all

Basic Examples  (3)

Filter an image:

Gabor filtering of a 3D image:

Apply a Gabor filter to a list of values:

Scope  (7)

Data  (4)

Gabor filtering of a 2D array:

Filter a TimeSeries object:

Filter an Audio signal:

Filter a color image:

Parameters  (3)

Gabor filtering of a noisy signal using different kernel radii:

Use different standard deviations:

Use different wave vectors:

Gabor filtering in the vertical direction:

Filtering in the horizontal direction:

Filtering in a diagonal direction:

The cosine part of a Gabor filter is computed when :

The sine part of a Gabor filter is computed when :

Options  (6)

Padding  (3)

Gabor filtering using different padding schemes:

Gabor filtering of a grayscale image using different padding schemes:

Padding->None normally returns an image smaller than the input image:

WorkingPrecision  (3)

MachinePrecision is by default used with integer arrays:

Perform exact computation instead:

With real arrays, by default the precision of the input is used:

Specify the precision to use:

WorkingPrecision is ignored when filtering images:

An image of a real type is always returned:

Applications  (3)

Gabor filtering of an image to detect vertical lines in an image:

Detect edges in the specified direction in a noisy image:

The magnitude of the Gabor filter is computed as the squared norm of the sine and cosine components:

Extract regions with the dominant direction parallel to and :

Highlight two texture segments on the image:

Properties & Relations  (5)

GaborFilter is equivalent to a convolution with a GaborMatrix:

Gabor filtering with a zero-valued wave vector is equivalent to Gaussian smoothing:

Impulse response of a Gabor filter:

Magnitude spectrum of the filter:

Gabor filtering of an image gives a real-valued image:

GaborFilter is a linear filter:

Wolfram Research (2012), GaborFilter, Wolfram Language function, https://reference.wolfram.com/language/ref/GaborFilter.html (updated 2016).

Text

Wolfram Research (2012), GaborFilter, Wolfram Language function, https://reference.wolfram.com/language/ref/GaborFilter.html (updated 2016).

CMS

Wolfram Language. 2012. "GaborFilter." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2016. https://reference.wolfram.com/language/ref/GaborFilter.html.

APA

Wolfram Language. (2012). GaborFilter. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/GaborFilter.html

BibTeX

@misc{reference.wolfram_2024_gaborfilter, author="Wolfram Research", title="{GaborFilter}", year="2016", howpublished="\url{https://reference.wolfram.com/language/ref/GaborFilter.html}", note=[Accessed: 21-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_gaborfilter, organization={Wolfram Research}, title={GaborFilter}, year={2016}, url={https://reference.wolfram.com/language/ref/GaborFilter.html}, note=[Accessed: 21-November-2024 ]}