Final warp computed is not diffeomorphic


#1

I have two T1 weighted images of the knee from the same subject and with the same intensity range that I want to align nonlinearly using:

mrregister -type rigid_affine_nonlinear image1.mif image2.mif -nl_warp_full warp.mif

but I get the following warning:

mrregister: [WARNING] final warp computed is not diffeomorphic (negative jacobian determinants detected). Try increasing -nl_disp_smooth or -nl_update_smooth regularisation.

and the resulting images are not aligned well.

The reason I want to do it nonlinearly is because the patient moved, causing slightly different configuration of the joint, which prevents linear registration.

I tried increasing both -nl_disp_smooth and -nl_update_smooth but I keep getting the same warning. What is the general advice to changing these parameters and tackling the above issue? Should this kind of application even work with mrregister?