Filters (Spatial): Gradient Magnitude

From MIPAV
Jump to: navigation, search

Edge detection is the identification of meaningful discontinuities in gray level or color images. Edges are formed between two regions that have differing intensity values. This algorithm calculates the gradient magnitude of an image (or VOI of the image) using the first derivatives (Gx, Gy, and Gz [3D] ) of the Gaussian function at a user-defined scale sigma (standard deviation, or SD) and convolving it with image. The convolution of the first derivatives of the Gaussian with an image is a robust method of extracting edge information. By varying the SD, a scale-space of edges can easily be constructed.

Image types

You can apply this algorithm to all image data types except complex and to 2D, 2.5D, 3D, and 4D images.

Special notes

The following notes apply:

  • The resultant image is, by default, a float type image;
  • To achieve 2.5D blurring (each slide of the volume is processed independently), select Process each slide independently (2.5D) in the Gradient Magnitude dialog box.

References

Refer to the following references for more information:

Raphael C. Gonzalez and Richard E. Woods, Digital Image Processing (Boston: Addison-Wesley, 1992).

J. J. Koenderink, "The Structure of Images," Biol Cybern 50: 363-370, 1984.

Tony Lindeberg, "Linear Scale-Space I: Basic Theory," Geometry-Driven Diffusion in Computer Vision, Bart M. Ter Har Romeney, ed. (Dordrecht, The Netherlands: Kluwer Academic Publishers, 1994), pp. 1-38.

Applying the Gradient Magnitude algorithm

To run this algorithm, complete the following steps:

  1. Select Algorithms > Filter > Gradient Magnitude. The Gradient Magnitude dialog box opens (Figure 1).
  2. Complete the information in the dialog box.
  3. When complete, click OK. The algorithm begins to run.
A pop-up window appears with the status. The following message appears
"Calculating the Gradient Magnitude." When the algorithm finishes running, the pop-up window closes.
Depending on whether you selected New Image or Replace Image, the result appears in a new window or replaces the image to which the algorithm was applied.

Figure 1. Gradient Magnitude dialog box

X Dimension
Indicates the standard deviation (SD) of Gaussian in the X direction.
DialogboxGradientMagnitude.jpg
Y Dimension
Indicates the SD of Gaussian in the Y direction.
Z Dimension
Indicates the SD of Gaussian in the Z direction.
Use image resolutions to normalize Z scale
Normalizes the Gaussian to compensate for the difference if the voxel resolution is less between slices than the voxel resolution in-plane. This option is selected by default.
Process each slice independently (2.5D)
Blurs each slice of the dataset independently.
Process red channel
Applies algorithm to the red channel only.
Process green channel
Applies algorithm to the green channel only.
Process blue channel
Applies algorithm to the blue channel only.
New image
Shows the results of the algorithm in a new image window.
Replace image
Replaces the current active image with the results of the algorithm.
Whole image
Applies the algorithm to the whole image.
VOI region(s)
Applies the algorithm to the volumes (regions) delineated by the VOIs.
OK
Applies the Gradient Magnitude algorithm according to the specifications in this dialog box.
Cancel
Disregards any changes that you made in this dialog box and closes the dialog box.
Help
Displays online help for this dialog box.