Skip to content

Commit 8a5fd28

Browse files
committed
fix shells options, merge master
1 parent de56b4c commit 8a5fd28

File tree

5 files changed

+20
-17
lines changed

5 files changed

+20
-17
lines changed

nipype/interfaces/mrtrix3/preprocess.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class ResponseSDInputSpec(CommandLineInputSpec):
4646

4747
# DW Shell selection options
4848

49-
shell = traits.List(traits.Float, sep=',', argstr='-shell %f',
49+
shell = traits.List(traits.Float, sep=',', argstr='-shell %s',
5050
desc='specify one or more dw gradient shells')
5151
in_mask = File(exists=True, argstr='-mask %s',
5252
desc='provide initial mask image')

nipype/interfaces/mrtrix3/reconst.py

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
from nipype.utils.filemanip import split_filename
2222
from nipype.interfaces.traits_extension import isdefined
2323

24+
2425
class FitTensorInputSpec(CommandLineInputSpec):
2526
in_file = File(exists=True, argstr='%s', mandatory=True, position=-2,
2627
desc='input diffusion weighted images')
@@ -30,17 +31,16 @@ class FitTensorInputSpec(CommandLineInputSpec):
3031

3132
# General options
3233
in_mask = File(exists=True, argstr='-mask %s',
33-
desc=('only perform computation within the specified binary '
34-
'brain mask image'))
34+
desc=('only perform computation within the specified '
35+
'binary brain mask image'))
3536
method = traits.Enum(
3637
'nonlinear', 'loglinear', 'sech', 'rician', argstr='-method %s',
3738
desc=('select method used to perform the fitting'))
3839
reg_term = traits.Float(
3940
5.e3, argstr='-regularisation %f',
40-
desc=('specify the strength of the regularisation term on the magnitude '
41-
'of the tensor elements (default = 5000). This only applies to the '
42-
'non-linear methods'))
43-
41+
desc=('specify the strength of the regularisation term on the '
42+
'magnitude of the tensor elements (default = 5000). This '
43+
'only applies to the non-linear methods'))
4444

4545
# DW gradient table import options
4646
grad_file = File(exists=True, argstr='-grad %s',
@@ -100,7 +100,8 @@ class EstimateFODInputSpec(CommandLineInputSpec):
100100
'function coefficients for a single fibre population'))
101101
out_file = File(
102102
'fods.mif', argstr='%s', mandatory=True, position=-1,
103-
usedefault=True, desc='the output spherical harmonics coefficients image')
103+
usedefault=True, desc=('the output spherical harmonics coefficients'
104+
' image'))
104105

105106
# DW gradient table import options
106107
grad_file = File(exists=True, argstr='-grad %s',
@@ -118,7 +119,7 @@ class EstimateFODInputSpec(CommandLineInputSpec):
118119
'false, 0 / 1 (default: true).'))
119120

120121
# DW Shell selection options
121-
shell = traits.List(traits.Float, sep=',', argstr='-shell %f',
122+
shell = traits.List(traits.Float, sep=',', argstr='-shell %s',
122123
desc='specify one or more dw gradient shells')
123124

124125
# Spherical deconvolution options
@@ -217,4 +218,4 @@ class EstimateFOD(CommandLine):
217218
def _list_outputs(self):
218219
outputs = self.output_spec().get()
219220
outputs['out_file'] = op.abspath(self.inputs.out_file)
220-
return outputs
221+
return outputs

nipype/interfaces/mrtrix3/tests/test_auto_EstimateFOD.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ def test_EstimateFOD_inputs():
4242
),
4343
sh_filter=dict(argstr='-filter %s',
4444
),
45-
shell=dict(argstr='-shell %f',
45+
shell=dict(argstr='-shell %s',
4646
sep=',',
4747
),
4848
terminal_output=dict(nohash=True,

nipype/interfaces/mrtrix3/tests/test_auto_ResponseSD.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def test_ResponseSD_inputs():
4040
),
4141
out_sf=dict(argstr='-sf %s',
4242
),
43-
shell=dict(argstr='-shell %f',
43+
shell=dict(argstr='-shell %s',
4444
sep=',',
4545
),
4646
terminal_output=dict(nohash=True,

nipype/interfaces/mrtrix3/utils.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ class BrainMaskInputSpec(CommandLineInputSpec):
4343
'BValueScaling entry. Valid choices are yes / no, true / '
4444
'false, 0 / 1 (default: true).'))
4545

46+
4647
class BrainMaskOutputSpec(TraitedSpec):
4748
out_file = File(exists=True, desc='the output response file')
4849

@@ -74,7 +75,6 @@ def _list_outputs(self):
7475
return outputs
7576

7677

77-
7878
class Mesh2PVEInputSpec(CommandLineInputSpec):
7979
in_file = File(exists=True, argstr='%s', mandatory=True, position=-3,
8080
desc='input mesh')
@@ -184,10 +184,12 @@ class TensorMetricsInputSpec(CommandLineInputSpec):
184184
desc=('specify the desired eigenvalue/eigenvector(s). Note that '
185185
'several eigenvalues can be specified as a number sequence'))
186186
in_mask = File(exists=True, argstr='-mask %s',
187-
desc=('only perform computation within the specified binary '
188-
'brain mask image'))
187+
desc=('only perform computation within the specified binary'
188+
' brain mask image'))
189189
modulate = traits.Enum('FA', 'none', 'eval', argstr='-modulate %s',
190-
desc='how to modulate the magnitude of the eigenvectors')
190+
desc=('how to modulate the magnitude of the'
191+
' eigenvectors'))
192+
191193

192194
class TensorMetricsOutputSpec(TraitedSpec):
193195
out_fa = File(desc='output FA file')
@@ -225,4 +227,4 @@ def _list_outputs(self):
225227
if isdefined(getattr(self.inputs, k)):
226228
outputs[k] = op.abspath(getattr(self.inputs, k))
227229

228-
return outputs
230+
return outputs

0 commit comments

Comments
 (0)