Difference between revisions of "Edge Detection: Zero X Non-Maximum Suppression"

From MIPAV
Jump to: navigation, search
(Background)
Line 14: Line 14:
 
For a 2D image, let's introduce a local coordinate system (u, v) such that at any point in the image P''0''(x''0'',y''0'') v-axis is parallel to the gradient direction at (x''0'',y''0'') and the u-axis is perpendicular to it, i.e.,
 
For a 2D image, let's introduce a local coordinate system (u, v) such that at any point in the image P''0''(x''0'',y''0'') v-axis is parallel to the gradient direction at (x''0'',y''0'') and the u-axis is perpendicular to it, i.e.,
  
<div style="font-style: normal; font-weight: normal; margin-bottom: 5pt; margin-left: 0pt; margin-right: 0pt; margin-top: 9pt; text-align: center; text-decoration: none; text-indent: 0pt; text-transform: none; vertical-align: baseline"><font size="9pt"><font color="#000000"> Equation 10
+
Equation 10 <div align "left> </div> </br>
 +
 
  
 
{| border="1" cellpadding="5"
 
{| border="1" cellpadding="5"

Revision as of 20:07, 2 February 2012

Mipavfinallogo.gif


Edge Detection: Zero X Non-Maximum Suppression

This method produces an edge map of the zero-crossings of the non-maximum suppression for 2D and 2.5D images. Edges are defined as the union of points for which the gradient magnitude assumes a maximum in the gradient direction.

Background

For a 2D image, let's introduce a local coordinate system (u, v) such that at any point in the image P0(x0,y0) v-axis is parallel to the gradient direction at (x0,y0) and the u-axis is perpendicular to it, i.e.,

Equation 10
</br>


Eq1.jpg


</font></font></div>

Where L is a convolution of an image (represented as a function f(x,y) with the Gaussian kernel defined as:

Equation 11
Eq2Gaussian.jpg

so that

Equation 12
Eq3Convolution.jpg

where the circle represents convolution of g(x,y;t) and f(x,y) and semicolon in the argument of g implies that the convolution is performed only over the variables x and y, while the scale parameter t after the semicolon just indicates which scale-space level is being defined. Directional derivatives in this local (u,v) system are related to partial derivatives in the Cartesian coordinate system by the following system of equations,

Equation 13
Eq4.jpg

where, at a given point P0

Equation 14
Eq5.jpg

And this (u,v) coordinate system is characterized by the fact that one of the two first-order derivatives -Lu, is zero, e.g.

Equation 15
Eq6.jpg

Equation 16
Eq7.jpg

Equation 17
Eq8.jpg

Below, are equations used in the method for calculating the second and third derivative - Lvv and Lvvv.

Equation 18
Eq9.jpg


Equation 19
Eq10.jpg


Equation 20
Eq11.jpg


Equation 21
Eq12.jpg


Equation 22
Eq13.jpg

According to the notion of non-maximum suppression, an edge point is defined as a point at which the gradient magnitude assumes a maximum in the gradient direction. In terms of directional derivatives, such definition can be also expressed as a combination of two conditions:

    • The second-order directional derivative in the v-direction Lvv being zero;
    • And the third-order directional derivative in the same direction Lvvv being negative, e.g.:
Equation 23
Eq14.jpg

Since only the sign information is important, these conditions can be restated as:

Equation 24
Eq15.jpg

Here, L is the scale-space representation of an image f(x,y;t) at a certain scale t, and the last equation defines the edges of f at that scale.

This condition can also be formulated in terms of zero-crossings of the partial derivative of L with respect to the scale parameter (i.e., as a directional derivative in the vertical scale direction). For more information about the zero-crossings method for detecting edges used in MIPAV, refer to MIPAV User Manual, Volume 2, Algorithms, [Edge_Detection_Zero_X.html#wp1005679 "Edge Detection: Zero X Laplacian" ].

The method evaluates detected zero-crossings using the Marching Squares algorithm to determine only those zero-crossings that corresponds to edges. To learn more about the Marching Squares algorithm, refer to MIPAV User Manual, Volume 2, Algorithms, [MarchingCubes.html#wp999048 "Extract Surface (Marching Cubes)" ].

The resulting image is an unsigned byte image with values of 255 at the edges and 0 elsewhere.


Figure 19. The original image and its unsigned byte mask with detected edges.

EdgeDetNonMAxSupprOriginal.jpg

EdgeDetNonMAxSupprResultl.jpg

Image types

You can apply this algorithm to 2D and 3D grayscale images.

References

Bart M. ter Haar Romeny(Ed.), "Geometry-Driven Diffusion in Computer Vision", Chapter2: Linear Scale'-'Space II: Early Visual Operations by Tony Lindeberg and Bart M. ter Haar Romeny, Kluwer Academic Publishers, 1994, pp. 39-46.

MIPAV User Manual, Volume 2, Algorithms, [Edge_Detection_Zero_X.html#wp1005679 "Edge Detection: Zero X Laplacian" ].

Tony Lindeberg [1996]. "Edge detection and ridge detection with automatic scale selection" Technical report ISRN KTH/NA/P-96/06-SE, May 1996, Revised August 1998. Int. J. of Computer Vision, vol 30, number 2, 1998. (In press). Shortened version in Proc. CVPR'96, San Francisco, June 1996. http://www.nada.kth.se/~tony

Applying the Zero X Non-Maximum Suppression algorithm

To run this algorithm, complete the following steps:

  1. Open an image of interest;
  2. Select Algorithms > Edge detection > Zero x non-maximum suppression. The EdgeNMSuppression dialog box opens. For the dialog box options, refer to [Edge_Detection_Zero_X_Non-Maxx_Suppress.html#wp1028172 Figure 20].
  3. Complete the fields in the dialog box. Click OK.
The algorithm begins to run, and a status window appears. When the algorithm finishes, the resulting image appears as an unsigned byte mask in a new image window as shown in [Edge_Detection_Zero_X_Non-Maxx_Suppress.html#wp1028301 Figure 21].

Scale of the Gaussian
Specifies the standard deviation (from 1.0 to 10.0) of the Gaussian filter in X, Y, and Z directions which were used to determine edges in the image.
Note that larger standard deviation produces an image with smaller number of edges. Smoothing the image before applying the algorithm also reduce the number of detected edges. Refer to [Edge_Detection_Zero_X_Non-Maxx_Suppress.html#wp1028301 Figure 21] for more information.
EdgeNMSuppression.jpg
Use image resolutions to normalize Z scale
If checked, the following equation - Z scale*(X resolution/Z resolution) will be used to generate the edge map.
If unchecked, only Z scale will be used in generation of the edge map.
Process each slice independently (2.5D)
Applies the algorithm to each image slice individually.
Destination
New image - this is the default option; Replace image - this option cannot be selected.
Process
Whole Image - if checked the edge detection will be calculated for the whole image; VOI region - if checked the edge detection will be calculated for the selected VOI.
OK
Applies the algorithm according to the specifications in this dialog box.
Cancel
Closes the dialog box.
Help
Displays online help for this dialog box.
Figure 20. The EdgeNMSuppression dialog box options

Figure 21. The original image (a) and its unsigned byte mask with detected edges depending on the standard deviation: (b) - standard deviation is set to 1; (c) - standard deviation is set to 4; (d) - standard deviation is set to 6; (e) - standard deviation is set to 8; (f) - standard deviation is set to 6, but the original image has been smoothed before applying the algorithm.

EdgrNMSuppOriginal.jpg

a
EdgrNMSuppEdges.jpg

b
EdgeDetNonMAxSupprResultDev4.jpg

c
EdgeDetNonMAxSupprResultDev6.jpg

d
EdgeDetNonMAxSupprResultDev8.jpg

e
EdgeDetNonMAxSupprResultDev6AfterBlur.jpg

f

[Edge_Detection_Zero_X.html Previous][ExtractBrainSurfaceBET.html Next]

Imaging Sciences Laboratory, CIT, NIH
Matthew McAullife, Ph.D.
mcmatt@exchange.nih.gov
301-594-2432
Building 12A, Room 2041,
9000 Rockville Pike, Bethesda, MD 20892