[Insight-users] Texture Feature Extraction
Luis Ibanez
luis.ibanez at kitware.com
Tue May 25 15:11:47 EDT 2010
Hi Neal,
You may find useful to look at the tests:
Insight/Testing/Code/Numerics/Statistics/
itkGreyLevelCooccurrenceMatrixTextureCoefficientsCalculatorTest.cxx
itkImageToCooccurrenceListAdaptorTest.cxx
itkMaskedScalarImageToGreyLevelCooccurrenceMatrixGeneratorTest.cxx
itkScalarImageToGreyLevelCooccurrenceMatrixGeneratorTest.cxx
Admittedly, tests are not as illustrative as real
examples, but, hopefully these ones here may
provide some guidance.
Regards,
Luis
-------------------------------------------------------
On Wed, May 12, 2010 at 10:54 AM, Neal R. Harvey <harve at lanl.gov> wrote:
> I too would be interested in using this functionality - i.e.
>
> ScalarImageToGreyLevelCooccurrenceMatrixGenerator
>
> and
>
> MaskedScalarImageToGreyLevelCooccurrenceMatrixGenerator
>
> However, for me to have any hope of using it successfully, I need some
> additional documentation on its use, beyond that available at:
>
> http://www.itk.org/Doxygen316/html/classitk_1_1Statistics_1_1MaskedScalarImageToGreyLevelCooccurrenceMatrixGenerator.html#_details
>
> and
>
> http://www.itk.org/Doxygen316/html/classitk_1_1Statistics_1_1ScalarImageToGreyLevelCooccurrenceMatrixGenerator.html
>
> I can't find anything about their use in the book. Does anyone know where I
> can get further documentation,
> such as examples showing how to use them?
>
>> ------------------------------
>>
>> Message: 2
>> Date: Wed, 12 May 2010 07:23:59 -0400
>> From: Cory Quammen <cquammen at cs.unc.edu>
>> Subject: Re: [Insight-users] Texture Feature Extraction
>> To: mohammed abdel samea <mohammed_abdel_samea at yahoo.com>
>> Cc: insight-users at itk.org
>> Message-ID:
>> <AANLkTik_qM232OZeM5k6ngSF-6VAxi3lirFGv_pOJW-H at mail.gmail.com>
>> Content-Type: text/plain; charset=ISO-8859-1
>>
>> Mohammed,
>>
>> You apparently are not linking against some libraries. Could you post
>> a more detailed error message so that we can get a hint as to which
>> libraries you are missing?
>>
>> Thanks,
>> Cory
>>
>> On Wed, May 12, 2010 at 4:13 AM, mohammed abdel samea
>> <mohammed_abdel_samea at yahoo.com> wrote:
>>
>>>
>>> Hi,
>>>
>>> I've tried to extract texture feature from an image. but wrote the
>>> following
>>> code:
>>>
>>> typedef float InternalPixelType;
>>> const unsigned int Dimension = 2;
>>> typedef itk::Image< InternalPixelType, Dimension > InternalImageType;
>>> typedef? itk::ImageFileReader< InternalImageType > ReaderType;
>>> ReaderType::Pointer reader = ReaderType::New();
>>> reader->SetFileName( FileName );
>>> typedef
>>>
>>> itk::Statistics::ScalarImageToGreyLevelCooccurrenceMatrixGenerator<InternalImageType>
>>> GLCMGeneratorType;
>>> typede
>>>
>>> fitk::Statistics::GreyLevelCooccurrenceMatrixTextureCoefficientsCalculator
>>> <GLCMGeneratorType::HistogramType> TexCalcType;
>>> InternalImageType::Pointer block = InternalImageType::New();
>>> block->SetRegions(reader->GetOutput()->GetRequestedRegion());
>>> block->Allocate();
>>> GLCMGeneratorType::Pointer glcm = GLCMGeneratorType::New();
>>> glcm->SetInput(block);
>>> InternalImageType::OffsetType offset = {1,0};
>>> glcm->SetOffset(offset);
>>> glcm->SetNumberOfBinsPerAxis(256);
>>> glcm->Compute();
>>> TexCalcType::Pointer texCalc = TexCalcType::New();
>>> texCalc->SetHistogram(glcm->GetOutput());
>>> double contrast = texCalc->GetInertia();
>>>
>>> But I've got errors: fatal error LNK1120: 12 unresolved externals. How
>>> can I
>>> solve this problem! help is really appreciated about that matter!.
>>>
>>> Best Regards,
>>> ?Mohammed
>
> _____________________________________
> 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
>
More information about the Insight-users
mailing list