Separate a blob into multiple regions

4 visualizaciones (últimos 30 días)
Hg
Hg el 1 de Ag. de 2015
Comentada: Hg el 1 de Ag. de 2015
Is it possible to separate a blob into multiple regions and find out the centroid and major axis of each region?

Respuesta aceptada

Walter Roberson
Walter Roberson el 1 de Ag. de 2015
Yes, but you have to have a way of determining where the boundary between regions is.
Then you could draw a pair of line segments dividing it up it separate regions and regionprops() the result.
Or you could switch out of logical() class, leave one of the sections as 1's as it is now, fill another of the sections with 2's, and the third with 3's. The result would be a labeled image that regionprops() could handle.
Or you could create three derived images, each masking out the unwanted parts, and call regionprops() on each.
One way that might work (but I haven't experimented with it myself) would be to skeletonize that image and then identify the location of the two turns. If the images are as regular as they look, the centroids will be the half-way points in each line segment, and you could determine the orientations with some minor trig to determine slopes then arctan()
  1 comentario
Hg
Hg el 1 de Ag. de 2015
Thanks for the answer. Other than the suggested methods above, I think I can use kmeans() to cluster and separate the region.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Image Segmentation and Analysis en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by