FMRIPrep errors on 3 of 15 subjects

Not sure where else to turn for help with these subjects.
These subjects all came from the same scanner using the same protocol. Not sure what the difference could be. They’ve all been processed by fmriprep in the past (~1yr ago), but now that I’m processing again (starting with raw data -> BIDS using dcm2niix), I get errors like the following. Thanks for any help.

         [Node] Finished "fmriprep_wf.single_subject_06_wf.func_preproc_run1_wf.bold_std_trans_wf.bold_reference_wf.enhance_and_skullstrip_bold_wf.apply_mask".
Traceback (most recent call last):
  File "/usr/local/miniconda/bin/fmriprep", line 10, in <module>
    sys.exit(main())
  File "/usr/local/miniconda/lib/python3.7/site-packages/fmriprep/cli/run.py", line 465, in main
    packagename='fmriprep')
  File "/usr/local/miniconda/lib/python3.7/site-packages/niworkflows/reports/core.py", line 478, in generate_reports
    for subject_label in subject_list
  File "/usr/local/miniconda/lib/python3.7/site-packages/niworkflows/reports/core.py", line 478, in <listcomp>
    for subject_label in subject_list
  File "/usr/local/miniconda/lib/python3.7/site-packages/niworkflows/reports/core.py", line 465, in run_reports
    subject_id=subject_label, packagename=packagename)
  File "/usr/local/miniconda/lib/python3.7/site-packages/niworkflows/reports/core.py", line 267, in __init__
    self._load_config(Path(config))
  File "/usr/local/miniconda/lib/python3.7/site-packages/niworkflows/reports/core.py", line 286, in _load_config
    self.index(settings['sections'])
  File "/usr/local/miniconda/lib/python3.7/site-packages/niworkflows/reports/core.py", line 307, in index
    for cfg in subrep_cfg['reportlets']]
  File "/usr/local/miniconda/lib/python3.7/site-packages/niworkflows/reports/core.py", line 307, in <listcomp>
    for cfg in subrep_cfg['reportlets']]
  File "/usr/local/miniconda/lib/python3.7/site-packages/niworkflows/reports/core.py", line 164, in __init__
    linked_svg = layout.build_path(entities, validate=False)
  File "/usr/local/miniconda/lib/python3.7/site-packages/bids/layout/layout.py", line 1351, in build_path
    raise ValueError("Unable to construct build path with source {}".format(source))
ValueError: Unable to construct build path with source {'datatype': 'figures', 'desc': 'bbregister', 'subject': '06', 'suffix': 'bold', 'extension': 'svg'}
fMRIPrep: Please report errors to https://github.com/poldracklab/fmriprep/issues
fmriprep-docker --skip_bids_validation /Volumes/Data/Drive/Research/aim1    0  1.58s user 1.08s system 0% cpu 7:03:57.21 total

And here’s the log output:

Node: fmriprep_wf.single_subject_06_wf.summary
Working directory: /tmp/work/fmriprep_wf/single_subject_06_wf/summary

Node inputs:

bold = ['/data/sub-06/func/sub-06_run1_bold.nii.gz', '/data/sub-06/func/sub-06_run2_bold.nii.gz', '/data/sub-06/func/sub-06_run3_bold.nii.gz', '/data/sub-06/func/sub-06_run4_bold.nii.gz']
nstd_spaces = []
std_spaces = ['MNI152NLin2009cAsym', 'fsaverage5']
subject_id = 06
subjects_dir = /out/freesurfer
t1w = ['/data/sub-06/anat/sub-06_T1w.nii.gz']
t2w = <undefined>

Traceback (most recent call last):
  File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/plugins/multiproc.py", line 336, in _send_procs_to_workers
    self.procs[jobid].run(updatehash=updatehash)
  File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 516, in run
    result = self._run_interface(execute=True)
  File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 635, in _run_interface
    return self._run_command(execute)
  File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/pipeline/engine/nodes.py", line 741, in _run_command
    result = self._interface.run(cwd=outdir)
  File "/usr/local/miniconda/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 395, in run
    runtime = self._run_interface(runtime)
  File "/usr/local/miniconda/lib/python3.7/site-packages/fmriprep/interfaces/reports.py", line 100, in _run_interface
    return super(SubjectSummary, self)._run_interface(runtime)
  File "/usr/local/miniconda/lib/python3.7/site-packages/fmriprep/interfaces/reports.py", line 64, in _run_interface
    segment = self._generate_segment()
  File "/usr/local/miniconda/lib/python3.7/site-packages/fmriprep/interfaces/reports.py", line 124, in _generate_segment
    for series in bold_series)
  File "/usr/local/miniconda/lib/python3.7/collections/__init__.py", line 566, in __init__
    self.update(*args, **kwds)
  File "/usr/local/miniconda/lib/python3.7/collections/__init__.py", line 653, in update
    _count_elements(self, iterable)
  File "/usr/local/miniconda/lib/python3.7/site-packages/fmriprep/interfaces/reports.py", line 124, in <genexpr>
    for series in bold_series)
TypeError: 'NoneType' object is not subscriptable

Hi, what version of fMRIPrep are you using?

I have 1.5.7 .
I see that a newer version is available. Do you recommend upgrading?

Thanks

This stuck out to me: should “/data/sub-06/func/sub-06_run1_bold.nii.gz” be “/data/sub-06/func/sub-06_run-1_bold.nii.gz” instead?

Best,
James

Ah! I think you’re onto something.
There’s more text missing, more in a bit…
Should actually be (I think):
sub-06_task-ao_run-01_bold.nii.gz

How many times did I look at those and not notice.

Thanks!

Edit: Success! Thanks so much!

2 Likes

Thanks for catching this @jdkent.

2 Likes

MANAGED BY INCF