[Insight-users] Label Connected Components in 2D binary Image in ITK+VTK

Sergio Vera sergio.vera at alma3d.com
Wed Dec 15 10:05:21 EST 2010


Hello Humayun,

ITK has a family of filters that work with labels. You can find more info in
this insight journal article: http://hdl.handle.net/1926/584

<http://hdl.handle.net/1926/584>The filters presented in that article are
now included in the ITK library, but under the Review directory, so in order
to use them you need to compile ITK with the USE_REVIEW variable set to true
in CMake.

Compared to with MATLAB's bwlabel and bwlabeln, those filters don't have the
same customization power regarding the connectivity at which they work, but
they are nice additions to ITK.

Regards

On Wed, Dec 15, 2010 at 3:51 PM, Humayun Irshad <humayun.irshad at gmail.com>wrote:

>
>
>
> I am working in ITK+VTK. I want to get Label connected components in 2-D
> binary image. Similiar type of function, *bwlabel (
> http://www.mathworks.com/help/toolbox/images/ref/bwlabel.html) *function
> exist in Matlab. Is any similiar to bwlabel function exist in ITK+VTK.
>
> e.g., Input to this function is matrixA and output of function should be
> matrixB.
>
>                1     1     1     0     0     0     0     0
>                1     1     1     0     1     1     0     0
>                1     1     1     0     1     1     0     0
> matrixA =      1     1     1     0     0     0     1     0
>
>                1     1     1     0     0     0     1     0
>                1     1     1     0     0     0     1     0
>                1     1     1     0     0     1     1     0
>                1     1     1     0     0     0     0     0
>
>
>
>                1     1     1     0     0     0     0     0
>                1     1     1     0     2     2     0     0
>                1     1     1     0     2     2     0     0
> matrixB =      1     1     1     0     0     0     3     0
>
>                1     1     1     0     0     0     3     0
>                1     1     1     0     0     0     3     0
>                1     1     1     0     0     1     3     0
>                1     1     1     0     0     0     0     0
>
>
>
> --
> --
> Best Regards,
>
> Humayun Irshad
>
> IPAL CNRS (Image & Pervasive Access Lab)
> Institute for Infocomm Research (I2R)
> 1 Fusionopolis Way
> #21-01 Connexis South Tower
> Singapore 138632
> Tel: +65 83851671
>
>
>
> --
> --
> Best Regards,
>
> Humayun Irshad
>
> IPAL CNRS (Image & Pervasive Access Lab)
> Institute for Infocomm Research (I2R)
> 1 Fusionopolis Way
> #21-01 Connexis South Tower
> Singapore 138632
> Tel: +65 83851671
>
> _____________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.html
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users
>
>


-- 
Sergio Vera

 Alma IT Systems
 C/ Vilana, 4B, 4º 1ª
 08022 Barcelona
 T. (+34) 932 380 592
 www.alma3d.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20101215/1f82eb68/attachment.htm>


More information about the Insight-users mailing list