QA Pipeline For DTI
https://masi.vuse.vanderbilt.edu/index.php/QA_DTI
page created: August 03, 2012 last update: August 14, 2012
Contents[hide] |
Overview
The QA pipeline for DTI is designed to automatically process and statistically evaluate DTI datasets. Processing is primarily done through incorporation of the external software programs: FSL for image preparation and CAMINO RESTORE for diffusion tensor estimation. Statistical evaluation includes multiple methods found in the DTI literature. The pipeline outputs (1) A four-page graphical PDF report summarizing data quality evaluation, and (2) a folder with digitally stored outputs from the pipeline.
Using the Pipeline
Data Structure Requirements
The pipeline automatically processes DTI data. Below specifies the data structures compatible with the pipeline.The QA graphical PDF Report offers several self-checking features to validate that data was interpreted correctly by the pipeline (see Graphical PDF Report).
Image Structures
- The program accepts data in the form of par/rec (or PAR/REC) and nifti formats.
- Although parsing of the par/rec file is used to properly orient image data and gradient table, the authors did not have access to all structure types and only one slice orientation has been validated (slice orientation =3).
- Nifti images that require reslicing to load into matlab are NOT compatible with the pipeline. In my experiene these are rare and an error will be produced when running the pipeline informing the user of this problem.
- Nifti gradient tables need to be oriented such that CAMINO interprets the image orientation/gradient orientation properly. This may require reorienting your gradient table before entry into the pipeline. The last page of the QA PDF report will check that the gradient table was oriented properly.
- Note: the pipeline will shift ALL data irregardless of starting orientation into RAS(x-axis: left to right, y-axis: back to front, z-axis: foot to head)
Protocols
- Data must contain exactly one bo volume.
- The Bo is assumed to be a single volume and not the average over multiple Bo’s. If your Bo is an average, the pipeline will complete, however the SIMEX bias estimates will be less valid. The open-source code allows for easy adjustment of this assumption (see FAQ).
- The b-values can be constant or variable across the DWI. However, variable b-values have not been tested.
- The pipeline should appropriately remove any images that are NOT DWI or Bo (e.g. an averaged volume should be removed correctly by the pipeline).
- If the entire brain volume is not in the FOV, the program will complete, but there may be deleterious results on statistical outputs.
Installing
- You can request the latest QA pipeline (as of August 14, 2012 the latest version is version 1.1). The tar file contains the main program, sub-programs called by the main program, and a readme text. The program runs in Matlab, is ACCRE compatible, and is open-source.
- You can also access version 1.0 as a release on NITRC under MASIMaltab.
Graphical PDF Report
The PDF Report consists of four pages. Here we walkthrough each page. These pages are from version 1.1, on multi-modal subject #23.
Page-1: The Inputs
- A – Filename
- B – Protocol information. More information is parsed if par/rec data is used than if nii data is used.
- ‘C – Patient movement as measured through FSL registration. All DWI are registered to bo, and the affine matrix for each DWI is used to measure patient translation and rotation.
- D – Outliers as labelled by RESTORE. For each gradient, the percent of voxel outliers is measured. The percent is determined on masked data. A standard mask is used for CAMINO DTI calclation, but for this plot, a more restrictive mask is used to protect against ‘counting’ voxels just outside the brain as ‘bad’ when in fact they are just noise that was not properly filterd by brain extraction.
- E – Goodness of fit: Pixel-chi-squared histogram. (see references). This histrogram is across all spatial locations. The insert shows at magnification a region of ‘definitively bad-quality’ (~0.2). The magnification required to see this region of the histogram is printed in the insert.
- F – Goodness of fit: Slice -pixel-chi-squared values. This parameter is a modification of the pixel-chi-squared (manuscript under review). For each slice in each DWI, the ‘pixel’-chi-squared was calculated as a summary measure of the goodness of fit and noise level of that slice. Values near and above 0.2 are definitvely poor-quality. Each column in plot ‘F’ represents an entire volume, each row represents a slice across all volumes. Note, this analysis is performed on the normalized DWI (DWI/bo). Poor bo quality will adversely impact all data. For this reason, the bo is visualized on page-3.
- G – Trimmed mean value of slice-pixel chi-squared value across volumes.
- H – Trimmed mean value of slice-pixel chi-squared values across axial slices.
- I – Best and worst DWI axial slices as estimated by the slice-pixel-chi-squared. For each 1/5th region of brain (moving axially from foot to head), the best and worst DWI are pictured. Shown is NOT DWI/bo, but DWI. Also, these images will not directly correspond to your data as these are the registered image. For example, striping in Figure ‘I’, may correspond to a blank slice sandwiched by two good slices.
Page-2: The Outputs
- A – Model of segmented regions from multi-atlas segmentation
- B – Boxplot distribution of measured parameters at each segmentation region. Blue box plot = this data set. Black box plot = distribution across all 21 subjects from the multi-modal study. Outliers are NOT shown for visual clarity. Therefore the full range of values likely exceeds the boxplot sizes.
- C – Measured MD value from RESTORE
- D – Measured FA value from RESTORE
- E – Bootstrap estimated standard deviation of FA. Only a subsampling of voxels is used for bootstrap, with a minimum of 50 per region (unless the region is assigned less than 50 voxels)
- F – SIMEX estimated bias of FA. Only a subsampling of voxels is used for SIMEX, a minimum of 50 per gions (unless the region is assigned less than 50 voxels)
Page-3: Visualization and Power Curves
- A – Mid-axial slice showing MD and FA values
- B – Mid-axial slice showing standard deviation and bias of FA. Because these values are estimated only for a subset of voxels, every voxel in each region is represented by the median value across that region. The percent of sub-sampling is indicated below the figures.
- C – Estimated power curves for different sample sizes. The curves are NOT including the bias estimate. This assumes a two-sided T-test and only looks at the cerebral white and gray matter.
- D – Estimated power curves for different sample sizes. The curves include the SIMEX bias estimate. This assumes a two-sided T-test and only looks at the cerebral white and gray matter.
- E – Full FOV view of the Bo (bo). Note, multi-atlas segmentation performance was found to be sensitive to data whose FOV was not large enough to encompass the full head.
- F – References. Numbers in brackets: [#], throughout the report refer to these reference numbers.
Page-4: Validation of FA/Vector Directions
- A – Mid-axial slice of vector color map. R = left-right, G = front-back, B = head-toe. The actual vector direction is shown by a white vector across each voxel. Three enlargements of the same slice are shown to increase visualization of the white-vectors.
- B – Mid-coronal slice of vector color map. R = left-right, G = front-back, B = head-toe. The actual vector direction is shown by a white vector across each voxel. Three enlargements of the same slice are shown to increase visualization of the white-vectors.
- C – Version number and author comments. Please read.
Stored Pipeline Outputs
One PDF and three sub-folders: (i)extra, (ii)multi-atlas, and (iii) QA_maps, are created in the user-specified pipeline output folder. For each folder, an itemized description of its inventory is given below.
extra
outputs are listed in the order they are produced by the pipeline
- RegIm.nii- the registered data
- registration_movement.mat – patient movement (translation, rotation, affine transformation matrix)
- multi_atlas_labels.nii- the segmentations for Bo produced by multi-atlas segmentation
- sigmaEst.mat – the estimated imaging noise. This scalar value is used as input for CAMINO-RESTORE and SIMEX
- scheme.txt – the input b-value and gradient table text file for CAMINO
- OutlierMask.nii – voxels labelled ‘outliers’ by CAMINO-RESTORE
- ModelData.mat – backfit DWI/Bo from fitted diffusion tensor
- voxel_wise_chi_q.mat- contains a) the squared error at each voxel (between observed data and ModelData) normalized by the total squared signal across DWI/Bo at that spatial location (see Papadakis reference), (b) the exact data used to create the chi-squared plot on page 1 of the PDF.
- NewMask.mat- the voxels subsampled for SIMEX and Bootstrap
- Boxplots*.mat- the boxplot data contained on the second page of the PDF. Each *.mat file contains the statistical data as a one-dimensional vector. A second grouping vector (grp) is used to indicate the anatomical grouping of elements in the statistical data vector. Together the two vectors can be used to recreate the boxplots from page-2 of the PDF.
- powerData.mat- all the data for the power curves. Although the Boxplots*.mat provide all necessary data, this is a smaller pooling of the needed data for power calculations. The matfile contains: Broi is the bias, FAbootM is the standard deviation, maskROI provides the segmentation regions, NewMask provides masking for data that was subsampled for SIMEX and Bootstrap.
multi-atlas
- (nls-fusion) bo_ref_est.nii – same as multi_atlas_lables.nii already stored in the sub-folder ‘extra’
- (reg-atlases) Bo##_to_bo_ref.nii- each of the 21 atlases registered to the target (your Bo volume)
- (reg-labels) Bo##_to_bo_ref_seg.nii – the labels from the 21 atlases registered to the target (your Bo volume)
- (reg-warps) Bo##_to_bo_ref_warp.nii – the 21 deformation fields from registering the 21 atlases to the target (your Bo volume)
- (temp-out)-empty folder. future update will remove this stored folder.
QA_maps
- dt.Bdouble – the fit diffusion tensor output from CAMINO-RESTORE. This file is in double and can be used as input to CAMINO for further DTI data processing (e.g if you want all the eigenvectors)
- fa.nii – the FA map
- md.nii – the MD (or ADC) map
- V1.nii – the principle direction vector
References
Multi-Modal Data
The freely available multi-modal dataset is used in the pipeline (1) as the source of bo segmentation atlases, and (2) as a quality canonical dataset for easy comparison across datasets on page-2 of the QA PDF report.
External Software Packages
Literature Citations
- Papadakis, N., et. al., “A measure of curve fitting error for noise filtering diffusion tensor MRI data”, J. Magn. Reson. 164: 1-9 (2003)
- A., Landman, B.A., “Non-local Staple: An intensity driven multi-atlas rater model”, MICCAI (2012)
- B., et. al., “Using the wild bootstrap to quantify uncertainty in diffusion tensor imaging parameters”, Human Brain Mapping 29: 346-362 (2008)
- Lauzon C., et. al., “Assessment of bias in experimentally measured diffusion tensor imaging parameters using SIMEX”, Magn. Reson. Med (2012)
- [Lauzon C., et. al., “Correcting power and p-value calculations for bias in diffusion tensor imaging”, Magn. Reson. Imag. (submitted)]
- [LauzonC. et. al., “A Multi-component Quality Analysis Pipeline for Diffusion Tensor Imaging”, Neuroimag. (submitted)]
- [Asman, A., et . al. “Robust Inter-Modality Multi-Atlas Segmentation for PACS-based DTI Quality Control”, SPIE (submitted)]
Re-distributed Open Source Software
The QA pipeline calls on many functions created by the larger community.
- Travis, Kupsche (2010). histnorm. MATLAB Central File Exchange. Retrieved ? 2011 (retrieved version from April 20, 2010)
- Tordoff,Ben (2010). Rotate X-axis Tick Labels. MATLAB Central File Exchange. Retrieved ? 2012 (retrieved version from Feb 2012)
- Ridgway, Guess (2001). Rice/Rician Distribution. MATLAB Central File Exchange. Retrieved November 2010.
- Shen, Jimmy(2005). Tools for NIfTI and ANALYZE image. MATLAB Central File Exchange. Retrieved May 2012.
- Quist, Richard (2008). ps2pdf. MATLAB Central File Exchange. Retrieved January 2012.
FAQ
Are these warnings/errors normal?
Many warnings/errors can be produced by the pipeline even for successfully running datasets. In particular, CAMINO produces many errors/warnings for certain voxels. These are likely voxels belonging to periphery regions of the brain that do not contain adequate data. Example terminal output with typical warnings for successful data can be found in the NITRC QA_DTI demo available /here.