BSpline deformable transformation


(Seth Ryan) #1

Hello ITK community,

I’m trying to understand how BSpline grid is defined over two images during a multi-resolution registration process. I just need the confirmation for the following thoughts:

  1. BSpline grids are uniform grids, so for example if I have an image 200mmx200mm, then I define a four stage multi-resolution 128,64,32,16mm as the pyramid, the number of grid points for the coarsest resolution (128) would be 1. I saw in the code that Spline Order is added to this (1+3=4) that makes 4 grid points uniformly split the 200x200 image. Is this correct? or the grids are non-uniformely split the image? I’m wondering where exactly 3 other control points are located?
  2. what happens if you have an image 100x100mm then you define 128mm grid size? does the code only consider 3 number of points to split the image?

These might be low level details, but I appreciate if someone could help me figure this out.

Thanks,
Sadeg


(Matt McCormick) #2

Hell Sadeg,

Regarding 1.), Yes, the grid points non-uniformly extend from the image domain. For a third order spline, one extends lower and two extend upper as described in this example.

Regarding 2.) Since the grid is described in physical space, its domain will extend beyond the domain of the input image.

Hope this helps,
Matt


(Seth Ryan) #3

Thanks Matt for the answer.
In question 2, when you say the grids extend beyond the input image domain, does that mean those extended grid points out of input image domain will not be included in the transformation/registration calculation?

What I thought was that in case of 128mm grid size, it splits the 200x200mm input image to 4 grid points.(200/128=1, then 1+3=4). Then 4 grid points would equally divide the input image (each ~50x50mm) and the transformation is characterized without going beyond the image domain.

Thanks,
Sadeg


(Matt McCormick) #4

Hi Sadeg,

In question 2, when you say the grids extend beyond the input image domain, does that mean those extended grid points out of input image domain will not be included in the transformation/registration calculation?

The location of where the matching metric is sampled (the sampling domain) are not directly dependent on the transform.

The B-spline grid is defined in physical space and all images are handled in physical space. At each level of the pyramid, the image is not changing in size. Here is some additional information on the BSpline grid concept and the handling of physical space (crucial for registration) in ITK.

Hope this helps,
Matt


(Gaurav Fotedar) #5

Hi

I have a similar question.
I want to visualize the BSpline gridpoints on the image before and after transformation.
Is there a way to do this?
For now I have tried to visualize the transformation by using TransformToDisplacementField function but I really need to be able to show the transformation of the Bspline grid points.

I also would like to understand why the number of grid points = input grid points + spline order

Any help is appreciated

Regards,
Gaurav