[Insight-users] [ITK Community] itkBSplineDeformableTransform implement local deformation

Luis Ibanez luis.ibanez at kitware.com
Sun Dec 29 10:29:34 EST 2013


Hi Tina,

Yes, the BSplineDeformableTransform can manage local deformations.

The parameters of the Transform are the components of the displacement
vectors
at every node of the BSpline Grid.

You can define the BSpline Grid to cover a small region of the image.
This is done by setting the Origin, Direction and Spacing of the Grid
according to the physical coordinates that you want to cover.

For example,

if you have an image of 300x400 pixels, with spacing of
2mmx3mm, with origin at 10mm,30mm,

and you want to cover the upper quarter of the image.
(note that ITK coordinates have Y+ aimed at the up direction).

you can define the BSpline Grid to have origin at:

X = 10mm + ( 300 / 2 ) * 2mm = 310mm
Y = 30mm + ( 400 / 2 ) * 3mm = 630mm

and if you want to match one BSpline Grid node to 5x5 pixels
region in the image then the Grid spacing would be:

Sx = 5 x 2mm = 10mm
Sy = 5 x 3mm = 15mm

and the size of the BSpline Grid should have a number of nodes

Nx = ( 300 - 1 ) * 2mm / Sx = 299 * 2 / 10 ~= 60
Ny = ( 400 - 1 ) * 3mm / Sy = 399 * 3 / 15 ~= 80


All this is assuming the simple case in which the direction of the
image is an identity matrix.

If that is not the case, then the  best way to find all these
parameters is to use the TransformIndexToPhysicalPoint
method of the image, and to feed it with the Index locations
of the nodes in the image that you want to be the corners of
the BSpline region.

Take also into account that, you need to add one extra
BSpline Grid node around the region that you are deforming
(if you are using  Cubic BSpline).


The BSplineDeformable transform does not have landmarks per se,
but one could argue that in fact all the nodes of the BSpline grid
are equivalent to landmarks, since the provide anchors for the
deformation values.

In all this process, it is very very helpful to sketch the grid of
your image in a piece of paper and add to it physical values
of origin, spacing...etc.  In this way you can follow the computation
of all the parameters in the BSpline grid.


   Hope this helps,


         Luis




On Thu, Dec 26, 2013 at 8:14 PM, 冯婷婷 <fttfzzx227 at 126.com> wrote:

> Hi,
> I'm using itkBSplineDeformableTransform to implement a local deformable
> transform of an image in order to get a moving image with local
> deformation. I havetwo questions about this class,can anybody help me with
> these?
>
> (1) Can itkBSplineDeformableTransform achieve the goal of local
> deformation?How can I implement this?Can I set the origin to the local
> place and set the origin only a local region?
> (2)What does the parameters mean ,are they the landmark or else?If I want
> to write a new parameter file on my own ,can anybody give me a model to
> follow or specify the meaning for me ?
> Any help would be appreciated ,many thanks!
>
> Best regards!
> Tina
>
>
>
>
> _____________________________________
> 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://www.itk.org/mailman/listinfo/insight-users
>
> _______________________________________________
> Community mailing list
> Community at itk.org
> http://public.kitware.com/cgi-bin/mailman/listinfo/community
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20131229/fad3a3b6/attachment.htm>


More information about the Insight-users mailing list