# Transforming to the Jacobian Domain

I need to understand what is tx in ANTspy
Can the TX be the MNI152_T1_1mm_brain.nii.gz file?
Using flirt, I aligned the T1w together by setting one T1w image as the reference and aligned the rest on it.
The ref T1w was transformed to MNI152 first before using it. Now I want to use ants to transform to the Jacobian domain, So what’s the correct way to use the below function to transform the T1w images to jacobian?

``````def create_jacobian_determinant_image(domain_image, tx, do_log=False, geom=False):
"""
Compute the jacobian determinant from a transformation file

ANTsR function: `createJacobianDeterminantImage`

Arguments
---------
domain_image : ANTsImage
image that defines transformation domain

tx : string
deformation transformation file name

do_log : boolean
return the log jacobian

geom : bolean
use the geometric jacobian calculation (boolean)

Returns
-------
ANTsImage

Example
-------
>>> import ants
>>> fi = ants.image_read( ants.get_ants_data('r16'))
>>> mi = ants.image_read( ants.get_ants_data('r64'))
>>> fi = ants.resample_image(fi,(128,128),1,0)
``````

Hi @Yasmine,

`tx` refers to the transformation of interest, as produced by ANTs. The jacobian determinant is a property related to the transform, and is not a space to align images to.

Best,
Steven

So MNI152 can be the transformation of interest, for example?

The transformation to MNI, yes. But for this to work you will probably have to use ANTs to register, I doubt it will accept FLIRT files.

1 Like