Skip to content

ENH: antsIntroduction handles RA and RI transformations #1009

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 5 commits into from
Jan 20, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGES
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Next release
============

* ENH: Updated antsIntroduction to handle RA and RI registrations (https://github.com/nipy/nipype/pull/1009)
* ENH: Updated N4BiasCorrection input spec to include weight image and spline order. Made
argument formatting consistent. Cleaned ants.segmentation according to PEP8.
(https://github.com/nipy/nipype/pull/990/files)
Expand Down
17 changes: 11 additions & 6 deletions nipype/interfaces/ants/legacy.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,16 +94,21 @@ class antsIntroduction(ANTSCommand):

def _list_outputs(self):
outputs = self._outputs().get()
transmodel = self.inputs.transformation_model

# When transform is set as 'RI'/'RA', wrap fields should not be expected
# The default transformation is GR, which outputs the wrap fields
if not isdefined(transmodel) or (isdefined(transmodel) and transmodel not in ['RI', 'RA']):
outputs['warp_field'] = os.path.join(os.getcwd(),
self.inputs.out_prefix +
'Warp.nii.gz')
outputs['inverse_warp_field'] = os.path.join(os.getcwd(),
self.inputs.out_prefix +
'InverseWarp.nii.gz')

outputs['affine_transformation'] = os.path.join(os.getcwd(),
self.inputs.out_prefix +
'Affine.txt')
outputs['warp_field'] = os.path.join(os.getcwd(),
self.inputs.out_prefix +
'Warp.nii.gz')
outputs['inverse_warp_field'] = os.path.join(os.getcwd(),
self.inputs.out_prefix +
'InverseWarp.nii.gz')
outputs['input_file'] = os.path.join(os.getcwd(),
self.inputs.out_prefix +
'repaired.nii.gz')
Expand Down