label_regions
13 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I would like a function that accepts a binary image and returns an image. The output image has the same dimensions as the input image, and the value of each pixel of the output image is an index describing what region that pixel belongs to. That is, each region in the input binary image is assigned a unique index, and that index is placed in the corresponding pixels of the output image.
Does such a function exist?
For those who are familiar with IDL, I'm looking for the Matlab equivalent of label_regions.
0 commentaires
Réponses (1)
Image Analyst
le 15 Oct 2011
You can use bwlabel() http://www.mathworks.com/help/toolbox/images/ref/bwlabel.html in the Image Processing Toolbox. It's still there, but there is a more efficient version called bwconncomp() http://www.mathworks.com/help/toolbox/images/ref/bwconncomp.html in newer versions of the toolbox.
0 commentaires
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!