10000 ENH: Add inputs to mrtrix3.DWIPreprocInputSpec and remove mandatory annotation for pe_dir by GalKepler · Pull Request #3470 · nipy/nipype · GitHub
[go: up one dir, main page]

Skip to content

ENH: Add inputs to mrtrix3.DWIPreprocInputSpec and remove mandatory annotation for pe_dir #3470

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Jul 23, 2022
Prev Previous commit
Next Next commit
removed default values for gradients' files outputs
  • Loading branch information
GalKepler committed May 12, 2022
commit 9d372603aa76811b6cca41217a535eac7d8cdbdc
25 changes: 17 additions & 8 deletions nipype/interfaces/mrtrix3/preprocess.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,9 @@ class DWIBiasCorrectInputSpec(MRTrix3BaseInputSpec):
mandatory=True,
desc="input DWI image",
)
in_mask = File(argstr="-mask %s", desc="input mask image for bias field estimation")
in_mask = File(
argstr="-mask %s", desc="input mask image for bias field estimation"
)
use_ants = traits.Bool(
argstr="ants",
mandatory=True,
Expand Down Expand Up @@ -343,13 +345,12 @@ class DWIPreprocInputSpec(MRTrix3BaseInputSpec):
out_grad_mrtrix = File(
"grad.b",
argstr="%s",
usedefault=True,
requires=["export_grad_mrtrix"],
desc="name of new gradient file",
)
out_grad_fsl = traits.Tuple(
File("grad.bvecs", usedefault=True, desc="bvecs"),
File("grad.bvals", usedefault=True, desc="bvals"),
File("grad.bvecs", desc="bvecs"),
File("grad.bvals", desc="bvals"),
argstr="%s, %s",
requires=["export_grad_fsl"],
desc="Output (bvecs, bvals) gradients FSL format",
Expand Down Expand Up @@ -410,7 +411,9 @@ def _list_outputs(self):
outputs = self.output_spec().get()
outputs["out_file"] = op.abspath(self.inputs.out_file)
if self.inputs.export_grad_mrtrix:
outputs["out_grad_mrtrix"] = op.abspath(self.inputs.out_grad_mrtrix)
outputs["out_grad_mrtrix"] = op.abspath(
self.inputs.out_grad_mrtrix
)
if self.inputs.export_grad_fsl:
outputs["out_fsl_bvec"] = op.abspath(self.inputs.out_grad_fsl[0])
outputs["out_fsl_bval"] = op.abspath(self.inputs.out_grad_fsl[1])
Expand Down Expand Up @@ -444,9 +447,15 @@ class ResponseSDInputSpec(MRTrix3BaseInputSpec):
usedefault=True,
desc="output WM response text file",
)
gm_file = File(argstr="%s", position=-2, desc="output GM response text file")
csf_file = File(argstr="%s", position=-1, desc="output CSF response text file")
in_mask = File(exists=True, argstr="-mask %s", desc="provide initial mask image")
gm_file = File(
argstr="%s", position=-2, desc="output GM response text file"
)
csf_file = File(
argstr="%s", position=-1, desc="output CSF response text file"
)
in_mask = File(
exists=True, argstr="-mask %s", desc="provide initial mask image"
)
max_sh = InputMultiObject(
traits.Int,
argstr="-lmax %s",
Expand Down
0