[Insight-users] how to remove an object (connected component) from the labled volume?

Gaëtan Lehmann gaetan.lehmann at jouy.inra.fr
Wed Apr 27 10:08:31 EDT 2011


Le 27 avr. 11 à 16:03, anna han wan a écrit :

> Hi all and sorry to send my questions in different emails.
> I have another question regarding ConnectedComponentImageFilter and  
> RelabelComponentImageFilter.
> Once I have the list of objects (connected components) in my volume  
> after applying RelabelComponentImageFilter, which class or function  
> can I use to specify a given object so I can remove it?

How do you want to specify which object you want to remove?

> Also can I access to the voxels belonging to a given connected  
> component?
>

You can iterate over all the pixels of the image and check the pixel  
value, but this is quite inefficient.
You can also use a LabelMap - in that case you can access only the  
pixel in a given object.

Gaëtan

-- 
Gaëtan Lehmann
Biologie du Développement et de la Reproduction
INRA de Jouy-en-Josas (France)
tel: +33 1 34 65 29 66    fax: 01 34 65 29 09
http://voxel.jouy.inra.fr  http://www.itk.org
http://www.mandriva.org  http://www.bepo.fr

-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 203 bytes
Desc: Ceci est une signature ?lectronique PGP
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110427/3050d168/attachment.pgp>


More information about the Insight-users mailing list