Summary of what happened:
Hi all,
I’m getting a crash while using fmriprep. I successfully completed preprocessing using fmriprep with the exact same command for all other subjects but two that keep crashing.
Command used (and if a helper script was used, a link to the helper script or the command generated):
docker run -it --rm ^
-v C:\Users\YossiY100\Desktop\2020_analysis\Nifti:/data:ro ^
-v C:\Users\YossiY100\Desktop\2020_analysis\derivatives:/out ^
-v C:\Users\YossiY100\Desktop\license.txt:/opt/freesurfer/license.txt:ro ^
nipreps/fmriprep:23.0.2 ^
/data /out/fmriprep-23.0.2 ^
participant --participant-label sub-1737202007130846 ^
--fs-license-file /opt/freesurfer/license.txt ^
--ignore slicetiming ^
--low-mem ^
--mem-mb 11000 ^
--skip_bids_validation
Version:
fmriprep 23.0.2
Environment (Docker, Singularity, custom installation):
docker
Data formatted according to a validatable standard? Please provide the output of the validator:
File Path: Not all subjects contain the same files. Each subject should contain the same number of files with the same naming unless some files are known to be missing.
Type: Warning
File: sub-1738202007131018_ses-1_FLAIR.json
Location: /sub-1738202007131018/ses-1/anat/sub-1738202007131018_ses-1_FLAIR.json
Reason: This file is missing for subject sub-1738202007131018, but is present for at least one other subject.
Evidence: Subject: sub-1738202007131018; Missing file: sub-1738202007131018_ses-1_FLAIR.json
Type: Warning
File: sub-1738202007131018_ses-1_FLAIR.nii
Location: /sub-1738202007131018/ses-1/anat/sub-1738202007131018_ses-1_FLAIR.nii
Reason: This file is missing for subject sub-1738202007131018, but is present for at least one other subject.
Evidence: Subject: sub-1738202007131018; Missing file: sub-1738202007131018_ses-1_FLAIR.nii
======================================================
File Path: Not all subjects/sessions/runs have the same scanning parameters.
Type: Warning
File: sub-1642202006170835_ses-1_task-IndividualSounds2020_acq-TR1000_bold.nii
Location: Nifti/sub-1642202006170835/ses-1/func/sub-1642202006170835_ses-1_task-IndividualSounds2020_acq-TR1000_bold.nii
Reason: The most common set of dimensions is: 102,102,72,417 (voxels), This file has the dimensions: 98,98,72,387 (voxels).
Type: Warning
File: sub-1642202006170835_ses-1_task-IndividualSounds2020_acq-TR1000_sbref.nii
Location: Nifti/sub-1642202006170835/ses-1/func/sub-1642202006170835_ses-1_task-IndividualSounds2020_acq-TR1000_sbref.nii
Reason: The most common set of dimensions is: 102,102,72 (voxels), This file has the dimensions: 98,98,72 (voxels).
======================================================
File Path: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
Type: Warning
File: task-IndividualSounds2020_events.tsv
Location: Nifti/task-IndividualSounds2020_events.tsv
Reason: The onset of the last event is after the total duration of the corresponding scan. This design is suspiciously long.
======================================================
Relevant log outputs (up to 20 lines):
Here is the log from the crash .txt:
Node: fmriprep_23_0_wf.single_subject_1737202007130846_wf.func_preproc_ses_1_task_IndividualSounds2020_acq_TR1000_wf.initial_boldref_wf.enhance_and_skullstrip_bold_wf.n4_correct
Working directory: /tmp/work/fmriprep_23_0_wf/single_subject_1737202007130846_wf/func_preproc_ses_1_task_IndividualSounds2020_acq_TR1000_wf/initial_boldref_wf/enhance_and_skullstrip_bold_wf/n4_correct
Node inputs:
args = <undefined>
bias_image = <undefined>
bspline_fitting_distance = 200.0
bspline_order = <undefined>
convergence_threshold = <undefined>
copy_header = True
dimension = 3
environ = {'NSLOTS': '1'}
histogram_sharpening = <undefined>
input_image = <undefined>
mask_image = <undefined>
n_iterations = <undefined>
num_threads = 1
output_image = <undefined>
rescale_intensities = True
save_bias = False
shrink_factor = <undefined>
weight_image = <undefined>
Traceback (most recent call last):
File "/opt/conda/lib/python3.9/site-packages/nipype/pipeline/plugins/multiproc.py", line 67, in run_node
result["result"] = node.run(updatehash=updatehash)
File "/opt/conda/lib/python3.9/site-packages/nipype/pipeline/engine/nodes.py", line 527, in run
result = self._run_interface(execute=True)
File "/opt/conda/lib/python3.9/site-packages/nipype/pipeline/engine/nodes.py", line 645, in _run_interface
return self._run_command(execute)
File "/opt/conda/lib/python3.9/site-packages/nipype/pipeline/engine/nodes.py", line 771, in _run_command
raise NodeExecutionError(msg)
nipype.pipeline.engine.nodes.NodeExecutionError: Exception raised while executing Node n4_correct.
Cmdline:
N4BiasFieldCorrection --bspline-fitting [ 200 ] -d 3 --input-image /tmp/work/fmriprep_23_0_wf/single_subject_1737202007130846_wf/func_preproc_ses_1_task_IndividualSounds2020_acq_TR1000_wf/initial_boldref_wf/gen_avg/sub-1737202007130846_ses-1_task-IndividualSounds2020_acq-TR1000_sbref_merged_squeezed.nii --output sub-1737202007130846_ses-1_task-IndividualSounds2020_acq-TR1000_sbref_merged_squeezed_corrected.nii -r --weight-image /tmp/work/fmriprep_23_0_wf/single_subject_1737202007130846_wf/func_preproc_ses_1_task_IndividualSounds2020_acq_TR1000_wf/initial_boldref_wf/enhance_and_skullstrip_bold_wf/check_hdr/tpl-MNI152NLin2009cAsym_res-01_label-brain_probseg_trans_hdr.nii.gz
Stdout:
Stderr:
Traceback:
Traceback (most recent call last):
File "/opt/conda/lib/python3.9/site-packages/nipype/interfaces/base/core.py", line 453, in aggregate_outputs
setattr(outputs, key, val)
File "/opt/conda/lib/python3.9/site-packages/nipype/interfaces/base/traits_extension.py", line 330, in validate
value = super(File, self).validate(objekt, name, value, return_pathlike=True)
File "/opt/conda/lib/python3.9/site-packages/nipype/interfaces/base/traits_extension.py", line 135, in validate
self.error(objekt, name, str(value))
File "/opt/conda/lib/python3.9/site-packages/traits/base_trait_handler.py", line 74, in error
raise TraitError(
traits.trait_errors.TraitError: The 'output_image' trait of a _FixN4BiasFieldCorrectionOutputSpec instance must be a pathlike object or string representing an existing file, but a value of '/tmp/work/fmriprep_23_0_wf/single_subject_1737202007130846_wf/func_preproc_ses_1_task_IndividualSounds2020_acq_TR1000_wf/initial_boldref_wf/enhance_and_skullstrip_bold_wf/n4_correct/sub-1737202007130846_ses-1_task-IndividualSounds2020_acq-TR1000_sbref_merged_squeezed_corrected.nii' <class 'str'> was specified.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/conda/lib/python3.9/site-packages/nipype/interfaces/base/core.py", line 398, in run
runtime = self._post_run_hook(runtime)
File "/opt/conda/lib/python3.9/site-packages/nipype/interfaces/mixins/fixheader.py", line 127, in _post_run_hook
outputs = self.aggregate_outputs(runtime=runtime).get_traitsfree()
File "/opt/conda/lib/python3.9/site-packages/nipype/interfaces/base/core.py", line 460, in aggregate_outputs
raise FileNotFoundError(msg)
FileNotFoundError: No such file or directory '/tmp/work/fmriprep_23_0_wf/single_subject_1737202007130846_wf/func_preproc_ses_1_task_IndividualSounds2020_acq_TR1000_wf/initial_boldref_wf/enhance_and_skullstrip_bold_wf/n4_correct/sub-1737202007130846_ses-1_task-IndividualSounds2020_acq-TR1000_sbref_merged_squeezed_corrected.nii' for output 'output_image' of a FixN4BiasFieldCorrection interface
Screenshots / relevant information:
Would really appreciate your help with this! Thank you in advance