how to make AFNI talk to SUMA

AFNI version info (afni -ver): AFNI_23.2.12

Hi,
I’d like to use SUMA to visualize a t-map, but I have the impression that I can’t make AFNI and SUMA to talk properly.

I’d like to use info derived from Schaefer parcellation, so I downloaded the brain surface in the ‘archive’ folder from here:
https://afni.nimh.nih.gov/pub/dist/atlases/SchaeferYeo/

From the downloaded folder, I went into this directory ../schaefer_yeo/sy_vol/schaefer_yeo/suma_MNI152_2009 (I also tried with MNI_N27) and put my t map here.

Then, I launched both AFNI and SUMA:
afni -niml & suma -spec MNI_N27_both.spec -vol MNI_N27_SurfVol.nii

Initializing: X11[The X.Org Foundation v 12101006].                                                                                             €€€€€€€€€€€€€€€€€€€€€€€                         ÿÿÿÿÿÿÿÿÿÿÿÿÿÿ
++++++++ IMAGE SAVE SETUP WARNINGS ++++++++                                                                                                                                                                   
++ Can't find program ffmpeg for Save to MPEG-1                                                                                                 €€€€€€€€€€€€€€€€€€€€€€€                         ÿÿÿÿÿÿÿÿÿÿÿÿÿÿ
++ To disable these warnings, set environment                                                                                                   Ì P#è#H#Ì #˜#ø#Ì (#À# #Ì P#è#H#Ì x##p#Ì  #8#˜#Ì È#`#À#Ì ð#ˆ#
++  variable AFNI_IMSAVE_WARNINGS to 'NO'.                                                                                                                                                                    
+++++++++++++++++++++++++++++++++++++++++++++                                                                                                   €€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€          ÿÿÿÿÿÿÿÿÿÿÿÿÿÿ

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #1/14(Local Domain Parent), loading ...
. Widgets...... Input files:+/Users/ns/Desktop/schaefer_yeo/sy_vol/schaefer_yeo/suma_MNI_N27
 session #  1  = suma_MNI_N27/ ==> 39 datasets
 dataset count = 39
 Timeseries.1D = 3 files read
 .[tc]sv data  = 0 files read
*** WARNING: Identical ID codes in /Users/ns/Desktop/schaefer_yeo/sy_vol/schaefer_yeo/suma_MNI_N27/aparc+aseg_rank.nii and /Users/ns/Desktop/schaefer_yeo/sy_vol/schaefer_yeo/suma_MNI_N27/aparc+aseg_rank.nii.gz
*** WARNING: Identical ID codes in /Users/ns/Desktop/schaefer_yeo/sy_vol/schaefer_yeo/suma_MNI_N27/aparc.a2009s+aseg_rank.nii and /Users/ns/Desktop/schaefer_yeo/sy_vol/schaefer_yeo/suma_MNI_N27/aparc.a2009s+aseg_rank.nii.gz
*** WARNING: Identical ID codes in /Users/ns/Desktop/schaefer_yeo/sy_vol/schaefer_yeo/suma_MNI_N27/aseg_rank.nii and /Users/ns/Desktop/schaefer_yeo/sy_vol/schaefer_yeo/suma_MNI_N27/aseg_rank.nii.gz

Path(s) to be searched for plugins: 
/Users/ns/abin /Users/ns/abin/../lib 

 Plugins       = 49 libraries read

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #8/14(Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #2/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #3/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #4/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #5/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #6/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #7/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #9/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #10/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #11/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #12/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #13/14 (mappable via Local Domain Parent), loading ...

vvvvvvvvvvvvvvvvvvvvvvvvvvvvSurface #14/14 (mappable via Local Domain Parent), loading ...
++ AFNI is detached from terminal.
SUMA_Engine: Starting to listen ...

++ NOTE: This version of AFNI was built Sep 29 2023 ++
++ NOTE: 'Define Markers' is hidden: right-click 'DataDir' to see it
++ NOTE: Use '-seehidden' option to see which plugins are hidden
++ NOTE: you may want to consider creating a '.afnirc' file in your home
         directory, to control AFNI's setup.  For more details, see
   https://afni.nimh.nih.gov/pub/dist/doc/program_help/README.environment.html

In AFNI I’m using MNI_N27_SurfVol.nii as underlying and my t-map in the overlay. Then I go into the SUMA window and hit ‘t’ to make the them talk, but nothing basically happens.

SUMA_niml_call: Contacting on tcp:localhost:53211 (0), maximum wait 2.000 sec 
(You can change max. wait time with env. SUMA_DriveSumaMaxWait)
SUMA_niml_call: Trying local connection...
++ NIML connection opened from 127.0.0.1 (tcp:host:53211,AFNI_SUMA_NIML)

I saw on various videos on youtube that the ‘talk’ between AFNI and SUMA is essentially istantaneuous, but my t-map doesn’t show up in SUMA.

Am I doing something wrong?

Thanks,
Nicola

Hi, Nicola-

Hm, everything there looks correct, including what the terminal text displays after hitting 't' in the SUMA GUI.

One thing to check: do you have any other AFNI/SUMA windows open when you try to make this specific pair talk? For default talking, you should not have any other AFNI/SUMA GUIs open, so there is no confusion about who is sending/receiving. You can have more complicated setups, but those require using additional options: when you want to have lots of GUIs open and have one or more pairs talking, you would use port numbers to specify what "channels" each pair should talk on.

What OS are you running on? And just to check, do you have the AFNI Bootcamp data on your computer? We could try with that and see if things work as a baseline test, but it is hard to see what why that would work if your current test didn't.

--pt

Hi Paul,
when calling afni and SUMA I tried -sv instead of -vol and now the 'talk' seems to work.
Is it possible that this would make the difference?

Since my original goal was to show a t-map of results obtained with the Schaefer parcellation, I'd like to know if there is a way to show in SUMA the boarder of that parcellation (or others).

Thanks,
Nicola

Hi, Nicola-

Oh my, indeed, the "-sv .." is needed to establish the relations between SUMA and AFNI. This is the run.suma.00.both.141 script we include in the Bootcamp teaching example (in directory AFNI_data6/FT_analysis/FT/SUMA/):

suma  -spec std.141.FT_both.spec -sv FT_SurfVol.nii &

Sorry I didn't spot that above.

From the suma GUI help about -sv .., there is the comment:

This parameter is optional, but linking to AFNI is 
not possible without it.

Here is what it looks like to display:

Before I started the GUIs talking:

  • I opened SUMA's Surface Controller (ctrl+s) -> Load Dset (lower left-ish in the controller) and selected the parcellation of interest;
  • when it was showing, changed the "Dsp" button just above that "Load Dset" to be "Con", to show only the contours of that parcellation.

--pt

I apologize for the naive mistake. I've looked at the documention for days without seeing what seems obvious now.

Thanks much for the description on how to visualize a dset in SUMA- that's exactly what I needed and it works smoothly.

Nicola

Hi, Nicola-

Not naive at all, and it is easy to swap those option names---I certainly saw it and didn't notice it. I put the doc comments there so anyone reading this thread in the future who is less familiar with these things can see it; hopefully that will help make it easier to understand and troubleshoot.

Glad the other visualization aspects worked.

--pt