AFQ.tasks.data

Module Contents

Functions

get_data_gtab(subses_dict, bval_file, bvec_file, min_bval=None, max_bval=None, filter_b=True, b0_threshold=50)

DWI data as an ndarray for selected b values,

b0(subses_dict, data, gtab, img)

full path to a nifti file containing the mean b0

b0_mask(subses_dict, b0_file, brain_mask_file)

full path to a nifti file containing the

dti_fit(dti_params_file, gtab)

DTI TensorFit object

dti(subses_dict, dwi_affine, brain_mask_file, data, gtab, bval_file, bvec_file, b0_threshold=50, robust_tensor_fitting=False)

full path to a nifti file containing parameters

dki_fit(dki_params_file, gtab)

DKI DiffusionKurtosisFit object

dki(subses_dict, dwi_affine, brain_mask_file, gtab, data)

full path to a nifti file containing

csd(subses_dict, dwi_affine, brain_mask_file, gtab, data, tracking_params, csd_response=None, csd_sh_order=None, csd_lambda_=1, csd_tau=0.1)

full path to a nifti file containing

anisotropic_power_map(subses_dict, csd_params_file)

full path to a nifti file containing

dti_fa(subses_dict, dwi_affine, dti_params_file, dti_tf)

full path to a nifti file containing

dti_cfa(subses_dict, dwi_affine, dti_params_file, dti_tf)

full path to a nifti file containing

dti_pdd(subses_dict, dwi_affine, dti_params_file, dti_tf)

full path to a nifti file containing

dti_md(subses_dict, dwi_affine, dti_params_file, dti_tf)

full path to a nifti file containing

dti_ga(subses_dict, dwi_affine, dti_params_file, dti_tf)

full path to a nifti file containing

dti_rd(subses_dict, dwi_affine, dti_params_file, dti_tf)

full path to a nifti file containing

dti_ad(subses_dict, dwi_affine, dti_params_file, dti_tf)

full path to a nifti file containing

dki_fa(subses_dict, dwi_affine, dki_params_file, dki_tf)

full path to a nifti file containing

dki_md(subses_dict, dwi_affine, dki_params_file, dki_tf)

full path to a nifti file containing

dki_awf(subses_dict, dwi_affine, dki_params_file, dki_tf, sphere='repulsion100', gtol=0.01)

full path to a nifti file containing

dki_mk(subses_dict, dwi_affine, dki_params_file, dki_tf)

full path to a nifti file containing

dki_ga(subses_dict, dwi_affine, dki_params_file, dki_tf)

full path to a nifti file containing

dki_rd(subses_dict, dwi_affine, dki_params_file, dki_tf)

full path to a nifti file containing

dki_ad(subses_dict, dwi_affine, dki_params_file, dki_tf)

full path to a nifti file containing

dki_rk(subses_dict, dwi_affine, dki_params_file, dki_tf)

full path to a nifti file containing

dki_ak(subses_dict, dwi_affine, dki_params_file, dki_tf)

full path to a nifti file containing

brain_mask(subses_dict, dwi_affine, b0_file, bids_info, brain_mask_definition=None)

full path to a nifti file containing

get_bundle_dict(segmentation_params, brain_mask_file, bundle_info=None, reg_template_spec='mni_T1')

Dictionary defining the different bundles to be segmented,

get_data_plan(kwargs)

Attributes

DIPY_GH

dti_params

dki_params

csd_params

AFQ.tasks.data.DIPY_GH = https://github.com/dipy/dipy/blob/master/dipy/[source]
AFQ.tasks.data.get_data_gtab(subses_dict, bval_file, bvec_file, min_bval=None, max_bval=None, filter_b=True, b0_threshold=50)[source]

DWI data as an ndarray for selected b values, A DIPY GradientTable with all the gradient information, and unaltered DWI data in a Nifti1Image.

Parameters
min_bvalfloat, optional

Minimum b value you want to use from the dataset (other than b0), inclusive. If None, there is no minimum limit. Default: None

max_bvalfloat, optional

Maximum b value you want to use from the dataset (other than b0), inclusive. If None, there is no maximum limit. Default: None

filter_bbool, optional

Whether to filter the DWI data based on min or max bvals. Default: True

b0_thresholdint, optional

The value of b under which it is considered to be b0. Default: 50.

AFQ.tasks.data.b0(subses_dict, data, gtab, img)[source]

full path to a nifti file containing the mean b0

AFQ.tasks.data.b0_mask(subses_dict, b0_file, brain_mask_file)[source]

full path to a nifti file containing the mean b0 after applying the brain mask

AFQ.tasks.data.dti_fit(dti_params_file, gtab)[source]

DTI TensorFit object

AFQ.tasks.data.dti(subses_dict, dwi_affine, brain_mask_file, data, gtab, bval_file, bvec_file, b0_threshold=50, robust_tensor_fitting=False)[source]

full path to a nifti file containing parameters for the DTI fit

Parameters
robust_tensor_fittingbool, optional

Whether to use robust_tensor_fitting when doing dti. Only applies to dti. Default: False

b0_thresholdint, optional

The value of b under which it is considered to be b0. Default: 50.

AFQ.tasks.data.dti_params[source]
AFQ.tasks.data.dki_fit(dki_params_file, gtab)[source]

DKI DiffusionKurtosisFit object

AFQ.tasks.data.dki(subses_dict, dwi_affine, brain_mask_file, gtab, data)[source]

full path to a nifti file containing parameters for the DKI fit

AFQ.tasks.data.dki_params[source]
AFQ.tasks.data.csd(subses_dict, dwi_affine, brain_mask_file, gtab, data, tracking_params, csd_response=None, csd_sh_order=None, csd_lambda_=1, csd_tau=0.1)[source]

full path to a nifti file containing parameters for the CSD fit

Parameters
csd_responsetuple or None, optional.

The response function to be used by CSD, as a tuple with two elements. The first is the eigen-values as an (3,) ndarray and the second is the signal value for the response function without diffusion-weighting (i.e. S0). If not provided, auto_response will be used to calculate these values. Default: None

csd_sh_orderint or None, optional.

default: infer the number of parameters from the number of data volumes, but no larger than 8. Default: None

csd_lambda_float, optional.

weight given to the constrained-positivity regularization part of the deconvolution equation. Default: 1

csd_taufloat, optional.

threshold controlling the amplitude below which the corresponding fODF is assumed to be zero. Ideally, tau should be set to zero. However, to improve the stability of the algorithm, tau is set to tau*100 % of the mean fODF amplitude (here, 10% by default) (see [1]). Default: 0.1

References

1

Tournier, J.D., et al. NeuroImage 2007. Robust determination of the fibre orientation distribution in diffusion MRI: Non-negativity constrained super-resolved spherical deconvolution

AFQ.tasks.data.csd_params[source]
AFQ.tasks.data.anisotropic_power_map(subses_dict, csd_params_file)[source]

full path to a nifti file containing the anisotropic power map

AFQ.tasks.data.dti_fa(subses_dict, dwi_affine, dti_params_file, dti_tf)[source]

full path to a nifti file containing the DTI fractional anisotropy

AFQ.tasks.data.dti_cfa(subses_dict, dwi_affine, dti_params_file, dti_tf)[source]

full path to a nifti file containing the DTI color fractional anisotropy

AFQ.tasks.data.dti_pdd(subses_dict, dwi_affine, dti_params_file, dti_tf)[source]

full path to a nifti file containing the DTI principal diffusion direction

AFQ.tasks.data.dti_md(subses_dict, dwi_affine, dti_params_file, dti_tf)[source]

full path to a nifti file containing the DTI mean diffusivity

AFQ.tasks.data.dti_ga(subses_dict, dwi_affine, dti_params_file, dti_tf)[source]

full path to a nifti file containing the DTI geodesic anisotropy

AFQ.tasks.data.dti_rd(subses_dict, dwi_affine, dti_params_file, dti_tf)[source]

full path to a nifti file containing the DTI radial diffusivity

AFQ.tasks.data.dti_ad(subses_dict, dwi_affine, dti_params_file, dti_tf)[source]

full path to a nifti file containing the DTI axial diffusivity

AFQ.tasks.data.dki_fa(subses_dict, dwi_affine, dki_params_file, dki_tf)[source]

full path to a nifti file containing the DKI fractional anisotropy

AFQ.tasks.data.dki_md(subses_dict, dwi_affine, dki_params_file, dki_tf)[source]

full path to a nifti file containing the DKI mean diffusivity

AFQ.tasks.data.dki_awf(subses_dict, dwi_affine, dki_params_file, dki_tf, sphere='repulsion100', gtol=0.01)[source]

full path to a nifti file containing the DKI axonal water fraction

Parameters
sphereSphere class instance, optional

The sphere providing sample directions for the initial search of the maximal value of kurtosis. Default: ‘repulsion100’

gtolfloat, optional

This input is to refine kurtosis maxima under the precision of the directions sampled on the sphere class instance. The gradient of the convergence procedure must be less than gtol before successful termination. If gtol is None, fiber direction is directly taken from the initial sampled directions of the given sphere object. Default: 1e-2

AFQ.tasks.data.dki_mk(subses_dict, dwi_affine, dki_params_file, dki_tf)[source]

full path to a nifti file containing the DKI mean kurtosis file

AFQ.tasks.data.dki_ga(subses_dict, dwi_affine, dki_params_file, dki_tf)[source]

full path to a nifti file containing the DKI geodesic anisotropy

AFQ.tasks.data.dki_rd(subses_dict, dwi_affine, dki_params_file, dki_tf)[source]

full path to a nifti file containing the DKI radial diffusivity

AFQ.tasks.data.dki_ad(subses_dict, dwi_affine, dki_params_file, dki_tf)[source]

full path to a nifti file containing the DKI axial diffusivity

AFQ.tasks.data.dki_rk(subses_dict, dwi_affine, dki_params_file, dki_tf)[source]

full path to a nifti file containing the DKI radial kurtosis

AFQ.tasks.data.dki_ak(subses_dict, dwi_affine, dki_params_file, dki_tf)[source]

full path to a nifti file containing the DKI axial kurtosis file

AFQ.tasks.data.brain_mask(subses_dict, dwi_affine, b0_file, bids_info, brain_mask_definition=None)[source]

full path to a nifti file containing the brain mask

Parameters
brain_mask_definitioninstance from AFQ.definitions.mask, optional

This will be used to create the brain mask, which gets applied before registration to a template. If you want no brain mask to be applied, use FullMask. If None, use B0Mask() Default: None

AFQ.tasks.data.get_bundle_dict(segmentation_params, brain_mask_file, bundle_info=None, reg_template_spec='mni_T1')[source]

Dictionary defining the different bundles to be segmented, and a Nifti1Image containing the template for registration

Parameters
bundle_infolist of strings, dict, or BundleDict, optional

List of bundle names to include in segmentation, or a bundle dictionary (see BundleDict for inspiration), or a BundleDict. If None, will get all appropriate bundles for the chosen segmentation algorithm. Default: None

reg_template_specstr, or Nifti1Image, optional

The target image data for registration. Can either be a Nifti1Image, a path to a Nifti1Image, or if “mni_T2”, “dti_fa_template”, “hcp_atlas”, or “mni_T1”, image data will be loaded automatically. If “hcp_atlas” is used, slr registration will be used and reg_subject should be “subject_sls”. Default: “mni_T1”

AFQ.tasks.data.get_data_plan(kwargs)[source]