From eda649755b4090ebaa959a771829fec1f9db3ba0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Toomas=20Erik=20Anij=C3=A4rv?= Date: Wed, 28 Feb 2024 09:03:21 +0100 Subject: [PATCH] Fix generate5tt input --- nipype/interfaces/mrtrix3/utils.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/nipype/interfaces/mrtrix3/utils.py b/nipype/interfaces/mrtrix3/utils.py index d0b474a76b..cb6b31ae91 100644 --- a/nipype/interfaces/mrtrix3/utils.py +++ b/nipype/interfaces/mrtrix3/utils.py @@ -11,6 +11,7 @@ traits, TraitedSpec, File, + Directory, InputMultiPath, isdefined, ) @@ -230,8 +231,10 @@ class Generate5ttInputSpec(MRTrix3BaseInputSpec): mandatory=True, desc="tissue segmentation algorithm", ) - in_file = File( - exists=False, argstr="%s", mandatory=True, position=-2, desc="input image" + in_file = traits.Either( + File(exists=True), + Directory(exists=True), + argstr="%s", mandatory=True, position=-2, desc="input image / directory" ) out_file = File(argstr="%s", mandatory=True, position=-1, desc="output image")