poldracklab / tacc-openneuro

0 stars 1 forks source link

ds002424-fmriprep: ValueError: Unknown total-readout time specification #20

Open jbwexler opened 1 year ago

jbwexler commented 1 year ago

This happened for majority of subjects:

Node: fmriprep_wf.single_subject_75_wf.func_preproc_ses_T1_task_VSI_wf.unwarp_wf.rotime Working directory: /scratch1/03201/jbwexler/work_dir/fmriprep/ds002424_sub-75/fmriprep_wf/single_subj ect_75_wf/func_preproc_ses_T1_task_VSI_wf/unwarp_wf/rotime

Node inputs:

in_file = metadata = {'EchoTime': 0.02, 'FlipAngle': 80, 'InstitutionAddress': 'Fairbanks_710_Chicago_Chicago_U S60611', 'InstitutionName': 'CAMRI, Nortwestern University', 'Instructions': 'Press the first finger if letters are the same and every time the cross turns red. Press the second finger if letters are N OT the same. Respond as fast as you can! Remember, the better you do the more money you can make!! Yo u CAN respond as soon as each letter appears.', 'MagneticFieldStrength': 3, 'Manufacturer': 'SIEMENS' , 'ManufacturerModelName': 'TrioTim', 'MatrixCoilMode': 'Auto (Triple)', 'NumberOfSlices': 32, 'Numbe rOfVolumesDiscardedByUser': 6, 'ParallelAcquisitionTechnique': 'GRAPPA', 'PartialFourier': '6/8', 'Ph aseEncodingDirection': 'j-', 'PulseSequenceType': 'susceptibility weighted single-shot EPI', 'Repetit ionTime': 2, 'SliceEncodingDirection': 'k', 'SliceTiming': [1.005, 0, 1.0675, 0.0625, 1.13, 0.1275, 1 .1925, 0.19, 1.255, 0.2525, 1.3175, 0.315, 1.38, 0.3775, 1.4425, 0.44, 1.5075, 0.5025, 1.57, 0.565, 1 .6325, 0.6275, 1.695, 0.69, 1.7575, 0.7525, 1.82, 0.8175, 1.8825, 0.88, 1.945, 0.9425], 'SoftwareVers ions': 'syngo MR B17', 'TaskDescription': 'Subjects performed 48 trials of a 1-back verbal working memory (VWM) task, 48 trials of a 2-back VWM task, and 24 trials of a fixation task in a block design. Experimental task order was randomly generated with each experimental block followed by a 12 trial fixation block. Prior to the beginning of each experimental block, the program would indicate which task instructions were to be followed (1-back or 2-back). Throughout the experimental tasks, subjects were presented with an image indicating that they would make $.02 for each correct answer (/stimuli/fixation onecoin.bmp) in the middle of a black fixation square. In each trial, subjects were presented with a letter of the English alphabet in one of the four corners around the fixation square for 1200 ms followed by a 200 ms fixation period where only the fixation square remained. Each trial ended with a 600 ms feedback period in which the reward image was replaced by a solid green square for correct response, or solid red square for incorrect or no response. In the 1-back task, participants were instructed to press the first finger if the new letter was the same as the previously presented letter and to press the second finger if it differed. In the 2-back task, participants were instructed to press the first finger if the new letter was the same as the letter presented two back and to press the second finger if it differed. Participants could respond with a right handed button box as soon as they saw the presentation of the letter until the beginning of the next trial. At the end of each experimental block, participants were presented with their block accuracy. During fixation trials, subjects were presented with a black fixation cross for 600ms, 1200ms of either a black or red fixation cross, followed by 200ms of a black fixation cross. Subjects were instructed to press the first finger whenever a black fixation-cross turned red (4/12 trials).', 'TaskName': 'Verbal Working Memory, Small Reward, Immediate Feedback'}

Traceback (most recent call last): File "/opt/conda/lib/python3.8/site-packages/nipype/pipeline/plugins/multiproc.py", line 67, in run _node result["result"] = node.run(updatehash=updatehash) File "/opt/conda/lib/python3.8/site-packages/nipype/pipeline/engine/nodes.py", line 516, in run result = self._run_interface(execute=True) File "/opt/conda/lib/python3.8/site-packages/nipype/pipeline/engine/nodes.py", line 635, in _run_in terface return self._run_command(execute) File "/opt/conda/lib/python3.8/site-packages/nipype/pipeline/engine/nodes.py", line 741, in _run_co mmand result = self._interface.run(cwd=outdir) File "/opt/conda/lib/python3.8/site-packages/nipype/interfaces/base/core.py", line 428, in run runtime = self._run_interface(runtime) File "/opt/conda/lib/python3.8/site-packages/sdcflows/interfaces/epi.py", line 55, in _run_interfac e self._results["readout_time"] = get_trt( File "/opt/conda/lib/python3.8/site-packages/sdcflows/utils/epimanip.py", line 228, in get_trt raise ValueError("Unknown total-readout time specification") ValueError: Unknown total-readout time specification

jbwexler commented 1 year ago

Same error for every subject in ds000120-fmriprep and ds000203-fmriprep

effigies commented 1 year ago

Need to check for TRT/EES, not just phase-encoding direction to fail.

effigies commented 1 year ago

@mgxd @oesteban When TRT/EES are missing for SyN-SDC, should we just not do it, or fall back to per-BOLD SyN-SDC?

oesteban commented 1 year ago

I think we should not do it because there's no certainty that all BOLDs will have the same TRT/EES. If the researcher knows the value, it should be encoded with the dataset. Sharing data without TRT should be flagged (in a way, it is similar to sharing data without TR).

jbwexler commented 1 year ago

In that case, should I just run those subjects without --use-syn-sdc?

oesteban commented 1 year ago

Yes, but I agree that is inconvenient. fMRIPrep should disable fieldmap estimation and make a lot of noise about the missing SDC step (alternatively, have a flag to be more lenient and instead of crashing completely, issue the warning).

effigies commented 1 year ago

We have --use-syn-sdc error (default) and --use-syn-sdc warn. My initial thought was to just expand our early checks (which only look for PE direction) to fail/warn if TRT/EES is also missing.

The point, though, is that this isn't really required metadata, it's just useful for binning multiple BOLD series together to save computation and get a less biased fieldmap estimate. In the absence of the binning information, we could fall back to the pre-21.0 behavior of creating a separate fieldmap estimate per BOLD series.