NIPY logo
Home · Quickstart · Documentation · Citation · NiPy
Loading

Table Of Contents

Versions

ReleaseDevel
0.6.0pre-0.7
Download Github

Links

interfaces.ants.coregister

GenWarpFields

Code: file:///build/buildd/nipype-0.6.0/nipype/interfaces/ants/coregister.py#L69

Wraps command antsIntroduction.sh

Uses ANTS to generate matrices to warp data from one space to another.

Examples

>>> from nipype.interfaces.ants import GenWarpFields
>>> warp = GenWarpFields()
>>> warp.inputs.reference_image = 'Template_6.nii'
>>> warp.inputs.input_image = 'structural.nii'
>>> warp.inputs.max_iterations = [30,90,20]
>>> warp.cmdline
'antsIntroduction.sh -d 3 -i structural.nii -m 30x90x20 -o ants_ -r Template_6.nii -t GR'

Inputs:

[Mandatory]
input_image: (an existing file name)
        input image to warp to template
reference_image: (an existing file name)
        template file to warp to

[Optional]
args: (a string)
        Additional parameters to the command
bias_field_correction: (a boolean)
        Applies bias field correction to moving image
dimension: (3 or 2, nipype default value: 3)
        image dimension (2 or 3)
environ: (a dictionary with keys which are a value of type 'str' and with values which
         are a value of type 'str', nipype default value: {})
        Environment variables
force_proceed: (a boolean)
        force script to proceed even if headers may be incompatible
ignore_exception: (a boolean, nipype default value: False)
        Print an error message instead of throwing an exception in case the interface fails to
        run
inverse_warp_template_labels: (a boolean)
        Applies inverse warp to the template labels to estimate label positions in target space
        (use for template-based segmentation)
max_iterations: (a list of items which are an integer)
        maximum number of iterations (must be list of integers in the form [J,K,L...]: J =
        coarsest resolution iterations, K = middle resolution interations, L = fine resolution
        iterations
num_threads: (an integer, nipype default value: 1)
        Number of ITK threads to use
out_prefix: (a string, nipype default value: ants_)
        Prefix that is prepended to all output files (default = ants_)
quality_check: (a boolean)
        Perform a quality check of the result
similarity_metric: ('PR' or 'CC' or 'MI' or 'MSQ')
        Type of similartiy metric used for registration (CC = cross correlation, MI = mutual
        information, PR = probability mapping, MSQ = mean square difference)
transformation_model: ('GR' or 'EL' or 'SY' or 'S2' or 'EX' or 'DD' or 'RI' or 'RA',
         nipype default value: GR)
        Type of transofmration model used for registration (EL = elastic transformation model,
        SY = SyN with time, arbitrary number of time points, S2 =  SyN with time optimized for 2
        time points, GR = greedy SyN, EX = exponential, DD = diffeomorphic demons style
        exponential mapping, RI = purely rigid, RA = affine rigid

Outputs:

affine_transformation: (an existing file name)
        affine (prefix_Affine.txt)
input_file: (an existing file name)
        input image (prefix_repaired.nii)
inverse_warp_field: (an existing file name)
        inverse warp field (prefix_InverseWarp.nii)
output_file: (an existing file name)
        output image (prefix_deformed.nii)
warp_field: (an existing file name)
        warp field (prefix_Warp.nii)