Processing
The images were then processed in order to analyze and compare the scans. The following steps were completed on the Fulton Supercomputer.
The preprocessed images were used to generate a template. They were first run simply with affine transformations and then rerun using diffeomorphic transformations to build a more complete template.
<path/to/buildtemplateparallel.sh> -d 3 -m 1x0x0 -o pt1 -c 5
<path/to/buildtemplateparallel.sh> -d c -z <input/file/pt1template.nii.gz -o pt2 -c
The -d option indicates dimensionality. The -m option describes iterations. The -c option indicates that the program controls parallel computation.
A couple different steps were completed with one script. In this script (shown below) the brain was extracted, or a brain mask was created, in order to remove excess data outside the image of the brain. Then, the script performs tissue segmentation using an ANTs pipeline to correct for intensity imperfections and overlap. The ANTs cortical thickness pipeline is then run using a general template in order to create the necessary output files(listed below) to run ANTs in the next step.
<path/to/antsCorticalThickness.sh> \
-d 3 -a <template.nii.gz> -e <T-template.nii.gz> \
-t <T-template_BrainCerebellum.nii.gz> \
-m <T-template_BrainCerebellumProbabilityMask.nii.gz> \
-f <T-template_BrainCerebellumExtractionMask.nii.gz> \
-p <priors%d.nii.gz> -q 1 -o <antsCT>
# COPY MASK
cd <BrainExtractionMask.nii.gz> <template_BrainCerebellumMask.nii.gz>
# EXTRACT BRAIN IMAGE
<ImageMath> 3 <template_BrainCerebellum.nii.gz \
m <template_BrainCerebellumMask.nii.gz <template.nii.gz
# CONVERT MASK ROI TO PROBABILITY MASK
<SmoothImage> 3 <template_BrainCerebellumMask.nii.gz> \
1 <template_BrainCerebellumProbabilityMask.nii.gz>
# DILATE MASK IMAGE TO GENERATE EXTRACTION MASK
<c3d> <template_BrainCerebellumMask.nii.gz> -dilate 1 28x28x28vox \
-o <template_BrainCerebellumExtractionMask.nii.gz>
# DILATE MASK IMAGE TO GENERATE REGISTRATION MASK
<c3d> <template_BrainCerebellumMask.nii.gz> -dilate 1 18x18x18vox \
-o <template_BrainCerebellumRegistrationMask.nii.gz
# COPY TISSUE SEGMENTATION
cp <BrainSegmentation.nii.gz <template_6labels.nii.gz>
# COPY TISSUE PRIORS
mkdir <priors>
cp <BrainSegmentationPosteriors1.nii.gz> <priors1.nii.gz>
cp <BrainSegmentationPosteriors2.nii.gz <priors2.nii.gz>
cp <BrainSegmentationPosteriors3.nii.gz> <priors3.nii.gz>
cp <BrainSegmentationPosteriors4.nii.gz> <priors4.nii.gz>
cp <BrainSegmentationPosteriors5.nii.gz> <priors5.nii.gz>
cp <BrainSegmentationPosteriors6.nii.gz> <priors6.nii.gz>