<link rel="stylesheet" href="css/skel.css" /> <link rel="stylesheet" href="css/style.css" /> <link rel="stylesheet" href="css/style-wide.css" /> <link rel="stylesheet" href="css/style-normal.css" />


A Computational Anatomy
Toolbox for SPM


This toolbox is a an extension to SPM12 (Wellcome Department of Cognitive Neurology) to provide computational anatomy. This covers diverse morphometric methods such as voxel-based morphometry (VBM), surface-based morphometry (SBM), deformation-based morphometry (DBM), and region- or label-based morphometry (RBM).

It is developed by Christian Gaser and Robert Dahnke (Jena University Hospital, Departments of Psychiatry and Neurology) and free but copyright software, distributed under the terms of the GNU General Public Licence as published by the Free Software Foundation; either version 2 of the Licence, or (at your option) any later version.

Voxel-based morphometry (VBM)

VBM provides the voxel-wise estimation of the local amount or volume of a specific tissue compartment (Ashburner 2005). VBM is most often applied to investigate the local distribution of grey matter, but can also be used to examine white matter. However, the sensitivity for finding effects in white matter is rather low and there exist more appropriate methods (e.g. DTI) for that purpose.

The concept of VBM incorporates different preprocessing steps: (1) spatial registration to a reference brain (template), (2) tissue classification (segmentation) into grey and white matter and CSF, and (3) bias correction of intensity non-uniformities. Finally, segmentations are modulated by scaling with the amount of volume changes due to spatial registration, so that the total amount of grey matter in the modulated image remains the same as it would be in the original image.

Deformation-based morphometry (DBM)

DBM is based on the application of non-linear registration procedures to spatially normalise one brain to another one. The simplest case of spatial registration is to correct the orientation and size of the brains. In addition to these global changes, a non-linear registration is necessary to minimise the remaining regional differences by means of local deformations. If this local adaptation is possible, the deformations now reveal information about the type and localization of the structural differences between the brains and can undergo subsequent analysis.

Differences between both images are minimized and are now coded in the deformations. Finally, a map of local volume changes can be quantified by a mathematical property of these deformations - the Jacobian determinant. This parameter is well known from continuum mechanics and is usually used for the analysis of volume changes in flowing liquids or gases. The Jacobian determinant allows a direct estimation of the percentage change in volume in each voxel and can be statistically analyzed (Gaser et al. 2001). This approach is also known as tensor-based morphometry because the Jacobian determinant represents such a tensor.

Surface-based morphometry (SBM)

CAT12 additionally includes the estimation of the cortical thickness and central surface of the left and right hemispheres based on the projection-based thickness (PBT) method (Dahnke et al. 2012).

Furthermore, the surface pipeline uses topology correction (Yotter et al. 2011a) and spherical mapping (Yotter et al. 2011b).

Surface-based morphometry has several advantages over using volumetric data alone. For instance, brain surface meshes have been shown to increase the accuracy of brain registration compared with Talairach registration (Desai et al. 2005, Brodoehl et al. 2005). Brain surface meshes also permit new forms of analyses, such as gyrification indices that measure surface complexity in 3D (Yotter et al. 2011c), local gyrification (Luders et al. 2006) or cortical thickness. Furthermore, inflation or spherical mapping of the cortical surface mesh raises the buried sulci to the surface so that mapped functional activity in these regions can be easily visualized.

Cortical thickness and central surface estimation

We use a fully automated method that allows for measurement of cortical thickness and reconstructions of the central surface in one step. It uses a tissue segmentation to estimate the white matter (WM) distance, then projects the local maxima (which is equal to the cortical thickness) to other gray matter voxels by using a neighbor relationship described by the WM distance. This projection-based thickness (PBT) allows the handling of partial volume information, sulcal blurring, and sulcal asymmetries without explicit sulcus reconstruction (Dahnke et al. 2012).

Topological correction

In order to repair topological defects we use a novel method that relies on spherical harmonics (Yotter et al. 2011a). First, the original MRI intensity values are used as a basis to select either a ’fill’ or ’cut’ operation for each topological defect. We modify the spherical map of the uncorrected brain surface mesh, such that certain triangles are favored while searching for the bounding triangle during reparameterization. Then, a low-pass filtered alternative reconstruction based on spherical harmonics is patched into the reconstructed surface in areas that previously contained defects.

Spherical mapping

A spherical map of a cortical surface is usually necessary to reparameterize the surface mesh into a common coordinate system to allow inter-subject analysis. We use a fast algorithm to reduce area distortion resulting in an improved reparameterization of the cortical surface mesh (Yotter et al. 2011b).

Spherical registration

We have adapted the volume-based diffeomorphic Dartel algorithm to the surface (Ashburner 2007) to work with spherical maps (Yotter et al. 2011d). We apply a multi-grid approach that uses reparameterized values of sulcal depth and shape index defined on the sphere to estimate a flow field that allows deforming a spherical grid.

Region- or label-based morphometry (RBM)

CAT12 also allows estimation of regional tissue volumes (and optionally cortical thickness values) for different volume and surface-based atlas maps. The idea of this approach is that regions of interest (ROIs) can be defined once in an atlas brain and can be then mapped to the individual brain by using a high-dimensional spatial registration. This approach is also known as label- or region-based morphometry.

CAT12 provides different volume- as well as surface-based atlases with several predefined ROIs.


CAT12 is an extension of the segmentation in SPM12, but uses a completely different segmentation approach.


CAT12 uses an internal interpolation to provide more reliable results even with low resolution images and anisotropic spatial resolutions. Although interpolation cannot add more details to the images, some of the functions used benefit from the higher number of voxels and the usual strip artefacts in modulated images are greatly reduced.


We also use two noise reduction methods to make data processing, and the tissue segmentation in particular, more robust against noise. The first method is a spatial-adaptive Non-Local Means (SANLM) denoising filter and removes noise while maintaining edges (Manjon et al. 2010) and is implemented as pre-processing step. The second method is a classical Markov Random Field (MRF) approach, which includes spatial information from adjacent voxels in the segmentation estimation (Rajapakse et al. 1997) and is part of the AMAP segmentation.

Affine Preprocessing (APP)

To improve the initial SPM segmentation, an initial affine registration is applied to a bias-corrected image and the intensity range is limited to avoid problems with special protocols. If the preprocessing fails a more aggressive version is available that applies a rough bias correction and removes non-brain parts the brain before the initial affine registration.

Local Adaptive Segmentation (LAS)

GM intensity can vary for different regions such as the motor cortex, the basal ganglia, or the occipital lobe. These changes have an anatomical background (e.g. iron content, myelenization), but are dependend on the MR-protocol and often lead to GM-underestimations at higher intensities and CSF-overestimations at lower intensities. Therefore, a local intensity transformation of all tissue classes is used to reduce these effects in the image before the final AMAP segmentation.

Amap Segmentation

The segmentation approach is based on an Adaptive Maximum A Posterior (AMAP) technique without the need for a priori information on the tissue probabilities. This means that the Tissue Probability Maps (TPM) are not constantly used in the sense of the classical Unified Segmentation approach (Ashburner et al. 2005), but only for spatial normalization, initial skull-stripping, and as initial segmentation estimate. The subsequent AMAP estimation is adaptive in the sense that local variations of the parameters (i.e., means and variance) are modelled as slowly varying spatial functions (Rajapakse et al. 1997). This accounts not only for intensity inhomogeneities, but also for other local intensity variations.

Partial Volume Segmentation

In addition, the segmentation approach uses a Partial Volume Estimation (PVE) with a simplified mixed model of a maximum of two tissue types (Tohka et al. 2004). We begin with an initial segmentation into three pure classes: gray matter (GM), white matter (WM), and cerebrospinal fluid (CSF) based on the AMAP estimation described above. The initial segmentation is followed by a PVE consisting of two additional mixed classes: GM-WM and GM-CSF. This results in an estimate of the amount (or fraction) of each pure tissue type that is present in each voxel (since single voxels - given their size - probably contain more than one tissue type) and thus allows for more precise segmentation.


CAT12 contains a revised graph-cut based skull-stripping.

Spatial Normalization

Another important extension of the SPM12 segmentation is the integration of the Dartel (Ashburner 2007) and the Geodesic Shooting (Ashburner 2011) normalization into the toolbox by already existing DARTEL and Geodesic Shooting templates in MNI space. These templates were derived from 555 healthy control subjects of the IXI-database. Therefore, the creation of sample-specific DARTEL and Geodesic Shooting templates is no longer necessary for most studies.

Quality control (QC)

Preprocessing of magnetic resonance (MR) images strongly depends on the quality of the input data. Especially multi-center studies and data-sharing projects need to take into account varying image properties due to different scanners, sequences and protocols.

CAT introduces a novel retrospective QC framework for empirical quantification of quality differences in different scans or studies. Retrospective QC allows the evaluation of essential image parameters such as noise, inhomogeneities, and image resolution. All these quality measures will be scaled to a rating scale which easily allows to compare measures across different scanners and sequences. Furthermore, quality measures are summarised to a single quality rating.


The CAT toolbox is available to the scientific community under the terms of the GNU General Public License.


CAT12 is designed to work with SPM12 and Matlab versions 7.4 (R2007a) or newer. No additional toolboxes are required.


Download Standalone Version (no need for Matlab licene)

The advantage of the standalone version is that no Matlab license is needed. Only the (free) Matlab Runtime R2017b (v93) has to be downloaded. However, there are some limitations (e.g. no parallelization and no interactive help in the GUI version) and the standalone version is mainly intended to run without GUI on Unix systems. Please check the ENIGMA CAT12 site fore more information and examples to call CAT12 from shell scripts.

The MATLAB Compiler Runtime (MCR) enables you to run applications compiled within MATLAB using MATLAB Compiler. MCR does not require a MATLAB license and can be used to run the MATLAB compiled program on computers which do not have MATLAB installed.

Please contact me if you need other versions.