Hi, Maya-
After running FreeSurfer’s recon-all, do you run AFNI’s @SUMA_Make_Spec_FS? That should provide most of the dsets you would want in NIFTI (and/or GIFTI) format, with some nice properties, too. Some description of running @SUMA_Make_Spec_FS after recon-all is given here:
https://afni.nimh.nih.gov/pub/dist/doc/htmldoc/tutorials/fs/main_toc.html
Some of the convenient outputs are provided here:
https://afni.nimh.nih.gov/pub/dist/doc/htmldoc/tutorials/fs/fs_makespec.html
The REN files are particularly nice: they are renumbered+labeltabled FreeSurfer segmentation maps (both the aparc+aseg and aparc2009 varieties). When opened in AFNI, they have ROI-like colorbars. There are several useful ones, including all the FS ROIs in one dset, but “families” that are convenient. Myself, I really like having the “ROI-like” GM as a single file, REN_gmrois (FS has both GM ROIs and GM “dots” that are left over in the GM map). I recently had some afni_proc.py commands and I defined the following dsets of interest (the full parcellation and GM-ROI-like parcellation subset, for both of FS’s output atlases):
set roi_all_2000 = ${sdir_suma}/aparc+aseg_REN_all.nii.gz
set roi_gmr_2000 = ${sdir_suma}/aparc+aseg_REN_gmrois.nii.gz
set roi_all_2009 = ${sdir_suma}/aparc.a2009s+aseg_REN_all.nii.gz
set roi_gmr_2009 = ${sdir_suma}/aparc.a2009s+aseg_REN_gmrois.nii.gz
… and then included the following anat followers in my afni_proc.py (AP) command:
-anat_follower_ROI a09all anat ${roi_all_2009} \
-anat_follower_ROI e09all epi ${roi_all_2009} \
-anat_follower_ROI a09gmr anat ${roi_gmr_2009} \
-anat_follower_ROI e09gmr epi ${roi_gmr_2009} \
-anat_follower_ROI a00all anat ${roi_all_2000} \
-anat_follower_ROI e00all epi ${roi_all_2000} \
-anat_follower_ROI a00gmr anat ${roi_gmr_2000} \
-anat_follower_ROI e00gmr epi ${roi_gmr_2000} \
… where “a09all …” is the dset of “all” aparc20"09" ROIs output on the final "a"natomical grid, etc.
You might want to define:
set roi_gm_2000 = ${sdir_suma}/aparc+aseg_REN_gm.nii.gz
… and then include this in your AP command:
-anat_follower_ROI a00gm anat ${roi_gm_2000} \
-anat_follower_ROI e00gm epi ${roi_gm_2000} \
You can always “binarize” the output dset with:
3dcalc -a DSET -expr 'bool(a)' -prefix DSET_BINARIZED
… which maps every nonzero value in DSET to 1, leaving everything else 0. (But from the anat follower command, you should have the labels still attached in the mapped parcellation, which is a recent update in AFNI.)
–pt