[ITK] [ITK-users] Texture analysis - two basics questions

Timothee Evain tevain at telecom-paristech.fr
Fri Jan 8 03:40:22 EST 2016


Hello Yohann,

Welcome to the ITK community!

1) I'm not sure I've fully understood your question,so feel free to correct me.
PixelType is any of the type you want, so you could use float without problem in itkImage.
I guess your question about the data matrix is related to the fact you already have your data in another form.
You can initialize an itkImage from a memory buffer with itkImportImageFilter, read the GettingStarted-V for example ( http://www.itk.org/CourseWare/Training/GettingStarted-V.pdf )
But since you said you have a .mha file, it would be far easier to read it with itkImageFileReader

2)This is related to the method. To construct a co-occurrence matrix, you have to provide an offset which is the "step" for looking at intensities pairs.
One is enough, but the example you provided computes the features images for all possible offsets.
To do that, a Neighborhood is used to easily get the offsets ( offset = neighborhood.GetOffset(d); ).
Each loop is computing and writing the feature images for one offset.

HTH

Tim


----- Mail original -----
De: "Yohann Tschudi" <yxt227 at med.miami.edu>
À: insight-users at itk.org
Envoyé: Jeudi 7 Janvier 2016 23:57:38
Objet: [ITK] [ITK-users] Texture analysis - two basics questions

Hello,

It is the first time I am posting here and I hope I am doing it following
the rules.

I am working on the texture analysis exposed as an example here :
http://www.itk.org/Doxygen/html/WikiExamples_2Statistics_2TextureFeatures_8cxx-example.html#_a3
<http://www.itk.org/Doxygen/html/WikiExamples_2Statistics_2TextureFeatures_8cxx-example.html#_a3>  
 and I have two questions in mind.

This method take as input :
- a 3D (or 2D, not tested yet) image. For that I used :
http://itk.org/Wiki/ITK/Examples/IO/VolumeFromSlices
<http://itk.org/Wiki/ITK/Examples/IO/VolumeFromSlices>   to convert a set of
DICOM images to a .mha file containing the volume.
- Is it possible to give it directly a data matrix (ADC mean values from MR
for each pixel in the ROI for example) ? I was thinking for example to
change : 
/typedef itk::Image< PixelType, Dimension >  ImageType;/
to
/typedef itk::Image< float, Dimension >  ImageType;/
but I do not really know how to fill the image (now a float matrix right ?)
used in :
/void calcTextureFeatureImage(OffsetType offset,
	InternalImageType::Pointer inputImage, InternalImageType::Pointer
outInertia,
	InternalImageType::Pointer outCorrelation, InternalImageType::Pointer
outEnergy)
/

- The second question is about the Neighborhood and offset :
/NeighborhoodType neighborhood;
neighborhood.SetRadius(1);
unsigned int centerIndex = neighborhood.GetCenterNeighborhoodIndex();
offset = neighborhood.GetOffset(d);/ (in the loop)
I do not understand at all what is this loop is doing and what is more
generally the Neigborhood concept in this case.

Here for example :
http://stackoverflow.com/questions/29570064/itk-calculate-texture-features-for-segmented-3d-brain-mri/29582085#29582085
<http://stackoverflow.com/questions/29570064/itk-calculate-texture-features-for-segmented-3d-brain-mri/29582085#29582085>  
This is not used.

Thank you for your help,

Yohann







--
View this message in context: http://itk-insight-users.2283740.n2.nabble.com/Texture-analysis-two-basics-questions-tp7588334.html
Sent from the ITK Insight Users mailing list archive at Nabble.com.
_____________________________________
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.php

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://public.kitware.com/mailman/listinfo/insight-users
_______________________________________________
Community mailing list
Community at itk.org
http://public.kitware.com/mailman/listinfo/community
_____________________________________
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.php

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://public.kitware.com/mailman/listinfo/insight-users


More information about the Community mailing list