({{, (RefLink[SkeletonTransform, paclet:ref/SkeletonTransform])[image] 
gives the skeleton transform of image, in which the value of each skeleton pixel is its distance to the nearest background pixel.}, {, (RefLink[SkeletonTransform, paclet:ref/SkeletonTransform])[image,t]
treats values above t as foreground.}})

OpenersNotesSection(Spacer1)Details and Options

(RefLink[SkeletonTransform, paclet:ref/SkeletonTransform]) effectively gives the medial axis of foreground objects multiplied with the distance transform.

(RefLink[SkeletonTransform, paclet:ref/SkeletonTransform]) gives an (RefLink[Image, paclet:ref/Image]) object in which the value of each nonzero pixel is the absolute Euclidean distance in pixels to the nearest pixel of background.

The inverse of (RefLink[SkeletonTransform, paclet:ref/SkeletonTransform]) can be computed using (RefLink[InverseDistanceTransform, paclet:ref/InverseDistanceTransform]).

For multichannel images, (RefLink[SkeletonTransform, paclet:ref/SkeletonTransform]) operates on the intensity averaged over all channels.

(RefLink[SkeletonTransform, paclet:ref/SkeletonTransform])[image] is equivalent to (RefLink[SkeletonTransform, paclet:ref/SkeletonTransform])[image,0].

The following options can be given:

Possible settings for the (RefLink[Method, paclet:ref/Method]) option are "MedialAxis" and "ReducedMedialAxis".

OpenersPrimaryExamplesSection(Spacer1)Examples  (8)

OpenersExampleSection0(Spacer1)Basic Examples  (1)

Skeleton transform of a binary image:

SkeletonTransform[]//ImageAdjust

OpenersExampleSection1(Spacer1)Scope  (2)

Skeleton transform applied to text:

SkeletonTransform[]

Skeletons of color shapes:

SkeletonTransform[ColorNegate@,0.1]

OpenersExampleSection2(Spacer1)Options  (3)

OpenersExampleSubsection0(Spacer1)Method  (2)

By default the full medial axis is returned:

SkeletonTransform[]

Compute reduced medial axis:

SkeletonTransform[,Method->"ReducedMedialAxis"]

Reduced medial axis of color shapes:

SkeletonTransform[ColorNegate@,0.1, Method->"ReducedMedialAxis"]

OpenersExampleSubsection1(Spacer1)Padding  (1)

By default, zero padding is assumed:

i=;

SkeletonTransform[i]

Specify a different padding scheme:

SkeletonTransform[i,Padding->1]

OpenersExampleSection3(Spacer1)Applications  (1)

Simplify a shape by pruning its skeleton:

Pruning[SkeletonTransform[],30]

Reconstruct the simplified shape:

InverseDistanceTransform[%]

OpenersExampleSection4(Spacer1)Properties & Relations  (1)

(RefLink[InverseDistanceTransform, paclet:ref/InverseDistanceTransform]) gives the exact inverse of (RefLink[SkeletonTransform, paclet:ref/SkeletonTransform]):

SkeletonTransform[]

InverseDistanceTransform[%]

({{DocumentationFooterIconsRelatedFunction.png, ({{See Also}, {(RefLink[Thinning, paclet:ref/Thinning])  ▪  (RefLink[Pruning, paclet:ref/Pruning])  ▪  (RefLink[DistanceTransform, paclet:ref/DistanceTransform])  ▪  (RefLink[InverseDistanceTransform, paclet:ref/InverseDistanceTransform])}})}})

({{DocumentationFooterIconsRelatedTutorial.png, ({{Tutorials}, {▪(RefLinkPlain[Image Processing, paclet:tutorial/ImageProcessing])}})}})

({{DocumentationFooterIconsRelatedGuide.png, ({{Related Guides}, {▪(RefLinkPlain[Mathematical Morphology, paclet:guide/MathematicalMorphology])}})}})