computes a measure for the presence of a ridge at every position of data.


uses the specified ridge scale σ.

Details and Options

  • RidgeFilter is commonly used to find ridges in images by computing estimates of the main principle curvature at each sample point using Gaussian derivatives. The main principal curvature orthogonal to a ridge is given by the main negative eigenvalue of the Hessian matrix.
  • The data can be any of the following:
  • list2D or 3D numerical array
    imagearbitrary Image or Image3D object
  • In RidgeFilter[data,σ], σ is the scale of the Gaussian derivatives in the Hessian matrix. By default, is used.
  • RidgeFilter[image,] returns a real image of the same dimensions as image.
  • RidgeFilter takes the following options used in the computation of the Hessian matrix:
  • InterpolationOrderAutomaticinterpolation order
    Padding"Fixed"padding method
  • Possible settings for the InterpolationOrder option are 3, 4, 5, , 9.
  • The Padding option accepts the settings "Fixed", "Periodic", "Reversed", "Reflected", or a numeric value. A list of two settings can specify different paddings for each dimension.


open allclose all

Basic Examples  (2)

Find the mountain ridges in a terrain elevation raster:

Click for copyable input

Sketch the thin parts in an engine block:

Click for copyable input
Click for copyable input

Scope  (4)

Options  (2)

Applications  (5)

Properties & Relations  (2)

See Also

DerivativeFilter  LaplacianFilter  LaplacianGaussianFilter  GaussianFilter  WatershedComponents  MaxDetect

Introduced in 2010
| Updated in 2014