|
4 | 4 |
|
5 | 5 | import os.path as op
|
6 | 6 |
|
7 |
| -from ..base import ( |
8 |
| - traits, TraitedSpec, File, Undefined, InputMultiObject, isdefined) |
| 7 | +from ..base import traits, TraitedSpec, File, Undefined, InputMultiObject, isdefined |
9 | 8 | from .base import MRTrix3BaseInputSpec, MRTrix3Base
|
10 | 9 |
|
11 | 10 |
|
@@ -52,10 +51,12 @@ class FitTensorInputSpec(MRTrix3BaseInputSpec):
|
52 | 51 | ),
|
53 | 52 | )
|
54 | 53 | predicted_signal = File(
|
55 |
| - argstr='-predicted_signal %s', |
| 54 | + argstr="-predicted_signal %s", |
56 | 55 | desc=(
|
57 | 56 | "specify a file to contain the predicted signal from the tensor "
|
58 |
| - "fits. This can be used to calculate the residual signal")) |
| 57 | + "fits. This can be used to calculate the residual signal" |
| 58 | + ), |
| 59 | + ) |
59 | 60 |
|
60 | 61 |
|
61 | 62 | class FitTensorOutputSpec(TraitedSpec):
|
@@ -89,8 +90,7 @@ def _list_outputs(self):
|
89 | 90 | outputs = self.output_spec().get()
|
90 | 91 | outputs["out_file"] = op.abspath(self.inputs.out_file)
|
91 | 92 | if isdefined(self.inputs.predicted_signal):
|
92 |
| - outputs['predicted_signal'] = op.abspath( |
93 |
| - self.inputs.predicted_signal) |
| 93 | + outputs["predicted_signal"] = op.abspath(self.inputs.predicted_signal) |
94 | 94 | return outputs
|
95 | 95 |
|
96 | 96 |
|
@@ -155,13 +155,15 @@ class EstimateFODInputSpec(MRTrix3BaseInputSpec):
|
155 | 155 | ),
|
156 | 156 | )
|
157 | 157 | predicted_signal = File(
|
158 |
| - argstr='-predicted_signal %s', |
| 158 | + argstr="-predicted_signal %s", |
159 | 159 | desc=(
|
160 | 160 | "specify a file to contain the predicted signal from the FOD "
|
161 | 161 | "estimates. This can be used to calculate the residual signal."
|
162 | 162 | "Note that this is only valid if algorithm == 'msmt_csd'. "
|
163 | 163 | "For single shell reconstructions use a combination of SHConv "
|
164 |
| - "and SH2Amp instead.")) |
| 164 | + "and SH2Amp instead." |
| 165 | + ), |
| 166 | + ) |
165 | 167 |
|
166 | 168 |
|
167 | 169 | class EstimateFODOutputSpec(TraitedSpec):
|
@@ -207,12 +209,12 @@ def _list_outputs(self):
|
207 | 209 | if isdefined(self.inputs.csf_odf):
|
208 | 210 | outputs["csf_odf"] = op.abspath(self.inputs.csf_odf)
|
209 | 211 | if isdefined(self.inputs.predicted_signal):
|
210 |
| - if self.inputs.algorithm != 'msmt_csd': |
| 212 | + if self.inputs.algorithm != "msmt_csd": |
211 | 213 | raise Exception(
|
212 | 214 | "'predicted_signal' option can only be used with "
|
213 |
| - "the 'msmt_csd' algorithm") |
214 |
| - outputs["predicted_signal"] = op.abspath( |
215 |
| - self.inputs.predicted_signal) |
| 215 | + "the 'msmt_csd' algorithm" |
| 216 | + ) |
| 217 | + outputs["predicted_signal"] = op.abspath(self.inputs.predicted_signal) |
216 | 218 | return outputs
|
217 | 219 |
|
218 | 220 |
|
|
0 commit comments