@@ -817,7 +817,9 @@ def _gen_filename(self, name):
817817
818818class ReconAllInputSpec (CommandLineInputSpec ):
819819 subject_id = traits .Str (
820- "recon_all" , argstr = "-subjid %s" , desc = "subject name" ,
820+ "recon_all" ,
821+ argstr = "-subjid %s" ,
822+ desc = "subject name" ,
821823 )
822824 directive = traits .Enum (
823825 "all" ,
@@ -932,7 +934,7 @@ class ReconAllInputSpec(CommandLineInputSpec):
932934 base_template_id = traits .Str (
933935 argstr = "-base %s" ,
934936 desc = "base template id" ,
935- xor = ["subject_id" ,"longitudinal_timepoint_id" ],
937+ xor = ["subject_id" , "longitudinal_timepoint_id" ],
936938 requires = ["base_timepoint_ids" ],
937939 )
938940 base_timepoint_ids = InputMultiObject (
@@ -943,14 +945,12 @@ class ReconAllInputSpec(CommandLineInputSpec):
943945 longitudinal_timepoint_id = traits .Str (
944946 argstr = "-long %s" ,
945947 desc = "longitudinal session/timepoint id" ,
946- xor = ["subject_id" ,"base_template_id" ],
948+ xor = ["subject_id" , "base_template_id" ],
947949 requires = ["longitudinal_template_id" ],
948- position = 1
950+ position = 1 ,
949951 )
950952 longitudinal_template_id = traits .Str (
951- argstr = "%s" ,
952- desc = "longitudinal base tempalte id" ,
953- position = 2
953+ argstr = "%s" , desc = "longitudinal base tempalte id" , position = 2
954954 )
955955
956956 # Expert options
@@ -1572,13 +1572,14 @@ def _list_outputs(self):
15721572 if isdefined (self .inputs .base_template_id ):
15731573 outputs .update (
15741574 FreeSurferSource (
1575- subject_id = self .inputs .base_template_id , subjects_dir = subjects_dir ,
1576- hemi = hemi
1575+ subject_id = self .inputs .base_template_id ,
1576+ subjects_dir = subjects_dir ,
1577+ hemi = hemi ,
15771578 )._list_outputs ()
15781579 )
15791580 outputs ["subject_id" ] = self .inputs .base_template_id
15801581 elif isdefined (self .inputs .longitudinal_timepoint_id ):
1581- subject_id = f"{ self .inputs .longitudinal_timepoint_id } .long.{ self .inputs .longitudinal_template_id } "
1582+ subject_id = f"{ self .inputs .longitudinal_timepoint_id } .long.{ self .inputs .longitudinal_template_id } "
15821583 outputs .update (
15831584 FreeSurferSource (
15841585 subject_id = subject_id , subjects_id = subjects_dir , hemi = hemi
@@ -1588,7 +1589,9 @@ def _list_outputs(self):
15881589 else :
15891590 outputs .update (
15901591 FreeSurferSource (
1591- subject_id = self .inputs .subject_id , subjects_dir = subjects_dir , hemi = hemi
1592+ subject_id = self .inputs .subject_id ,
1593+ subjects_dir = subjects_dir ,
1594+ hemi = hemi ,
15921595 )._list_outputs ()
15931596 )
15941597 outputs ["subject_id" ] = self .inputs .subject_id
@@ -1604,12 +1607,18 @@ def _is_resuming(self):
16041607 # Check for longitudinal pipeline
16051608 if not isdefined (self .inputs .subject_id ):
16061609 if isdefined (self .inputs .base_template_id ):
1607- if os .path .isdir (os .path .join (subjects_dir , self .inputs .base_template_id , "mri" )):
1610+ if os .path .isdir (
1611+ os .path .join (subjects_dir , self .inputs .base_template_id , "mri" )
1612+ ):
16081613 return True
16091614 elif isdefined (self .inputs .longitudinal_template_id ):
1610- if os .path .isdir (os .path .join (subjects_dir ,
1611- f"{ self .inputs .longitudinal_timepoint_id } .long.{ self .inputs .longitudinal_template_id } " ,
1612- "mri" )):
1615+ if os .path .isdir (
1616+ os .path .join (
1617+ subjects_dir ,
1618+ f"{ self .inputs .longitudinal_timepoint_id } .long.{ self .inputs .longitudinal_template_id } " ,
1619+ "mri" ,
1620+ )
1621+ ):
16131622 return True
16141623 else :
16151624 if os .path .isdir (os .path .join (subjects_dir , self .inputs .subject_id , "mri" )):
0 commit comments