Summary of what happened:
I am preprocessing some PET data to be used as example data for a computational lab class for undergrads. I inherited some very old partial PET NIFTIs associated with Volkow et al (2009) from a colleague. The PET NIFTIs appear to have been preprocessed in the long past but I have no record of what was done to them.
I have a decent amount of experience working with BOLD fMRI but basically none with PET until this project, heh.
I would like for students to be able to average the subject-specific PET timeseries together for their condition of interest to get one across-subjects timeseries mean. They would then select a seed ROI based on xyz coordinates to use to extract signal and calculate receptor binding potential. In order for images to be averageable across subjects, they must of course be registered to the same template image. An MRI template was provided (no documentation on what image this is, but based on the paper it might be an old SPM anatomical template), so I am trying to register each of the PET timeseries to this MRI template.
I am trying to use ANTs to:
- Create a PET template for each PET timeseries by meaning images together (SUCCESSFUL)
- Register each scan-specific PET template to the MRI template, apply registration to the timeseries image. I would like to keep it to rigid-body registration if possible, so I have been using
type_of_transform=’AffineFast’, but everything else left as default. (ISSUES HERE)
I’ve gotten the code to run all the way through to attempt registrations on every timeseries. A couple of the registrations look all right, but most of them just look awful! Seeking advice on other pre-processing transforms that can be applied, other transform algorithms, or other issues to check to improve the bad registrations.
Screenshots / relevant information:
EXAMPLE OF BAD REGISTRATIONS
Overlay of mean PET template on MRI BEFORE registration. You can see that the affine for the original PET images is very much not in the neighborhood of the MRI template to start, but the mean PET image does at least show some brain-shape that could be registered.
Overlay AFTER registration. Equally bad but different!
Command used (and if a helper script was used, a link to the helper script or the command generated):
import ants
template_img = ants.image_read('MRI_Template.nii')
pet_img = ants.image_read('PET_timeseries.nii')
# mean over timeseries for PET template
mean_img = ants.from_numpy_like(
data=pet_img.mean(axis=3),
image=ants.slice_image(pet_img, axis=3, idx=0)
)
# calculate rigid body registration
reg = ants.registration(fixed=template_img, moving=mean_img, type_of_transform='Affine')
# apply registration
pet_warped = ants.apply_transforms(fixed=template_img, moving=pet_img, transformlist=reg['fwdtransforms'], imagetype=3)
mean_warped = ants.apply_transforms(fixed=template_img, moving=mean_img, transformlist=reg['fwdtransforms'])
# this generates the plot screenshots
ants.plot(image=template_img,overlay=mean_warped, overlay_alpha=0.8, overlay_cmap='viridis')


