nipreps / mriqc

Automated Quality Control and visual reports for Quality Assessment of structural (T1w, T2w) and functional MRI of the brain
http://mriqc.readthedocs.io
Apache License 2.0
299 stars 132 forks source link

MRIQC TypeError: ‘reversed’ is an invalid keyword argument for sort() #1235

Closed WangYunHong98 closed 7 months ago

WangYunHong98 commented 7 months ago

What happened?

I got an error when I submitted a slurm job of MRIQC using singularity. Please see the log details.

What command did you use?

subjectID=$( sed -n -E "$((${SLURM_ARRAY_TASK_ID} + 1))s/sub-(\S*)\>.*/\1/gp"${BIDS_DIR}/participants.tsv)

echo "$subjectID"

singularity run \
        --cleanenv \
        -B ${BIDS_DIR}:/data:ro \
        -B ${OUTPUT_DIR}:/output \
        -B ${WORK_DIR}:/work \
    ${MRIQC} /data /output \
    participant \
    --participant-label "$subjectID" \
    -w /work \
    -vv \
    --n_cpus 4 \
    --mem 16000 \
    --write-graph \
    --fd_thres 0.2 \
    --float32 \

What version of the software are you running?

23.1.1

How are you running this software?

Singularity

Is your data BIDS valid?

Yes

Are you reusing any previously computed results?

No

Please copy and paste any relevant log output.

Traceback (most recent call last):
  File "/opt/conda/lib/python3.11/site-packages/mriqc/engine/plugin.py", line 60, in run_node
    result['result'] = node.run(updatehash=updatehash)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/conda/lib/python3.11/site-packages/nipype/pipeline/engine/nodes.py", line 527, in run
    result = self._run_interface(execute=True)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/conda/lib/python3.11/site-packages/nipype/pipeline/engine/nodes.py", line 645, in _run_interface
    return self._run_command(execute)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/conda/lib/python3.11/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 GradientThreshold.

Traceback:
    Traceback (most recent call last):
      File "/opt/conda/lib/python3.11/site-packages/nipype/interfaces/base/core.py", line 397, in run
        runtime = self._run_interface(runtime)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/conda/lib/python3.11/site-packages/nipype/interfaces/utility/wrappers.py", line 142, in _run_interface
        out = function_handle(**args)
              ^^^^^^^^^^^^^^^^^^^^^^^
      File "<string>", line 44, in gradient_threshold
    TypeError: 'reversed' is an invalid keyword argument for sort()

Additional information / screenshots

No response

WangYunHong98 commented 7 months ago

Hi everyone,

I tried the latest verison nipreps/mriqc:24.0.0rc1 and it worked well.

oesteban commented 7 months ago

Yes, this was fixed with #1211. Thanks for reporting :)