[Insight-users] Continuous Index

Xiang Hao haoxiang at yahoo.cn
Wed Jul 1 15:53:27 EDT 2009


Hi Luis,

I can compute the features at the continuous index by following your
suggestion. Thank you again. Now I want to save the tract(path) in an binary
image, but I have a problem about how to write an value in a continuous
index.

Cheers,
Xiang

On Tue, Jun 30, 2009 at 12:41 PM, Xiang Hao <haoxiang at yahoo.cn> wrote:

> Great, Luis. Thank you again. I appreciate it very much.
>
> Cheers,
> Xiang
>
>
> On Tue, Jun 30, 2009 at 11:30 AM, Luis Ibanez <luis.ibanez at kitware.com>wrote:
>
>>
>> Hi Xiang,
>>
>> If you need to evaluat the image at ContinousIndex positions,
>> or at Point positions you will need to use an Interpolator.
>>
>> Something like
>>
>>    interpolator->SetImage( image );
>>    interpolator->Evaluate( point );
>>    interpolator->Evaluate( continuousIndex );
>>
>> For a list of ITK Interpolators, please look at:
>>
>> http://public.kitware.com/Insight/Doxygen/html/group__ImageInterpolators.html
>>
>>
>> Note however, that, depending on how you track
>> fibers, what you may actually need is to compute
>> features at those points (or continuous indices)
>> and therefore you may have to use ImageFunctions
>> there.
>>
>> For example:
>>
>> itkGaussianBlurImageFunction.h
>> itkGaussianDerivativeImageFunction.h
>>
>>
>>
>>        Regards,
>>
>>
>>                 Luis
>>
>>
>>
>> ----------------------------------------------------------------------
>>
>> On Tue, Jun 30, 2009 at 1:22 PM, Xiang Hao <haoxiang at yahoo.cn> wrote:
>>
>>> Hi Luis,
>>>
>>> Thank you so much, Luis. I will try it, and BTW, as I remember, there is
>>> a problem about setPixel() and getPixel() method while I am using the
>>> ContinuousIndex. It said it cannot find the corresponding method. Anyway, I
>>> will try your method and try to make it work.
>>>
>>> Thank you again,
>>> Xiang
>>>
>>>
>>> On Tue, Jun 30, 2009 at 10:29 AM, Luis Ibanez <luis.ibanez at kitware.com>wrote:
>>>
>>>>
>>>>
>>>> Hi Xian,
>>>>
>>>> If you need sub-pixel locations for the points of the fibers,
>>>> yes, it makes sense to use ContinuousIndex instead of
>>>> Indexes for representing the location of fibers centers.
>>>>
>>>> That said, it may be preferable to use itk::Point<> since
>>>> that will take into account also the pixel spacing, image
>>>> origin, and image orientation, and you will be able to
>>>> do things like overlapping a visualization of the fibers
>>>> with the original image.
>>>>
>>>> A) If you need to convert Index to ContinousIndex you
>>>>      can use the method:
>>>>
>>>>     Constructor
>>>>
>>>>      IndexType  index;
>>>>      ContinuousIndexType  cindex( index );
>>>>
>>>> B) In order to convert Continuous index to Index you
>>>>      can use the method CopyWithRound()
>>>>
>>>>     index.CopyWithRound( continousIndex )
>>>>
>>>> C) In order to convert an index into a physical point
>>>>      and back you can use the image methods
>>>>
>>>>       TransformIndexToPhysicalPoint( index, point );
>>>>       TransformPhysicalPointToIndex(point, index );
>>>>
>>>>
>>>>
>>>>   Regards,
>>>>
>>>>
>>>>
>>>>         Luis
>>>>
>>>>
>>>>
>>>>
>>>> ----------------------------------------------------------------------------------------------
>>>> On Sun, Jun 28, 2009 at 2:42 PM, Xiang Hao <haoxiang at yahoo.cn> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> I am trying to write a tractography program.
>>>>> Now I use discrete index:
>>>>>
>>>>> Dimension =3;
>>>>> typedef int OutputPixelType;
>>>>> typedef itk::Image< OutputPixelType, Dimension > OutputImageType;
>>>>> OutputImageType::IndexType pixelIndex;
>>>>>
>>>>> So now the pixelIndex is discrete index and I want to change it to
>>>>> continuous index. I know there is an ContinuousIndex class in ITK. I wonder
>>>>> whether I should use this class and how to use it in order to change the
>>>>> index to continuous index.
>>>>>
>>>>>
>>>>> --
>>>>> Cheers,
>>>>> Xiang
>>>>>
>>>>>
>>>>> --
>>>>> Cheers,
>>>>> Xiang
>>>>>
>>>>> _____________________________________
>>>>> Powered by www.kitware.com
>>>>>
>>>>> Visit other Kitware open-source projects at
>>>>> http://www.kitware.com/opensource/opensource.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
>>>>>
>>>>>
>>>>
>>>
>>>
>>> --
>>> Cheers,
>>> Xiang
>>>
>>
>>
>
>
> --
> Cheers,
> Xiang
>



-- 
Cheers,
Xiang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20090701/2528260e/attachment-0001.htm>


More information about the Insight-users mailing list