Registration to/from MNI space

549 views
Skip to first unread message

christoph...@biomedica.udec.cl

unread,
Dec 13, 2020, 5:55:06 PM12/13/20
to DSI Studio
Hello Dr. Yeh,

I apologize in advance if this question is too basic or if it is already covered in the documentation, I'm quite new to DSI Studio and to tractography analysis in general.

I have preprocessed dMRI images, created the SRC files and then reconstructed using the DTI method. In the Fiber Tracking step, I noticed that using Slices > Insert MNI images, I can open a MNI template (specifically avg152T1 from SPM), and it automatically aligns itself with the subject's native space (where the FA, MD, etc. are).

1) How is this registration calculated? I assume it's a combination of an affine transformation plus a non-linear deformation.

2) Is there a way to extract this transformation and save it externally to the hard drive?

3) If the previous point is possible, is there also a way to obtain the inverse transformation (i.e. one that transforms the FA from native to MNI space)? My intention is to apply a spatial transformation to a set of tracts in order to take them from the subject's space to MNI.

Thank you very much in advance, any help would be greatly appreciated.

-Christopher

Frank Yeh

unread,
Dec 14, 2020, 7:33:09 PM12/14/20
to dsi-s...@googlegroups.com
Hi Christopher,

No problem at all. These are actually not trivial questions:

>
> 1) How is this registration calculated? I assume it's a combination of an affine transformation plus a non-linear deformation.

Yes, you are correct.

>
> 2) Is there a way to extract this transformation and save it externally to the hard drive?

The newer version of DSI Studio will save the transformation map to a
*.inv.mapping.gz or *.mapping.gz file that can be loaded afterward.

>
> 3) If the previous point is possible, is there also a way to obtain the inverse transformation (i.e. one that transforms the FA from native to MNI space)? My intention is to apply a spatial transformation to a set of tracts in order to take them from the subject's space to MNI.

You may load the files in MATLAB (first unzip them and rename the
files as .mat). There will be a mapping matrix inside that you can
"reshape" to get its 3D form. You may check out how FIB file can be
accessed and matrices rehaped in MATLAB,
http://dsi-studio.labsolver.org/Manual/export-data-to-matlab

Best,
Frank
>
> Thank you very much in advance, any help would be greatly appreciated.
>
> -Christopher
>
> --
> You received this message because you are subscribed to the Google Groups "DSI Studio" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to dsi-studio+...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/dsi-studio/1fad167d-fb50-4419-a786-cf846f808959o%40googlegroups.com.

chrver...@gmail.com

unread,
Dec 15, 2020, 9:30:16 AM12/15/20
to DSI Studio
Thank you very much for your answer Dr. Yeh.

I was now able to find the mapping.gz file. However, I have further questions regarding it, if you could help me.

As the amount of elements in the mapping are equal to the number of voxels in my image (X x Y x Z voxels) times 3, I assume it's telling me the deformation to be applied in each voxel of my original image, and that each of the three numbers tells me the (x,y,z) coordinate of the deformation.

1) Does each element of the mapping inform me of the final coordinate to be assigned to that voxel, or is it telling me the "displacement" I need to apply to said voxel? For instance, if the value for the first voxel is (10,20,30), does that mean the final position is (10,20,30) mm, or that the final position is the original mm coordinates plus (10,20,30) mm?

2) I used the reshape function to transform the mapping to the dimensions of my original image. What is the orientation of the resulting matrix? What I mean by this, starting from the first element, if I advance further down the matrix in which direction am I advancing (left/right, anterior/posterior, superior/inferior)?

I apologize in advance if my wording is deficient. Thank you very much in advance.

Christopher

El lunes, 14 de diciembre de 2020, 21:33:09 (UTC-3), Frank Yeh escribió:
Hi Christopher,

     No problem at all. These are actually not trivial questions:

>
> 1) How is this registration calculated? I assume it's a combination of an affine transformation plus a non-linear deformation.

Yes, you are correct.

>
> 2) Is there a way to extract this transformation and save it externally to the hard drive?

The newer version of DSI Studio will save the transformation map to a
*.inv.mapping.gz or *.mapping.gz file that can be loaded afterward.

>
> 3) If the previous point is possible, is there also a way to obtain the inverse transformation (i.e. one that transforms the FA from native to MNI space)? My intention is to apply a spatial transformation to a set of tracts in order to take them from the subject's space to MNI.

You may load the files in MATLAB (first unzip them and rename the
files as .mat). There will be a mapping matrix inside that you can
"reshape" to get its 3D form. You may check out how FIB file can be
accessed and matrices rehaped in MATLAB,
http://dsi-studio.labsolver.org/Manual/export-data-to-matlab

Best,
Frank
>
> Thank you very much in advance, any help would be greatly appreciated.
>
> -Christopher
>
> --
> You received this message because you are subscribed to the Google Groups "DSI Studio" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to dsi-s...@googlegroups.com.

Frank Yeh

unread,
Dec 15, 2020, 9:36:46 AM12/15/20
to dsi-s...@googlegroups.com
> As the amount of elements in the mapping are equal to the number of voxels in my image (X x Y x Z voxels) times 3, I assume it's telling me the deformation to be applied in each voxel of my original image, and that each of the three numbers tells me the (x,y,z) coordinate of the deformation.

Yes

>
> 1) Does each element of the mapping inform me of the final coordinate to be assigned to that voxel, or is it telling me the "displacement" I need to apply to said voxel? For instance, if the value for the first voxel is (10,20,30), does that mean the final position is (10,20,30) mm, or that the final position is the original mm coordinates plus (10,20,30) mm?

It is the final coordinate.

>
> 2) I used the reshape function to transform the mapping to the dimensions of my original image. What is the orientation of the resulting matrix? What I mean by this, starting from the first element, if I advance further down the matrix in which direction am I advancing (left/right, anterior/posterior, superior/inferior)?

The orientation is LPS.
Frank
> To unsubscribe from this group and stop receiving emails from it, send an email to dsi-studio+...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/dsi-studio/1c8c611a-018b-4ed1-b282-a9dd8959cc01o%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages