.. AUTO-GENERATED FILE -- DO NOT EDIT!

interfaces.niftyfit.dwi
=======================


.. _nipype.interfaces.niftyfit.dwi.DwiTool:


.. index:: DwiTool

DwiTool
-------

`Link to code <file:///build/nipype-1.1.8/nipype/interfaces/niftyfit/dwi.py#L454>`__

Wraps the executable command ``dwi_tool``.

Interface for executable dwi_tool from Niftyfit platform.

Use DwiTool.

Diffusion-Weighted MR Prediction.
Predicts DWI from previously fitted models and calculates model derived
maps.

`Source code <https://cmiclab.cs.ucl.ac.uk/CMIC/NiftyFit-Release>`_

Examples
~~~~~~~~

>>> from nipype.interfaces import niftyfit
>>> dwi_tool = niftyfit.DwiTool(dti_flag=True)
>>> dwi_tool.inputs.source_file = 'dwi.nii.gz'
>>> dwi_tool.inputs.bvec_file = 'bvecs'
>>> dwi_tool.inputs.bval_file = 'bvals'
>>> dwi_tool.inputs.mask_file = 'mask.nii.gz'
>>> dwi_tool.inputs.b0_file = 'b0.nii.gz'
>>> dwi_tool.inputs.rgbmap_file = 'rgb_map.nii.gz'
>>> dwi_tool.cmdline
'dwi_tool -source dwi.nii.gz -bval bvals -bvec bvecs -b0 b0.nii.gz -mask mask.nii.gz -dti -famap dwi_famap.nii.gz -logdti2 dwi_logdti2.nii.gz -mcmap dwi_mcmap.nii.gz -mdmap dwi_mdmap.nii.gz -rgbmap rgb_map.nii.gz -syn dwi_syn.nii.gz -v1map dwi_v1map.nii.gz'

Inputs::

        [Mandatory]
        bval_file: (a file name)
                The file containing the bvalues of the source DWI.
                argument: ``-bval %s``, position: 2
        source_file: (a file name)
                The source image containing the fitted model.
                argument: ``-source %s``, position: 1

        [Optional]
        v1map_file: (a file name)
                Filename of PDD map [x,y,z]
                argument: ``-v1map %s``
        mono_flag: (a boolean)
                Input is a single exponential to non-directional data [default with
                no b-vectors]
                argument: ``-mono``, position: 6
                mutually_exclusive: ivim_flag, dti_flag, dti_flag2, ball_flag,
                  ballv_flag, nod_flag, nodv_flag
        dti_flag: (a boolean)
                Input is a tensor model diag/off-diag.
                argument: ``-dti``, position: 6
                mutually_exclusive: mono_flag, ivim_flag, dti_flag2, ball_flag,
                  ballv_flag, nod_flag, nodv_flag
        mcmap_file: (a file name)
                Filename of multi-compartment model parameter map (-ivim,-ball,-nod)
                argument: ``-mcmap %s``
        environ: (a dictionary with keys which are a newbytes or None or a
                  newstr or None and with values which are a newbytes or None or a
                  newstr or None, nipype default value: {})
                Environment variables
        ballv_flag: (a boolean)
                Input is a ball and stick model with optimised PDD.
                argument: ``-ballv``, position: 6
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, dti_flag2,
                  ball_flag, nod_flag, nodv_flag
        nodv_flag: (a boolean)
                Input is a NODDI model with optimised PDD
                argument: ``-nodv``, position: 6
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, dti_flag2,
                  ball_flag, ballv_flag, nod_flag
        diso_val: (a float)
                Isotropic diffusivity for -nod [3e-3]
                argument: ``-diso %f``
        rgbmap_file: (a file name)
                Filename of colour FA map.
                argument: ``-rgbmap %s``
        famap_file: (a file name)
                Filename of FA map
                argument: ``-famap %s``
        dti_flag2: (a boolean)
                Input is a tensor model lower triangular
                argument: ``-dti2``, position: 6
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, ball_flag,
                  ballv_flag, nod_flag, nodv_flag
        args: (a unicode string)
                Additional parameters to the command
                argument: ``%s``
        mdmap_file: (a file name)
                Filename of MD map/ADC
                argument: ``-mdmap %s``
        syn_file: (a file name)
                Filename of synthetic image. Requires: bvec_file/b0_file.
                argument: ``-syn %s``
                requires: bvec_file, b0_file
        bvec_file: (a file name)
                The file containing the bvectors of the source DWI.
                argument: ``-bvec %s``, position: 3
        b0_file: (a file name)
                The B0 image corresponding to the source DWI
                argument: ``-b0 %s``, position: 4
        ivim_flag: (a boolean)
                Inputs is an IVIM model to non-directional data.
                argument: ``-ivim``, position: 6
                mutually_exclusive: mono_flag, dti_flag, dti_flag2, ball_flag,
                  ballv_flag, nod_flag, nodv_flag
        dpr_val: (a float)
                Parallel diffusivity for -nod [1.7e-3].
                argument: ``-dpr %f``
        nod_flag: (a boolean)
                Input is a NODDI model
                argument: ``-nod``, position: 6
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, dti_flag2,
                  ball_flag, ballv_flag, nodv_flag
        ball_flag: (a boolean)
                Input is a ball and stick model.
                argument: ``-ball``, position: 6
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, dti_flag2,
                  ballv_flag, nod_flag, nodv_flag
        mask_file: (a file name)
                The image mask
                argument: ``-mask %s``, position: 5
        logdti_file: (a file name)
                Filename of output logdti map.
                argument: ``-logdti2 %s``

Outputs::

        famap_file: (a file name)
                Filename of FA map
        mcmap_file: (a file name)
                Filename of multi-compartment model parameter map (-ivim,-ball,-nod)
        v1map_file: (a file name)
                Filename of PDD map [x,y,z]
        mdmap_file: (a file name)
                Filename of MD map/ADC
        syn_file: (a file name)
                Filename of synthetic image
        rgbmap_file: (a file name)
                Filename of colour FA map
        logdti_file: (a file name)
                Filename of output logdti map

.. _nipype.interfaces.niftyfit.dwi.FitDwi:


.. index:: FitDwi

FitDwi
------

`Link to code <file:///build/nipype-1.1.8/nipype/interfaces/niftyfit/dwi.py#L257>`__

Wraps the executable command ``fit_dwi``.

Interface for executable fit_dwi from Niftyfit platform.

Use NiftyFit to perform diffusion model fitting.

Diffusion-weighted MR Fitting.
Fits DWI parameter maps to multi-shell, multi-directional data.

`Source code <https://cmiclab.cs.ucl.ac.uk/CMIC/NiftyFit-Release>`_

Examples
~~~~~~~~

>>> from nipype.interfaces import niftyfit
>>> fit_dwi = niftyfit.FitDwi(dti_flag=True)
>>> fit_dwi.inputs.source_file = 'dwi.nii.gz'
>>> fit_dwi.inputs.bvec_file = 'bvecs'
>>> fit_dwi.inputs.bval_file = 'bvals'
>>> fit_dwi.inputs.rgbmap_file = 'rgb.nii.gz'
>>> fit_dwi.cmdline
'fit_dwi -source dwi.nii.gz -bval bvals -bvec bvecs -dti -error dwi_error.nii.gz -famap dwi_famap.nii.gz -mcout dwi_mcout.txt -mdmap dwi_mdmap.nii.gz -nodiff dwi_no_diff.nii.gz -res dwi_resmap.nii.gz -rgbmap rgb.nii.gz -syn dwi_syn.nii.gz -tenmap2 dwi_tenmap2.nii.gz -v1map dwi_v1map.nii.gz'

Inputs::

        [Mandatory]
        bval_file: (a file name)
                The file containing the bvalues of the source DWI.
                argument: ``-bval %s``, position: 2
        source_file: (a file name)
                The source image containing the dwi data.
                argument: ``-source %s``, position: 1
        bvec_file: (a file name)
                The file containing the bvectors of the source DWI.
                argument: ``-bvec %s``, position: 3

        [Optional]
        maxit_val: (an integer (int or long))
                Maximum number of non-linear LSQR iterations [100x2 passes])
                argument: ``-maxit %d``
                requires: gn_flag
        voxel: (a tuple of the form: (an integer (int or long), an integer
                  (int or long), an integer (int or long)))
                Fit to single voxel only.
                argument: ``-voxel %d %d %d``
        vb_flag: (a boolean)
                Use Variational Bayes fitting with known prior (currently identity
                covariance...).
                argument: ``-vb``
        mcout: (a file name)
                Filename of mc samples (ascii text file)
                argument: ``-mcout %s``
        mono_flag: (a boolean)
                Fit single exponential to non-directional data [default with no
                b-vectors]
                argument: ``-mono``, position: 4
                mutually_exclusive: ivim_flag, dti_flag, ball_flag, ballv_flag,
                  nod_flag, nodv_flag
        v1map_file: (a file name)
                Filename of PDD map [x,y,z]
                argument: ``-v1map %s``
        lm_vals: (a tuple of the form: (a float, a float))
                LM parameters (initial value, decrease rate) [100,1.2].
                argument: ``-lm %f %f``
                requires: gn_flag
        prior_file: (a file name)
                Filename of parameter priors for -ball and -nod.
                argument: ``-prior %s``
        te_value: (a file name)
                Value of TEs (ms).
                argument: ``-TE %s``
                mutually_exclusive: te_file
        ten_type: ('lower-tri' or 'diag-off-diag', nipype default value:
                  lower-tri)
                Use lower triangular (tenmap2) or diagonal, off-diagonal tensor
                format
        dti_flag: (a boolean)
                Fit the tensor model [default with b-vectors].
                argument: ``-dti``, position: 4
                mutually_exclusive: mono_flag, ivim_flag, ball_flag, ballv_flag,
                  nod_flag, nodv_flag
        nodiff_file: (a file name)
                Filename of average no diffusion image.
                argument: ``-nodiff %s``
        mcmap_file: (a file name)
                Filename of multi-compartment model parameter map (-ivim,-ball,-nod)
                argument: ``-mcmap %s``
                requires: nodv_flag
        acceptance: (a float)
                Fraction of iterations to accept [0.23].
                argument: ``-accpetance %f``
        mcsamples: (an integer (int or long))
                Number of samples to keep [100].
                argument: ``-mcsamples %d``
        environ: (a dictionary with keys which are a newbytes or None or a
                  newstr or None and with values which are a newbytes or None or a
                  newstr or None, nipype default value: {})
                Environment variables
        ballv_flag: (a boolean)
                Fit the ball and stick model with optimised PDD.
                argument: ``-ballv``, position: 4
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, ball_flag,
                  nod_flag, nodv_flag
        swls_val: (a float)
                Use location-weighted least squares for DTI fitting [3x3 Gaussian]
                argument: ``-swls %f``
        wls_flag: (a boolean)
                Use Variational Bayes fitting with known prior (currently identity
                covariance...).
                argument: ``-wls``
                mutually_exclusive: gn_flag
        perf_thr: (a float)
                Threshold for perfusion/diffsuion effects [100].
                argument: ``-perfthreshold %f``
        te_file: (a file name)
                Filename of TEs (ms).
                argument: ``-TE %s``
                mutually_exclusive: te_file
        nodv_flag: (a boolean)
                Fit the NODDI model with optimised PDD
                argument: ``-nodv``, position: 4
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, ball_flag,
                  ballv_flag, nod_flag
        diso_val: (a float)
                Isotropic diffusivity for -nod [3e-3]
                argument: ``-diso %f``
        rgbmap_file: (a file name)
                Filename of colour-coded FA map
                argument: ``-rgbmap %s``
                requires: dti_flag
        famap_file: (a file name)
                Filename of FA map
                argument: ``-famap %s``
        gn_flag: (a boolean)
                Use Gauss-Newton algorithm [Levenberg-Marquardt].
                argument: ``-gn``
                mutually_exclusive: wls_flag
        tenmap_file: (a file name)
                Filename of tensor map [diag,offdiag].
                argument: ``-tenmap %s``
                requires: dti_flag
        args: (a unicode string)
                Additional parameters to the command
                argument: ``%s``
        error_file: (a file name)
                Filename of parameter error maps.
                argument: ``-error %s``
        mdmap_file: (a file name)
                Filename of MD map/ADC
                argument: ``-mdmap %s``
        syn_file: (a file name)
                Filename of synthetic image.
                argument: ``-syn %s``
        tenmap2_file: (a file name)
                Filename of tensor map [lower tri]
                argument: ``-tenmap2 %s``
                requires: dti_flag
        slice_no: (an integer (int or long))
                Fit to single slice number.
                argument: ``-slice %d``
        cov_file: (a file name)
                Filename of ithe nc*nc covariance matrix [I]
                argument: ``-cov %s``
        wm_t2_val: (a float)
                White matter T2 value [80ms].
                argument: ``-wmT2 %f``
        csf_t2_val: (a float)
                CSF T2 value [400ms].
                argument: ``-csfT2 %f``
        ivim_flag: (a boolean)
                Fit IVIM model to non-directional data.
                argument: ``-ivim``, position: 4
                mutually_exclusive: mono_flag, dti_flag, ball_flag, ballv_flag,
                  nod_flag, nodv_flag
        res_file: (a file name)
                Filename of model residual map.
                argument: ``-res %s``
        mcmaxit: (an integer (int or long))
                Number of iterations to run [10,000].
                argument: ``-mcmaxit %d``
        dpr_val: (a float)
                Parallel diffusivity for -nod [1.7e-3].
                argument: ``-dpr %f``
        nod_flag: (a boolean)
                Fit the NODDI model
                argument: ``-nod``, position: 4
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, ball_flag,
                  ballv_flag, nodv_flag
        ball_flag: (a boolean)
                Fit the ball and stick model.
                argument: ``-ball``, position: 4
                mutually_exclusive: mono_flag, ivim_flag, dti_flag, ballv_flag,
                  nod_flag, nodv_flag
        mask_file: (a file name)
                The image mask
                argument: ``-mask %s``
        rot_sform_flag: (an integer (int or long))
                Rotate the output tensors according to the q/s form of the image
                (resulting tensors will be in mm coordinates, default: 0).
                argument: ``-rotsform %d``

Outputs::

        v1map_file: (a file name)
                Filename of PDD map [x,y,z]
        mcout: (a file name)
                Filename of mc samples (ascii text file)
        nodiff_file: (a file name)
                Filename of average no diffusion image.
        tenmap_file: (a file name)
                Filename of tensor map
        res_file: (a file name)
                Filename of model residual map
        error_file: (a file name)
                Filename of parameter error maps
        mdmap_file: (a file name)
                Filename of MD map/ADC
        syn_file: (a file name)
                Filename of synthetic image
        famap_file: (a file name)
                Filename of FA map
        tenmap2_file: (a file name)
                Filename of tensor map [lower tri]
        mcmap_file: (a file name)
                Filename of multi-compartment model parameter map
                (-ivim,-ball,-nod).
        rgbmap_file: (a file name)
                Filename of colour FA map
