This is a common source of confusion. Read the section named Data Format if you don't know the difference.
DTI-TK provides a number of tools for converting DTI volumes computed using several major DTI tools to the NIfTI tensor format that is used by DTI-TK. The detailed instructions for these tools are given in the Interoperability page. After conversion, remember to check that the DTI volumes are converted correctly by using the tensor glyph viewing tool described here.
This is the foremost important step to verify! A detailed instruction on how to check and, if necessary, to correct the diffusivity unit is available here. If you choose to use a public available DTI template for registration, make sure that you verify its diffusivity unit as well!
If your protocol for reconstructing DTI volumes from DWI images does not include the step of removing non brain tissues, you need to do this now, before proceeding to registration or spatial normalization. To do this, our recommended protocol is to use the excellent Brain Extraction Tool, aka BET, available as part of the FSL suite. Once you have computed the brain tissue mask and are satisfied with its quality, you can apply it to the corresponding DTI volume with the following command:
TVtool -in tensor.nii.gz -out mtensor.nii.gz -mask b0_mask.nii.gz
where b0_mask.nii.gz is the brain tissue mask.
Comment:
Outliers often don't have any effect on image registration. However, when the outliers are substantially outside the normal range, they will. A good indicator that the outliers are worthy of concerns is when their existence distorts the mean significantly. For analyzing DTI volumes, a good summary scalar that reflects the size of a tensor is the tensor norm. A practical strategy of identifying outliers is by computing the tensor norm image and examining its intensity statistics. This can be accomplished with the following two commands:
TVtool -in tensor.nii.gz -norm
which outputs the tensor norm image as tensor_norm.nii.gz, and
SVtool -in tensor_norm.nii.gz -stats
which prints out the intensity statistics.
Several example outputs are:
The first example shows there are some small outliers in the image. There are some substantially larger outliers in the second image but it isn't significant enough to affect the mean by a lot. The third case is an example of the outliers that should be removed prior to registration. The outliers are so large, the mean value is significantly inflated.
The outlier voxels can be easily identified with binary thresholding and removed via masking.
Note: It is safe to set the outlier threshold at 100 (The estimate is in DTI-TK diffusivity unit).
BinaryThresholdImageFilter tensor_norm.nii.gz non_outliers.nii.gz 0 100 1 0 TVtool -in tensor.nii.gz -mask non_outliers.nii.gz -out mtensor.nii.gz
Thanks to Stephen Meredith from University College Dublin for the suggestion.
Diffusion tensors, by definition, are symmetric and positive-definite matrices, or SPD. However, in practice, due to noises in the DWI images, the diffusion tensors estimated within a DTI volume are not always SPD. The SPD condition is very important however to ensure DTI volumes behave properly after various image processing steps. DTI-TK provides a simple tool that identifies the voxels that are not SPD and enforces this condition on such voxels. The tool TVtool can be used as follows:
TVtool -in tensor.nii.gz -spd -out spd.nii.gz
which will report the total number of voxels that are not SPD. These voxels will be flagged in a binary image called nonSPD.nii.gz. These voxels are often around the boundary of the brain, usually an result of imperfect removal of non-brain tissues or incomplete correction of motion or eddy-current induced geometrical distortions. If you find a large number of such voxels occurring within brain tissues, this is a good indication that the data is very noisy and you should perhaps investigate and understand why this is the case and if it is a wide-spread problem.
By a voxel space, I mean the following three specifications of a 3D digital volume: the origin (the grid point that maps to the physical origin), the voxel dimensions (the number of grid points along each spatial direction), and the voxel spacings (the physical distance between adjacent grid points along each spatial direction). Given a NIfTI or Analyzer volume, these specfications can be determined with VolumeInfo.
Having a comon voxel space is ideal for bootstrapping a reasonably good initial template estimate.
TVAdjustVoxelspace -in tensor.nii.gz -origin 0 0 0