Hi all,
I am using whereami -mask_atlas_region to save out some brainstem/cerebellum masks that are subsequently combined into a single mask for later analysis. I previously had no issues with this using AFNI v19.0.25 and using the following command after using @SUMA_Make_Spec_FS:
@MakeLabelTable -atlasize_labeled_dset aparc.a2009s+aseg_rank.nii -replace
whereami -atlas aparc.a2009s+aseg_rank -mask_atlas_region aparc.a2009s+aseg_rank::brain-stem
whereami -atlas aparc.a2009s+aseg_rank -mask_atlas_region aparc.a2009s+aseg_rank::Cerebellum
whereami -atlas aparc.a2009s+aseg_rank -mask_atlas_region aparc.a2009s+aseg_rank::Cerebellum-WhiteMatter
whereami -atlas aparc.a2009s+aseg_rank -mask_atlas_region aparc.a2009s+aseg_rank::VentralDC
# Combine separate masks into a single mask
3dMean -prefix Cerebellum_BrainStem_Mask_{$subj} -mask_union \
aparc.a2009s+aseg_rank.brain-stem+orig \
aparc.a2009s+aseg_rank.Cerebellum+orig \
aparc.a2009s+aseg_rank.Cerebellum-WhiteMatter+orig \
aparc.a2009s+aseg_rank.VentralDC+orig
I recently updated from AFNI v19.0.25 to v21.0.03 and the atlas now separates left and right cerebellum. This is not an issue and I updated my code to reflect some of the comments in this thread. My new code is below:
@MakeLabelTable -atlasize_labeled_dset aparc.a2009s+aseg.nii -replace
whereami -atlas aparc.a2009s+aseg -mask_atlas_region aparc.a2009s+aseg::Brain-Stem
whereami -atlas aparc.a2009s+aseg -mask_atlas_region aparc.a2009s+aseg::Left-Cerebellum-Cortex
whereami -atlas aparc.a2009s+aseg -mask_atlas_region aparc.a2009s+aseg::Right-Cerebellum-Cortex
whereami -atlas aparc.a2009s+aseg -mask_atlas_region aparc.a2009s+aseg::Left-Cerebellum-White-Matter
whereami -atlas aparc.a2009s+aseg -mask_atlas_region aparc.a2009s+aseg::Right-Cerebellum-White-Matter
whereami -atlas aparc.a2009s+aseg -mask_atlas_region aparc.a2009s+aseg::Left-VentralDC
whereami -atlas aparc.a2009s+aseg -mask_atlas_region aparc.a2009s+aseg::Right-VentralDC
# Combine separate masks into a single mask
3dMean -prefix Cerebellum_BrainStem_Mask_{$subj} -mask_union \
aparc.a2009s+aseg.Brain-Stem+orig \
aparc.a2009s+aseg.Left-Cerebellum-Cortex.l+orig \
aparc.a2009s+aseg.Right-Cerebellum-Cortex.r+orig \
aparc.a2009s+aseg.Left-Cerebellum-White-Matter.l+orig \
aparc.a2009s+aseg.Right-Cerebellum-White-Matter.r+orig \
aparc.a2009s+aseg.Left-VentralDC.l+orig \
aparc.a2009s+aseg.Right-VentralDC.r+orig
There now is consistently a gap in my mask in medial cerebellum, however. See attached images of the union mask created by 3dMean with an overlay showing disparities between what I think is being called from the overlaid aparc.a2009s+aseg dataset and my new underlay mask. There seems to be portions of medial cerebellum included in the atlas overlay that are not being included in my whereami call and I’m not sure why this is happening. I feel like I’m missing something obvious but am at a loss?
-Walker