questions about draw ROI plugin

Hello,
Hope you’re all doing well! I have a simple question about the draw ROI plugin.
I’m interested in import some atlas regions as ROIs, and I’m interested in the Glasser HCP atlas. I learned that I can use whereami from the documentation, for example this is the command I tried:
$whereami -mask_atlas_region MNI_Glasser_HCP_v1.0:left:L_Primary_Visual_Cortex -prefix roi.lv1.mni

When I looked at the generated ROI in a subject’s MNI warped anat (e.g., subj_anat_tlrc) volume, it looks about right, which is great. But I also saw the video where the interactive draw ROI plugin was used. So I loaded subj_anat_tlrc, then start the plugin, copy the dataset, then choose the same atlas, choose left primary visual cortex, click Load:overwrite. Now I get the pink ROI in the image, which is way off. I had assumed that the two methods (command line above) and this interactive way of doing things are equivalent, but apparently that’s not the case. I’m probably doing something wrong here, but it’s not obvious to me. Could you advise?

While on the same topic, I’m just curious, how does AFNI keep track of different template spaces? For example, while loading the same anat, I can apparently choose the TT_Daemon as the atlas, But I thought that one is in the Tailarach space. Does AFNI automatically perform spatial transformation if I load a region from TT_Daemon? Incidentally, I did try to load Boradmann area 17, and it is actually quite close (the purple region in the image). I don’t understand–the Glasser atlas is supposed in the same space but it’s way off, yet the TT_Daemon is in a different space, but it looks Ok.

Thank you very much.

Best,

–Taosheng

lv1_overlay.jpg

The Draw ROI/Dataset plugin uses atlases that match the grid of the templates on which they are based. That HCP Glasser atlas was on a 256^3 grid instead of the MNI 2009c grid. I have adjusted the atlas grid to match. It should be available in new distributions, but you can get that atlas specifically from:

https://afni.nimh.nih.gov/pub/dist/atlases/current/MNI_Glasser_HCP_v1.0.nii.gz

Replace the one in your abin directory with this one. Thanks for letting me know about this.

Thank you, Daniel. This works now. I’m glad I found this out.
For the second part of my original question, i.e., does AFNI do automatic conversion when loading atlas ROIs, do you have any advice? I looked at Broadman area 17 from TT_Daemon on my MNI 2009c tlrc brain, it’s roughly in the right location, but it doesn’t look as good (e.g., a lot of zagged and missing part) as the newly fixed left V1 from the Glasser atlas. So I assume AFNI doesn’t do automatic conversion, and the user has to make sure the atlas and the underlying anatomy is in the same space, right?
Thank you for your help!

–ts

That’s right. The plugin doesn’t transform the atlases across template spaces. The whereami GUI and command line transforms coordinates (xyz to xyz) but not ROIs, but it’s limited to affine, 2-piece and 12-piece manual transformations. Atlases are associated with specific templates, so you will need to be careful about which atlas and template pair you use. Both MNI and Talairach cover a large variety of specific templates, and it’s not always obvious which one is used for a particular atlas.

For the simple case where the data has been aligned to a specific template, and the atlas is in the same template space, you can just use 3dresample to put the atlas region into the grid of the dataset. For other cases, you would need to compute transformations and apply them to the atlases. That may be more trouble than you would like.