ANTsX / ANTs

Advanced Normalization Tools (ANTs)
Apache License 2.0
1.21k stars 381 forks source link

PET-MR Registration #785

Closed guilhermepovala closed 5 years ago

guilhermepovala commented 5 years ago

Hi,

I have the PET and MR images obtained from ADNI for the same patient. First, I perform an MR registration using the MNI template. After this, I want to co-register the patient's PET image to its MR preregistered with the MNI template.

What's the best way to do this? I've already tried the antsRegistrationSyN.sh script but did not get great results. Do I have to perform some preprocessing with the PET image?

ntustison commented 5 years ago

Hi,

Your description is a bit unclear. Can you provide the commands you used to perform your set of registrations?

guilhermepovala commented 5 years ago

Sure.

T1 registration

../antsRegistrationSyNQuick.sh -d 3 -f ../Atlas/MNI152/mni_icbm152_t1_tal_nlin_asym_09c.nii.gz -m t1.nii -o reg/reg

T1 brain extraction

../antsBrainExtration.sh -d 3 -a reg/regWarped.nii -e ../Atlas/MNI152/mni_icbm152_t1_tal_nlin_asym_09c.nii.gz -m ../Atlas/MNI152/mni_icbm152_t1_tal_nlin_asym_09c_mask.nii.gz -o bext/bext

PET-T1 registration

../antsRegistrationSyNQuick.sh -d 3 -f bext/bextN4Corrected0.nii.gz -m pet.nii -o regpet

guilhermepovala commented 5 years ago

The brain extraction is there because next, I'll make a PVC.

ntustison commented 5 years ago

Okay, great. Thanks.

In setting up these processing scenarios, one wants to exploit as much prior knowledge as possible. In this case, you want to exploit the fact that the PET image and pre-registered T1 are from the same brain and can most likely be aligned using just a rigid transform. What you're trying to do is align the PET image with the deformed T1 which requires the additional degree of flexibility afforded by a deformable transform and the only prior knowledge exploited by the deformable transform is that it be "smooth." So one is able to leverage more prior knowledge in the former case vs. the latter. Rearranging your commands, you want to do:

# Rigidly align PET to T1
antsRegistrationSyNQuick -d 3 -f T1.nii -m PET.nii -t r -o reg/T1xPET
# Register T1 to MNI
antsRegistrationSyNQuick -d 3 -f MNI.nii -m T1.nii -o reg/MNIxT1
# Warp PET to MNI
antsApplyTransforms -d 3 -v 1 -i PET.nii -r MNI.nii -o PET_warped_to_MNI.nii -n Linear -t reg/MNIxT11Warp.nii.gz -t reg/MNIxT10GenericAffine.mat -t reg/T1xPET0GenericAffine.mat 
guilhermepovala commented 5 years ago

It worked like a charm. Thanks for the explanation.