Skip to content

Commit

Permalink
fix tests, bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
bpinsard committed May 16, 2024
1 parent 00a20eb commit 7c33deb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions smriprep/workflows/anatomical.py
Original file line number Diff line number Diff line change
Expand Up @@ -1484,7 +1484,7 @@ def init_anat_template_wf(
if gradunwarp_file:
nds = [
(
meta.get('NonlinearGradientCorrection', None)
not meta.get('NonlinearGradientCorrection', None)
or 'ND' in meta.get('ImageType', [])
or False
)
Expand All @@ -1498,7 +1498,7 @@ def init_anat_template_wf(
gradunwarp_file = None
if gradunwarp_file:
gradunwarp_ver = GradUnwarp.version()
workflow.__desc__ += f"""\
workflow.__desc__ = (workflow.__desc__ or "") + f"""\
{"Each" if num_files > 1 else "The"} {contrast} image was corrected for gradient
non-linearity with `gradunwarp` [@gradunwarp] {gradunwarp_ver} [@gradunwarp]\n"""
gradunwarp_wf = init_gradunwarp_wf('gradunward_T1w')
Expand Down
6 changes: 5 additions & 1 deletion smriprep/workflows/tests/test_anatomical.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@
BASE_LAYOUT = {
'01': {
'anat': [
{'run': 1, 'suffix': 'T1w'},
{
'run': 1,
'suffix': 'T1w',
'metadata': {'ImageType': ['ND']},
},
{'run': 2, 'suffix': 'T1w'},
{'suffix': 'T2w'},
],
Expand Down

0 comments on commit 7c33deb

Please sign in to comment.