fibermetric

Enhance elongated or tubular structures in image

Description

example

J = fibermetric(I) enhances elongated or tubular structures in 2-D or 3-D grayscale image I using Hessian-based multiscale filtering. The image returned, J, contains the maximum response of the filter at a thickness that approximately matches the size of the tubular structure in the image.

J = fibermetric(I,thickness) specifies the thickness of the tubular structures to enhance.

J = fibermetric(___,Name,Value) uses name-value pair arguments to control different aspects of the filtering algorithm.

Examples

collapse all

Read and display an image that contains tubular threads of varying thicknesses.

A = imread('threads.png');
imshow(A)

Create an enhanced version of the image that highlights threads that are seven pixels thick. Threads show up dark against a light background, therefore specify the object polarity as 'dark'. Display the enhanced image.

B = fibermetric(A,7,'ObjectPolarity','dark');
imshow(B)
title('Enhanced Tubular Structures 7 Pixels Thick')

Threshold the enhanced image to create a binary mask image containing the threads with the specified thickness.

BW = imbinarize(B);

Display the mask over the original image by using the labeloverlay function. The overlay has a cyan tint where the mask is true (where threads have the specified thickness).

imshow(labeloverlay(A,BW));
title('Detected Tubular Structures 7 Pixels Thick')

Input Arguments

collapse all

Image with elongated or tubular structures, specified as 2-D grayscale image or 3-D grayscale volume.

Data Types: single | double | int8 | int16 | int32 | uint8 | uint16 | uint32

Thickness of tubular structures in pixels, specified as a positive integer or vector of positive integers.

Data Types: single | double | int8 | int16 | int32 | int64 | uint8 | uint16 | uint32 | uint64

Name-Value Pair Arguments

Specify optional comma-separated pairs of Name,Value arguments. Name is the argument name and Value is the corresponding value. Name must appear inside quotes. You can specify several name and value pair arguments in any order as Name1,Value1,...,NameN,ValueN.

Example: J = fibermetric(I,'StructureSensitivity',15)

Structure sensitivity, specified as the comma-separated pair consisting of 'StructureSensitivity' and a positive number. The structure sensitivity is a threshold for differentiating the tubular structure from the background.

The default value depends on the data type of image I, and is calculated as 0.01*diff(getrangefromclass(I)). For example, the default threshold is 2.55 for images of data type uint8, and the default is 0.01 for images of data type double with pixel values in the range [0, 1].

Data Types: single | double | int8 | int16 | int32 | int64 | uint8 | uint16 | uint32 | uint64

Polarity of the tubular structures with the background, specified as the comma-separated pair consisting of 'ObjectPolarity' and one of the following values:

ValueDescription
'bright'Structure is brighter than the background.
'dark'Structure is darker than the background.

Data Types: char | string

Output Arguments

collapse all

Enhanced image, returned as a numeric array of the same size as the input image I. If the data type of I is double, then the data type of J is also double. Otherwise, the data type of J is single.

Data Types: single | double

Tips

  • The fibermetric function does not perform segmentation. The function enhances an image to highlight structures and is typically used as a preprocessing step for segmentation.

Compatibility Considerations

expand all

Behavior changed in R2018b

References

[1] Frangi, Alejandro F., et al. Multiscale vessel enhancement filtering. Medical Image Computing and Computer-Assisted Intervention — MICCAI'98. Springer Berlin Heidelberg, 1998. pp. 130–137.

See Also

|

Introduced in R2017a