Error in running when analyzing ME data

AFNI version info (afni -ver): (Version AFNI_23.2.10 'Marcus Didius Severus Julianus')

I am experiencing two issues while processing ME data.

  1. When running the following script with the -combine_method OC, I receive the following error message and the index.html file creation fails.
Traceback (most recent call last): File "/usr/local/bin/afni/latest/", line 914, in <module> descrip=descrip )

File "/usr/local/bin/afni/abin_v23.2.10/afnipy/", line 3760, i n apqc_regr_tsnr

111 = com. so[0].split () IndexError: list index out of range                                                         \
            -subj_id                   {$subj}test.complicated                        \
            -blocks                    despike tshift align volreg mask combine surf blur scale regress     \
            -radial_correlate_blocks   tcat volreg                           \
            -blip_forward_dset         $epi_dir/{$subj}_fMRIFieldMap_PA_*.nii           \
            -blip_reverse_dset         $epi_dir/{$subj}_fMRIFieldMap_AP_*.nii           \
            -copy_anat                 $SSW_dir/anatSS.{$subj}.nii                       \
            -anat_follower_ROI         FSvent epi $anat_dir/fs_ap_latvent.nii.gz       \
            -anat_follower_erode       FSvent                                \
            -regress_ROI_PC            FSvent 3                              \
            -regress_ROI_PC_per_run    FSvent                                \
            -regress_make_corr_vols    FSvent                                \
            -dsets_me_echo             $epi_dir/{$subj}_cmrr_mbep2d_bold_MEMB6_REST_*_e1.nii                \
            -dsets_me_echo             $epi_dir/{$subj}_cmrr_mbep2d_bold_MEMB6_REST_*_e2.nii                \
            -dsets_me_echo             $epi_dir/{$subj}_cmrr_mbep2d_bold_MEMB6_REST_*_e3.nii                \
            -dsets_me_echo             $epi_dir/{$subj}_cmrr_mbep2d_bold_MEMB6_REST_*_e4.nii                \
            -dsets_me_echo             $epi_dir/{$subj}_cmrr_mbep2d_bold_MEMB6_REST_*_e5.nii                \
            -echo_times                13 30.99 48.98 66.97 84.96                       \
            -combine_method            OC                                   \
            -tcat_remove_first_trs     0                                     \
            -tshift_interp             -wsinc9                               \
            -mask_epi_anat             yes                                   \
            -align_unifize_epi         local                                 \
            -align_opts_aea            -cost lpc+ZZ                          \
                                       -giant_move                           \
            -volreg_align_to           MIN_OUTLIER                           \
            -volreg_align_e2a                                                \
            -volreg_post_vr_allin      yes                                   \
            -volreg_pvra_base_index    MIN_OUTLIER                           \
            -volreg_warp_final_interp  wsinc5                                \
            -surf_anat                 $anat_dir/{$subj}_SurfVol.nii                \
            -surf_spec                 $anat_dir/std.141.{$subj}_?h.spec            \
            -blur_size                 6                                     \
            -regress_censor_motion     0.2                                   \
            -regress_censor_outliers   0.05                                  \
            -regress_motion_per_run                                          \
            -regress_apply_mot_types   demean deriv                          \
            -html_review_style         pythonic								 \
  1. When I run the above with the m_tedana combine method I receive the following error:

(Note that this is running on a RHEL7 system with 64GB RAM.)

tedana -d pb03.20231221test.complicated.r01.e01.volreg+orig.HEAD pb03.20231221test.complicated.r01.e02.volreg+orig.HEAD pb03.20231221test.complicated.r01.e03.volreg+orig.HEAD pb03.20231221test.complicated.r01.e04.volreg+orig.HEAD pb03.20231221test.complicated.r01.e05.volreg+orig.HEAD -e 13.0 30.99 48.98 66.97 84.96 --mask mask_epi_anat.20231221test.complicated+orig.HEAD --out-dir tedana_r01 --convention orig
INFO     tedana:tedana_workflow:466 Using output directory: /home/sa-j186b025/R-Drive/Martin_L/150353_GETActiveHIIT2/MR_Data/Participants/20231221/Resting/20231221test.complicated.results/tedana_r01
INFO     tedana:tedana_workflow:484 Loading input data: ['pb03.20231221test.complicated.r01.e01.volreg+orig.HEAD', 'pb03.20231221test.complicated.r01.e02.volreg+orig.HEAD', 'pb03.20231221test.complicated.r01.e03.volreg+orig.HEAD', 'pb03.20231221test.complicated.r01.e04.volreg+orig.HEAD', 'pb03.20231221test.complicated.r01.e05.volreg+orig.HEAD']
INFO     io:__init__:153 Generating figures directory: /home/sa-j186b025/R-Drive/Martin_L/150353_GETActiveHIIT2/MR_Data/Participants/20231221/Resting/20231221test.complicated.results/tedana_r01/figures
INFO     tedana:tedana_workflow:543 Using user-defined mask
INFO     tedana:tedana_workflow:591 Computing T2* map
Traceback (most recent call last):
  File "/opt/anaconda3/envs/py3_afni_tiny/bin/tedana", line 8, in <module>
  File "/home/sa-j186b025/.local/lib/python3.8/site-packages/tedana/workflows/", line 890, in _main
  File "/home/sa-j186b025/.local/lib/python3.8/site-packages/tedana/workflows/", line 592, in tedana_workflow
    t2s_limited, s0_limited, t2s_full, s0_full = decay.fit_decay(
  File "/home/sa-j186b025/.local/lib/python3.8/site-packages/tedana/", line 375, in fit_decay
    t2s_limited, s0_limited, t2s_full, s0_full = fit_loglinear(
  File "/home/sa-j186b025/.local/lib/python3.8/site-packages/tedana/", line 274, in fit_loglinear
    log_data = np.log(np.abs(data_2d) + 1)
numpy.core._exceptions.MemoryError: Unable to allocate 3.44 GiB for an array with shape (2580, 178714) and data type float64

Please advise.
Thank you,
Morgan B.

code text  # or delete if not needed

Hi, Morgan-

For the first error in the APQC HTML generation, I suspect that was a bug that has probably been squashed since then. Can you update your AFNI locally?

For the second (m_tedana one, the primary error appears to be this:

numpy.core._exceptions.MemoryError: Unable to allocate 3.44 GiB for an array with shape (2580, 178714) and data type float64

... which means that your computer memory has been exhausted for that operation. Are you running on a computer on which you could increase RAM usage (like a high performance computing cluster, where you could request more memory)? If not, perhaps could you try inputting a subset of runs (I see you have a glob character currently), to see if that resolves it? (And the above APQC HTML error might come into play once this completes, though again hopefully updating your local code would resolve that.)