[RESOLVED] Difficulty getting group-level results with fc_compute_gbc

Description:

I have successfully run fc_compute_gbc to get individual session GBC pscalar output.
I would like to run the exact same analysis, but additionally get the group-level mean and a concatenated file that includes all the sessions that I input. So I added the option savegroup to the options parameter and set it to mean,sessions. I also added the targetf parameter and specified the full path where I would like the group-level results to go. However, I do not receive any outputs in this location or the location that I run the command from (I tried in my home folder, and in the location where I want the output to go.) I still receive the individual-level results. I also tried setting saveind=none and only try one option for savegroup at a time (e.g. just sessions or mean) but that did not help.

The issue is difficult to troubleshoot because fc_compute_gbc does not produce runlogs or comlogs. The error in the command log is difficult for me to understand.

Input list:
group_test_AP_ptseries.list

session id: BI02450_20230328
    file:/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI02450_20230328/images/functional/bold1_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii
    file:/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI02450_20230328/images/functional/bold3_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii
session id: BI05529_20230619
    file:/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI05529_20230619/images/functional/bold1_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii
    file:/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI05529_20230619/images/functional/bold3_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii
session id: BI05874_20230525
    file:/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI05874_20230525/images/functional/bold1_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii
    file:/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI05874_20230525/images/functional/bold3_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii

Call:

qunex_container fc_compute_gbc \
--container="/gpfs/gibbs/pi/n3/software/Singularity/qunex_suite-1.0.3.sif" \
--sessionsfolder="/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions" \
--logfolder="/gpfs/gibbs/pi/n3/Studies/PREDICT/processing/logs" \
--flist="/gpfs/gibbs/pi/n3/Studies/PREDICT/processing/lists/group_test_AP_ptseries.list" \
--command='mFz:0' \
--parjobs=1 \
--targetf="/gpfs/gibbs/pi/n3/Studies/PREDICT/analysis/rsFC/GBC" \
--options='sessions=all|eventdata=all|ignore=udvarsme|badevents=use|fcmeasure=r|savegroup=sessions|saveind=none|savesessionid=false|itargetf=sfolder|rsmooth=|rdilate=|vstep=1000|time=true|verbose=true|debug=true' \
--scheduler=SLURM,time=05:00:00,mem-per-cpu=32000,partition=pi_anticevic,mail-type=all,nodes=1,cpus-per-task=1

Log:
/gpfs/gibbs/pi/n3/Studies/PREDICT/processing/logs/batchlogs/qunex_container_2025-01-13_14.47.57.423985.txt

.......................... Running QuNex v1.0.3 [QIO] ..........................


--- Full QuNex call for command: fc_compute_gbc

qunex fc_compute_gbc --sessionsfolder="/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions" --logfolder="/gpfs/gibbs/pi/n3/Studies/PREDICT/processing/logs" --flist="/gpfs/gibbs/pi/n3/Studies/PREDICT/processing/lists/group_test_AP_ptseries.list" --command="mFz:0" --targetf="/gpfs/gibbs/pi/n3/Studies/PREDICT/analysis/rsFC/GBC" --options="sessions=all|eventdata=all|ignore=udvarsme|badevents=use|fcmeasure=r|savegroup=sessions|saveind=none|savesessionid=false|itargetf=sfolder|rsmooth=|rdilate=|vstep=1000|time=true|verbose=true|debug=true"

---------------------------------------------------------



Running:
>>> fc_compute_gbc('/gpfs/gibbs/pi/n3/Studies/PREDICT/processing/lists/group_test_AP_ptseries.list', 'mFz:0', '', '', '', '/gpfs/gibbs/pi/n3/Studies/PREDICT/analysis/rsFC/GBC', 'sessions=all|eventdata=all|ignore=udvarsme|badevents=use|fcmeasure=r|savegroup=sessions|saveind=none|savesessionid=false|itargetf=sfolder|rsmooth=|rdilate=|vstep=1000|time=true|verbose=true|debug=true')


fc_compute_gbc options used:
---------------------------
      sessions: all
     eventdata: all
        ignore: udvarsme
     badevents: use
     fcmeasure: r
     savegroup: sessions
       saveind: none
 savesessionid: false
      itargetf: sfolder
       rsmooth: 
       rdilate: 
         vstep: 1000
       verbose: true
         debug: true
          time: true


Checking ...
... found results folder (/gpfs/gibbs/pi/n3/Studies/PREDICT/analysis/rsFC/GBC)
ans = [](0x0)
 ... listing files to process
 ... reading file list: 
     - session id: BI02450_20230328
       ... found image file (/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI02450_20230328/images/functional/bold1_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii)
       ... found image file (/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI02450_20230328/images/functional/bold3_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii)

     - session id: BI05529_20230619
       ... found image file (/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI05529_20230619/images/functional/bold1_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii)
       ... found image file (/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI05529_20230619/images/functional/bold3_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii)

     - session id: BI05874_20230525
       ... found image file (/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI05874_20230525/images/functional/bold1_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii)
       ... found image file (/gpfs/gibbs/pi/n3/Studies/PREDICT/sessions/BI05874_20230525/images/functional/bold3_Atlas_s_hpss_res-mVWMWB1d_lpss_BOLD-CAB-NP-v1.0.ptseries.nii)

 ... done ... done.

---------------------------------
Processing session BI02450_20230328
     ... creating ROI masks
     ... done
     ... reading image file(s)
         -> 666 frames read, done.
     ... generating extraction sets ...
img_get_extraction_matrices options used:
----------------------------------------
    ignore: udvarsme
 badevents: use
   verbose: true
     debug: true
 done.
     ... computing gbc
         ... set timeseries
         ... extracted ts

img_compute_gbc_fc
... setting up data
... starting GBC on 
... 718 voxels & 616 frames to process in 1 steps
... computing GBC for voxels:
     ...          1:718
     -> fc [0.016 s]
     -> clip [0.000 s]
     -> Fz [0.016 s]
     -> mFz [0.000 s]
... done! [0.053 s]
         ... computed gbc maps

Matlab Error! Processing Failed!
subsasgn: invalid object


ERROR: fc_compute_gbc failed! Please check output / log!

Hi,

we have encountered this problem recently and it will be fixed in the next version of qunex. In the meantime, you can enter the qunex container interactively and add the following code to line 772 in fc_compute_gbc.m

                gbcmaps(n).gbc = nimage();

I have already run the call with this change, you can find the results in /gpfs/gibbs/pi/n3/Studies/PREDICT/analysis/rsFC/GBC

1 Like

Hi,

The fix for this will be included in QuNex 1.0.4, which we plan to release later this week.

Best, Jure