I can't understand what is bwconncomp command do ?
6 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
What does "connecting components" mean ? What are components ? What they connect ?
0 commentaires
Réponses (2)
Image Analyst
le 6 Mai 2017
If all you have is one giant image, essentially a collection of individual pixel elements, and you want the area of one blob in the image, then how do you think you can do it? How do you think it would know that pixel 5 is connected to pixel 6 (assuming they're both true/white/1 in the binary image) but pixel 498357 (far away and separated by big swaths of black from pixel 5) is not part of the same blob and should not be counted in the area computation? You have to give each connected set of pixels in a blob an ID number, so it will know pixels 5 and 6 are part of blob #1 but pixel #498357 is part of blob #135 (or whatever).
Read this page https://en.wikipedia.org/wiki/Connected-component_labeling and see if you still don't know what it is after reading that.
0 commentaires
Steven Lord
le 6 Mai 2017
This example in the documentation describes and illustrates what a connected component is.
Why might you be interested in connected components? Take a look at the "before" and "after" pictures in the "Erase Largest Component from Image" example on the documentation page for bwconncomp. Note that the "different" in the before picture has become "di erent" in the after picture, because the two f's were connected to one another and so were considered one component. But in other words in the picture, the individual letters will be the components.
1 commentaire
Voir également
Catégories
En savoir plus sur Read, Write, and Modify Image dans Help Center et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!