[Insight-users] Label Image question again...

Gaëtan Lehmann gaetan.lehmann at jouy.inra.fr
Tue May 20 08:30:06 EDT 2008


Hi,

Le 20 mai 08 à 12:01, Xabier Artaechevarria Artieda a écrit :

> Hi Anja,
>
> Let's see if I can help a bit with some points.
>
> 1. The article you mentioned is an Insight Journal contribution. As  
> such, it includes the code needed to reproduce the results. You need  
> this code, which you can find in http://insight-journal.org/InsightJournalManager/view_reviews.php?pubid=176 
> .
> This includes the LabelImage class, the classes to convert different  
> images to a LabelMap, and so on.

I think that's an error in the name used here, but just to be sure:

   There is no LabelImage class in that contribution.

The string “LabelImage” is used in the name of a filter to describe an  
image (stored in an itk::Image object) with several objects inside it.  
“LabelImage” is used the same way “BinaryImage” is used elsewhere in  
the toolkit.
A label image is a classical itk::Image, but with some specific  
properties: each object is marked in the image by a different pixel  
value (a label). An object int that label image is formed by all the  
pixels with the same label.

The real new class is itk::LabelMap. This class is able to store a  
label image (that's why there are classes to convert one  
representation to the other) and also some values associated to the  
objects (like the size, the elongation, the centroid, …). The way the  
objects are stored in memory is completely different of the way  
itk::Image stores an image. This new memory representation allow very  
fast computations of most of the attributes, and an easier  
manipulation of the objects. Also, using itk::LabelMap, more  
attributes computations have been implemented than what is currently  
available in ITK with the classical label images.

>
>
> 2. At least that I know, there is no straighforward way to create a  
> LabelImage based on a user defined contour. What you need, though,  
> is a LabelMap.

There is no straightforward way to create an *itk::LabelMap* from a  
user defined contour. It should be possible to create a label image,  
or at least a binary image from a user defined contour however, by  
using the spatial objects.

>
> 3. You must do it in two steps. First convert your points to binary  
> image, and then this image to a label map. You can convert a Binary  
> image to a label map easily with the itkBinaryImageToBinaryMapFilter.
>

rather itk::BinaryImageToLabelMapFilter :-)

Regards,

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.mandriva.org
http://www.itk.org  http://www.clavier-dvorak.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 186 bytes
Desc: This is a digitally signed message part
URL: <http://www.itk.org/pipermail/insight-users/attachments/20080520/793fafc3/attachment.pgp>


More information about the Insight-users mailing list