Software - MRI Image Bias Correction

Template-Based Inhomogeneity Correction of High-Resolution MRI Images
There are two models in the literature for correcting intensity nonuniformities (bias) in MRI images. The first model involves resetting the image to a hypothetical ideal. For example, N3 changes intensities to sharpen the histogram tissue peaks. The second model uses a template image with known voxel intensities and compares the subject image to it. The idea here is that deviations in the ratios of corresponding voxel intensities identify nonuniformities which can be removed from the subject image.

Our nonuniformity correction is a template based method. We use a non-linear spline warp to align the subject volume with a template which is assumed to be bias free. We assume the alignment is adequate to allow comparison of like tissue types between the subject and template voxels. Voxel ratios at discrete locations are obtained by comparing the voxel means in corresponding local patches of template and image. The ratios at these locations are interpolated using thin-plate splines to create a smoothly varying model of the voxel intensity ratios at every point. With no bias in the template, the ratio field is de facto a model of the bias field for the subject.

Thus, our correction method is aimed at smooth, slowly varying MRI field nonuniformities. It is not intended to correct abrupt changes in the MRI field that may result from coil placements.

Also, this algorithm is not recommended for whole head image correction. It is most successful when the skull has been stripped.

The ratio field is used to multiplicatively correct the subject voxel intensities. The following synthetic images illustrate the procedure:

Fig. 1 Subject with bias field

Fig. 2 Template image

On the left is a subject image with evident intensity nonuniformity. On the right is a template used for comparison (both of these images are derived from the MNI template; one is a slightly warped version of the other, used here for illustrative purposes).

Fig. 3 Computed inverse bias ratio field

This image shows the resulting model of the inverse ratio field, which when multiplied against the subject image reduces the bias.

Next we show the results of correcting a real image.

Fig. 4 Uncorrected MRI image showing bias

Fig. 5 Same slice after bias correction

Figures 4-5 show the successful removal of the bright and dark highlights in the MRI bias field on the left. Also, bias correction typically improves the quality of the image histogram. The following figures show histograms for this MRI image before and after correction.

Image histogram prior to correction

Histogram after correction

The main improvements are the appearance of more distinct tissue intensity peaks for gray and white matter.

Summary of Bias Correction Algorithm
The algorithm has these capabilities and limitations:

The algorithm executes the following steps:
  1. Align template image to target using linear (affine) registration followed by high-dimensional spline warp. This improves the matching of like tissue types between images of dissimilar topography.
  2. Sample the ratios of intensities at like tissue types between target and aligned template. These ratios estimate the MRI field non uniformities for the target image when a low-bias template is used.
  3. Smoothly interpolate the ratios at discrete points using thin-plate splines to create a multiplicative correction field for the target image.
  4. Correct the target image by multiplying times the inverse model bias field.

Our bias correction algorithm runs to completion in a little less than an hour for most images, running on a Pentium P4 chip at 3.6 GHz. This is in the range of reported times (sometimes over one hour) for N3 correction. In addition, we have found that with some images (such as the example above in Fig. 4), N3 will not perform a correction without prior smoothing of the image.

Parity matching
There are some practical issues involved, however. The main one is that the template and subject image must be in the same orientation prior to the warping that allows bias removal. To address this question, we have implemented a way to keep track of the image parity - the relation of the subject's right to left, nose to occiput, and foot to head coordinate directions with the standard coordinate axes of the image space. Once this information is known, then the images can be internally reoriented to matching parities prior to alignment. Our program does this.

To do so, we need to supply the parity information for the subject image. This is accomplished with our parity tool, illustrated next. The figure shows the parity tool interface with a sample image pictured. The "wizard" button launches a sequence of separate windows (X axis is shown) that walks you through setting the information for each of the subject's directions relative to the image space axes.

In the sample window, the X-axis direction is being set: if it is parallel to the subject's right-left direction, then click which one. Otherwise, click NO and a second window will query whether the subject's front-back direction is parallel to this axis, and so forth. Continuing in this way, you can set the complete parity information for the subject.

Once this is done, the rest of the bias correction proceeds automatically.

Parity tool interface

Parity Tool wizard window for setting X-axis information

Template Images
Our bias correction package includes all software needed to automatically run the template-based corrections, including two template images -- for old and young subjects. These templates have parity information in their header files. The actual images are derived as follows:

Both templates are 1-byte images in analyze format. The Young Template is bias free (being a synthetic image), while the Old Template has minimal bias since it is created as an average high-dimensional deformation of the 29 elderly subjects, all warped onto the same space.

The following figures show sample slices from the templates.

Old Template

Young Template

Running the Bias Correction

The algorithm accepts analyze or interfile file formats. A typical call for a subject image "T" in analyze format (using in this example the young template) would be as follows:

IHCorr T.hdr YoungTemplate.hdr
If the parity information for the target image is missing, then the algorithm calls up the parity tool window so that this can be set. When done, be sure to click the Set Parity and Exit buttons of the parity tool. When the parity information for the target image has been set, then the rest of the bias correction follows automatically.

Outputs from this run would include two new images:

T_corr.hdr .img (or .h01 .i01 if interfile)
SubjectBiasRatioCorr
storing respectively the corrected image and the bias field used to make the correction.

Up (Software)

9551 unique visits since June 1, 2006