Skip to content

Commit 50b89c4

Browse files
authored
Use out_prefix instead of "w" in spm.Normalize12
Currently, for the Normalize12 process in spm, the user can define the out_prefix parameter, but this is not used to generate output, as it is hard-coded to 'w' in Normalize12._list_outputs().
1 parent 83d52f9 commit 50b89c4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Diff for: nipype/interfaces/spm/preprocess.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -1491,13 +1491,13 @@ def _list_outputs(self):
14911491
filelist = ensure_list(self.inputs.apply_to_files)
14921492
for f in filelist:
14931493
if isinstance(f, list):
1494-
run = [fname_presuffix(in_f, prefix="w") for in_f in f]
1494+
run = [fname_presuffix(in_f, prefix=self.inputs.out_prefix) for in_f in f]
14951495
else:
1496-
run = [fname_presuffix(f, prefix="w")]
1496+
run = [fname_presuffix(f, prefix=self.inputs.out_prefix)]
14971497
outputs["normalized_files"].extend(run)
14981498
if isdefined(self.inputs.image_to_align):
14991499
outputs["normalized_image"] = fname_presuffix(
1500-
self.inputs.image_to_align, prefix="w"
1500+
self.inputs.image_to_align, prefix=self.inputs.out_prefix
15011501
)
15021502

15031503
return outputs

0 commit comments

Comments
 (0)