Skip to content

Commit 5ab828d

Browse files
committed
PEP8 cleanup
1 parent 772f540 commit 5ab828d

File tree

1 file changed

+31
-28
lines changed

1 file changed

+31
-28
lines changed

nipype/interfaces/fsl/epi.py

Lines changed: 31 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@
1212
... '../../testing/data'))
1313
>>> os.chdir(datadir)
1414
"""
15-
from __future__ import print_function, division, unicode_literals, absolute_import
15+
from __future__ import print_function, division, unicode_literals, \
16+
absolute_import
1617
from builtins import str
1718

1819
import os
@@ -106,7 +107,7 @@ def _run_interface(self, runtime):
106107
out_file = self.inputs.out_fieldmap
107108
im = nb.load(out_file, mmap=NUMPY_MMAP)
108109
dumb_img = nb.Nifti1Image(np.zeros(im.shape), im.affine,
109-
im.header)
110+
im.header)
110111
out_nii = nb.funcs.concat_images((im, dumb_img))
111112
nb.save(out_nii, out_file)
112113

@@ -450,26 +451,25 @@ class EddyInputSpec(FSLCommandInputSpec):
450451

451452

452453
class EddyOutputSpec(TraitedSpec):
453-
out_corrected = File(exists=True,
454-
desc=('4D image file containing all the corrected '
455-
'volumes'))
456-
out_parameter = File(exists=True,
457-
desc=('text file with parameters definining the '
458-
'field and movement for each scan'))
459-
out_rotated_bvecs = File(exists=True,
460-
desc=('File containing rotated b-values for all volumes'))
461-
out_movement_rms = File(exists=True,
462-
desc=('Summary of the "total movement" in each volume'))
463-
out_restricted_movement_rms = File(exists=True,
464-
desc=('Summary of the "total movement" in each volume '
465-
'disregarding translation in the PE direction'))
466-
out_shell_alignment_parameters = File(exists=True,
467-
desc=('File containing rigid body movement parameters '
468-
'between the different shells as estimated by a '
469-
'post-hoc mutual information based registration'))
470-
out_outlier_report = File(exists=True,
471-
desc=('Text-file with a plain language report '
472-
'on what outlier slices eddy has found'))
454+
out_corrected = File(
455+
exists=True, desc='4D image file containing all the corrected volumes')
456+
out_parameter = File(
457+
exists=True, desc=('text file with parameters definining the field and'
458+
'movement for each scan'))
459+
out_rotated_bvecs = File(
460+
exists=True, desc='File containing rotated b-values for all volumes')
461+
out_movement_rms = File(
462+
exists=True, desc='Summary of the "total movement" in each volume')
463+
out_restricted_movement_rms = File(
464+
exists=True, desc=('Summary of the "total movement" in each volume '
465+
'disregarding translation in the PE direction'))
466+
out_shell_alignment_parameters = File(
467+
exists=True, desc=('File containing rigid body movement parameters '
468+
'between the different shells as estimated by a '
469+
'post-hoc mutual information based registration'))
470+
out_outlier_report = File(
471+
exists=True, desc=('Text-file with a plain language report on what '
472+
'outlier slices eddy has found'))
473473

474474

475475
class Eddy(FSLCommand):
@@ -492,9 +492,9 @@ class Eddy(FSLCommand):
492492
>>> eddy.inputs.in_bvec = 'bvecs.scheme'
493493
>>> eddy.inputs.in_bval = 'bvals.scheme'
494494
>>> eddy.cmdline # doctest: +ELLIPSIS +ALLOW_UNICODE
495-
'eddy_openmp --acqp=epi_acqp.txt --bvals=bvals.scheme --bvecs=bvecs.scheme \
496-
--imain=epi.nii --index=epi_index.txt --mask=epi_mask.nii \
497-
--out=.../eddy_corrected'
495+
'eddy_openmp --acqp=epi_acqp.txt --bvals=bvals.scheme \
496+
--bvecs=bvecs.scheme --imain=epi.nii --index=epi_index.txt \
497+
--mask=epi_mask.nii --out=.../eddy_corrected'
498498
>>> res = eddy.run() # doctest: +SKIP
499499
500500
"""
@@ -562,7 +562,8 @@ def _list_outputs(self):
562562
out_restricted_movement_rms = os.path.abspath(
563563
'%s.eddy_restricted_movement_rms' % self.inputs.out_base)
564564
out_shell_alignment_parameters = os.path.abspath(
565-
'%s.eddy_post_eddy_shell_alignment_parameters' % self.inputs.out_base)
565+
'%s.eddy_post_eddy_shell_alignment_parameters'
566+
% self.inputs.out_base)
566567
out_outlier_report = os.path.abspath(
567568
'%s.eddy_outlier_report' % self.inputs.out_base)
568569

@@ -571,9 +572,11 @@ def _list_outputs(self):
571572
if os.path.exists(out_movement_rms):
572573
outputs['out_movement_rms'] = out_movement_rms
573574
if os.path.exists(out_restricted_movement_rms):
574-
outputs['out_restricted_movement_rms'] = out_restricted_movement_rms
575+
outputs['out_restricted_movement_rms'] = \
576+
out_restricted_movement_rms
575577
if os.path.exists(out_shell_alignment_parameters):
576-
outputs['out_shell_alignment_parameters'] = out_shell_alignment_parameters
578+
outputs['out_shell_alignment_parameters'] = \
579+
out_shell_alignment_parameters
577580
if os.path.exists(out_outlier_report):
578581
outputs['out_outlier_report'] = out_outlier_report
579582

0 commit comments

Comments
 (0)