@@ -133,14 +133,14 @@ class ExtractROIBasedSurfaceMeasuresInputSpec(SPMCommandInputSpec):
133133 lh_roi_atlas = InputMultiPath (File (exists = True ), field = "rdata" , desc = "(Left) ROI Atlas. These are the ROI's " ,
134134 mandatory = True , copyfile = False )
135135
136+ rh_roi_atlas = InputMultiPath (File (exists = True ), desc = "(Right) ROI Atlas. These are the ROI's " ,
137+ mandatory = False , copyfile = False )
138+
136139 lh_surface_measure = InputMultiPath (File (exists = True ), field = "cdata" , desc = "(Left) Surface data files. " ,
137140 mandatory = True , copyfile = False )
138141 rh_surface_measure = InputMultiPath (File (exists = True ), desc = "(Right) Surface data files." ,
139142 mandatory = False , copyfile = False )
140143
141- rh_roi_atlas = InputMultiPath (File (exists = True ), desc = "(Right) ROI Atlas. These are the ROI's " ,
142- mandatory = False , copyfile = False )
143-
144144
145145class ExtractROIBasedSurfaceMeasuresOutputSpec (TraitedSpec ):
146146 label_files = List (File (exists = True ), desc = "Files with the measures extracted for ROIs." )
@@ -194,13 +194,12 @@ def _format_arg(self, opt, spec, val):
194194 def _list_outputs (self ):
195195 outputs = self ._outputs ().get ()
196196
197- outputs ["label_files" ] = []
198- for f in self .inputs .lh_roi_atlas :
199- pth , base , ext = split_filename (f )
197+ pth , base , ext = split_filename (self .inputs .lh_surface_measure [0 ])
200198
201- outputs ["label_files" ].extend ([os .path .join (os .path .join (pth , "label" ), f ) for f in
202- os .listdir (os .path .join (pth , "label" ))
203- if os .path .isfile (os .path .join (os .path .join (pth , "label" ), f ))])
199+ outputs ["label_files" ] = [os .path .join (os .path .join (pth , "label" ), f ) for f in
200+ os .listdir (os .path .join (pth , "label" ))
201+ if os .path .isfile (os .path .join (os .path .join (pth , "label" ), f ))]
202+ return outputs
204203
205204
206205class Cell :
@@ -227,4 +226,3 @@ def __str__(self):
227226 """Convert input to appropriate format for cat12
228227 """
229228 return "{%s}" % self .to_string ()
230-
0 commit comments