Skip to content

Commit aaf3b05

Browse files
author
David Ellis
committed
FIX: make check-before-commit
1 parent 89e208c commit aaf3b05

File tree

11 files changed

+28
-20
lines changed

11 files changed

+28
-20
lines changed

nipype/interfaces/freesurfer/tests/test_auto_Aparc2Aseg.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ def test_Aparc2Aseg_inputs():
1919
environ=dict(nohash=True,
2020
usedefault=True,
2121
),
22+
filled=dict(),
2223
hypo_wm=dict(argstr='--hypo-as-wm',
2324
mandatory=False,
2425
),

nipype/interfaces/freesurfer/tests/test_auto_Curvature.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ def test_Curvature_inputs():
1919
usedefault=True,
2020
),
2121
in_file=dict(argstr='%s',
22+
copyfile=True,
2223
mandatory=True,
2324
position=-2,
2425
),

nipype/interfaces/freesurfer/tests/test_auto_MakeSurfaces.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ def test_MakeSurfaces_inputs():
3535
in_orig=dict(argstr='-orig %s',
3636
mandatory=True,
3737
),
38+
in_white=dict(),
3839
in_wm=dict(mandatory=True,
3940
),
4041
longitudinal=dict(argstr='-long',
@@ -66,6 +67,8 @@ def test_MakeSurfaces_inputs():
6667
subjects_dir=dict(),
6768
terminal_output=dict(nohash=True,
6869
),
70+
white=dict(argstr='-white %s',
71+
),
6972
white_only=dict(argstr='-whiteonly',
7073
mandatory=False,
7174
),

nipype/interfaces/freesurfer/tests/test_auto_SegStatsReconAll.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ def test_SegStatsReconAll_inputs():
1010
),
1111
args=dict(argstr='%s',
1212
),
13+
aseg=dict(),
1314
avgwf_file=dict(argstr='--avgwfvol %s',
1415
),
1516
avgwf_txt_file=dict(argstr='--avgwf %s',
@@ -85,8 +86,7 @@ def test_SegStatsReconAll_inputs():
8586
),
8687
partial_volume_file=dict(argstr='--pv %s',
8788
),
88-
presurf_seg=dict(mandatory=True,
89-
),
89+
presurf_seg=dict(),
9090
rh_orig_nofix=dict(mandatory=True,
9191
),
9292
rh_pial=dict(mandatory=True,

nipype/interfaces/freesurfer/tests/test_auto_VolumeMask.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
def test_VolumeMask_inputs():
77
input_map = dict(args=dict(argstr='%s',
88
),
9+
aseg=dict(xor=['in_aseg'],
10+
),
911
copy_inputs=dict(mandatory=False,
1012
),
1113
environ=dict(nohash=True,
@@ -16,6 +18,7 @@ def test_VolumeMask_inputs():
1618
),
1719
in_aseg=dict(argstr='--aseg_name %s',
1820
mandatory=False,
21+
xor=['aseg'],
1922
),
2023
left_ribbonlabel=dict(argstr='--label_left_ribbon %d',
2124
mandatory=True,

nipype/interfaces/freesurfer/utils.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2315,14 +2315,14 @@ class VolumeMaskInputSpec(FSTraitedSpec):
23152315
rh_white = File(mandatory=True, exists=True,
23162316
desc="Implicit input right white matter surface")
23172317
aseg = File(exists=True,
2318-
xor=['in_aseg'],
2319-
desc="Implicit aseg.mgz segmentation. " +
2318+
xor=['in_aseg'],
2319+
desc="Implicit aseg.mgz segmentation. " +
23202320
"Specify a different aseg by using the 'in_aseg' input.")
23212321
subject_id = traits.String('subject_id', usedefault=True,
23222322
position=-1, argstr="%s", mandatory=True,
23232323
desc="Subject being processed")
23242324
# optional
2325-
in_aseg = File(argstr="--aseg_name %s", mandatory=False,
2325+
in_aseg = File(argstr="--aseg_name %s", mandatory=False,
23262326
exists=True, xor=['aseg'],
23272327
desc="Input aseg file for VolumeMask")
23282328
save_ribbon = traits.Bool(argstr="--save_ribbon", mandatory=False,
@@ -2383,7 +2383,7 @@ def run(self, **inputs):
23832383
copy2subjdir(self, self.inputs.rh_white, 'surf', 'rh.white')
23842384
copy2subjdir(self, self.inputs.in_aseg, 'mri')
23852385
copy2subjdir(self, self.inputs.aseg, 'mri', 'aseg.mgz')
2386-
2386+
23872387
return super(VolumeMask, self).run(**inputs)
23882388

23892389
def _format_arg(self, name, spec, value):

nipype/workflows/smri/freesurfer/autorecon1.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ def awkfile(in_file, log_file):
345345
intensity_correction.inputs.iterations = 2
346346
ar1_wf.connect([(add_xform_to_orig, intensity_correction, [('out_file', 'in_file')]),
347347
(copy_transform, intensity_correction, [('out_file', 'transform')])])
348-
348+
349349

350350
add_to_header_nu = pe.Node(AddXFormToHeader(), name="Add_XForm_to_NU")
351351
add_to_header_nu.inputs.copy_name = True
@@ -356,7 +356,7 @@ def awkfile(in_file, log_file):
356356
[('out_file', 'transform')])
357357
])
358358

359-
359+
360360
# Intensity Normalization
361361
# Performs intensity normalization of the orig volume and places the result in mri/T1.mgz.
362362
# Attempts to correct for fluctuations in intensity that would otherwise make intensity-based
@@ -368,7 +368,7 @@ def awkfile(in_file, log_file):
368368
mri_normalize.inputs.out_file = 'T1.mgz'
369369

370370
if fsvernum < 6:
371-
ar1_wf.connect([(add_to_header_nu, mri_normalize, [('out_file', 'in_file')])])
371+
ar1_wf.connect([(add_to_header_nu, mri_normalize, [('out_file', 'in_file')])])
372372
else:
373373
ar1_wf.connect([(add_xform_to_orig_nu, mri_normalize, [('out_file', 'in_file')])])
374374

@@ -390,7 +390,7 @@ def awkfile(in_file, log_file):
390390
ar1_wf.connect(add_to_header_nu, 'out_file', mri_em_register, 'in_file')
391391
else:
392392
ar1_wf.connect(add_xform_to_orig_nu, 'out_file', mri_em_register, 'in_file')
393-
393+
394394
ar1_wf.connect([(inputspec, mri_em_register, [('num_threads', 'num_threads'),
395395
('reg_template_withskull', 'template')])])
396396

nipype/workflows/smri/freesurfer/autorecon2.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ def create_AutoRecon2(name="AutoRecon2", longitudinal=False,
6161
ar2_wf.connect([(inputspec, intensity_correction, [('orig', 'in_file'),
6262
('brainmask', 'mask'),
6363
('transform', 'transform')])])
64-
64+
6565
# intensity correction parameters are more specific in 6+
6666
intensity_correction.inputs.iterations = 1
6767
intensity_correction.inputs.protocol_iterations = 1000
@@ -70,7 +70,7 @@ def create_AutoRecon2(name="AutoRecon2", longitudinal=False,
7070
if shrink:
7171
intensity_correction.inputs.shrink = shrink
7272
intensity_correction.inputs.distance = distance
73-
73+
7474
add_to_header_nu = pe.Node(AddXFormToHeader(), name="Add_XForm_to_NU")
7575
add_to_header_nu.inputs.copy_name = True
7676
add_to_header_nu.inputs.out_file = 'nu.mgz'
@@ -108,7 +108,7 @@ def create_AutoRecon2(name="AutoRecon2", longitudinal=False,
108108
ar2_wf.connect([(add_to_header_nu, align_transform, [('out_file', 'in_file')])])
109109
else:
110110
ar2_wf.connect([(inputspec, align_transform, [('nu', 'in_file')])])
111-
111+
112112

113113
# CA Normalize
114114
"""
@@ -698,7 +698,7 @@ def create_AutoRecon2(name="AutoRecon2", longitudinal=False,
698698
# add to outputspec to perserve datasinking
699699
ar2_wf.connect([(inputspec, outputspec, [('nu', 'nu')])])
700700

701-
701+
702702
ar2_wf.connect([(align_transform, outputspec, [('out_file', 'tal_lta')]),
703703
(ca_normalize, outputspec, [('out_file', 'norm')]),
704704
(ca_normalize, outputspec, [('control_points', 'ctrl_pts')]),

nipype/workflows/smri/freesurfer/autorecon3.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -621,10 +621,10 @@ def out_aseg(in_aparcaseg, in_aseg, out_file):
621621
out_aseg),
622622
name="Aseg")
623623
ar3_wf.connect([(aparc_2_aseg, apas_2_aseg, [('out_file', 'in_aparcaseg')]),
624-
(inputspec, apas_2_aseg, [('aseg_presurf', 'in_aseg')])])
624+
(inputspec, apas_2_aseg, [('aseg_presurf', 'in_aseg')])])
625625

626626
apas_2_aseg.inputs.out_file = "aseg.mgz"
627-
627+
628628

629629
# Segmentation Stats
630630
"""

nipype/workflows/smri/freesurfer/ba_maps.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ def create_ba_maps_wf(name="Brodmann_Area_Maps", th3=True, exvivo=True,
8585
out_file = '{0}.{1}_exvivo.label'.format(hemisphere, label)
8686
else:
8787
out_file = '{0}.{1}.label'.format(hemisphere, label)
88-
88+
8989
out_files.append(out_file)
9090
field_template[label] = 'label/' + out_file
9191
source_fields.append(label)

0 commit comments

Comments
 (0)