How to Rotate Mouse Brain MRI for quick AFNI Registration

There are similar problems as in the original post; the orientation of those datasets is not correct, and they are differently incorrect. By looking at this in the AFNI GUI, it becomes apparent, the sagittal, axial and coronal views are not correctly set. The solution is to "refit" the header of the dataset with the correct orientation. to3d provides one way to fix the header. By opening the dataset with the to3d GUI, the orientation can be found by looking across the image, down the image and across the slices and noting the first letter of each of the directions. We can't know left from right here, so there are just assumpltions to make this more consistent, but hopefully you will know that from some other clues in the anatomy of these particular mice.

# find dimensions in number of voxels in i,j,k with 3dinfo
3dinfo 01_T2_1_refit.nii
# use those dimensions here when starting to3d, use "View images"
# can ctrl-c to exit or exit without saving
to3d '3D:-1:0:192:192:52:01_T2_1_refit.nii'
# refit the orientation from what was found in the GUI
3drefit -orient RSA 01_T2_1_refit.nii

Similarly do that for the RARE dataset. That's slightly more complicated because it is also an oblique dataset.

3dinfo dicom_T2_TurboRARE_20230607141101_20001.nii
3drefit -orient LIP -deoblique dicom_T2_TurboRARE_20230607141101_20001.nii

These two datasets now line up with each other.

Unfortunately, the template with its 800um resolution is far too large for a mouse, but I don't know what it should be. In the meantime, you could use another template and atlas, like the Allen mouse brain here. See the previous thread here:

and here:

Depending on the size of the volumetric changes, the segmentation quality will be limited by voxel resolution, and I wouldn't expect VBM to be particularly useful. Alternative methods may work better.