Differences between revisions 7 and 8
Deletions are marked like this. Additions are marked like this.
Line 85: Line 85:
= Outputs =
See above

Line 93: Line 89:
mri_robust_register --mov vol1.mgz --dst vol2.mgz --lta v1to2.lta --warp v1to2.mgz --weights v1to2-weights.mgz --iscale mri_robust_register --mov vol1.mgz --dst vol2.mgz --lta v1to2.lta --warp v1to2.mgz --weights v1to2-weights.mgz --iscale --satit
Line 103: Line 99:
mri_robust_register --mov vol1.mgz --dst vol2.mgz --lta v1to2.lta --halfmov h1.mgz --halfdst h2.mgz --halfmovlta h1.lta --halfdstlta h2.lta --iscale mri_robust_register --mov vol1.mgz --dst vol2.mgz --lta v1to2.lta --halfmov h1.mgz --halfdst h2.mgz --halfmovlta h1.lta --halfdstlta h2.lta --iscale --satit



mri_robust_register - computes symmetric robust registration of two volumes (within modality)


mri_robust_register --mov <mov.mgz> --dst <dst.mgz> --lta <m2d.lta> [options]

Important Note

This webpage describes the version of mri_robust_register that is distributed with FreeSurfer 5.0. We encourage the use of that version or possible newer versions, that can be downloaded here.


This program symmetrically aligns two volumes. It uses a method based on robust statistics to detect outliers and removes them from the registration. This leads to highly accurate registrations even with local changes in the image (e.g. jaw movement). The main purpose is to find the rigid registration (translation, rotation) of longitudinal data, but the method can be used to rigidly align different images. An additional optional intensity scale parameter can be used to adjust for global intensity differences. The extension to affine registration is being tested.

If the registration fails: The registration can fail because of several reasons, most likeley due to large intensity differences or non-linear differences in the image. You can try:

  • Switch on intensity scaling ( - -iscale).

  • When specifying a manual saturation (- -sat) too many voxels might be considered outlier early in the process. You can check this by outputing the weights (--weights ow.mgz) and by looking at them in:
       tkmedit -f dst.mgz -aux mov.mgz -overlay ow.mgz 
    If most of the brain is labeled outlier, try to set the saturation to a higher value (eg. --sat 12) or use --satit to automatically determine a good sat value.
  • When using automatic saturation estimation ( - -satit) you can try specifying the sensitivity manually or twiddle around with - -wlimit (which is around 0.16 by default). A lower wlimit should reduce the number of outlier voxels.


Positional Arguments

No positional arguments

Required Flagged Arguments

- - mov <mov.mgz>

input movable volume to be aligned to target

- - dst <dst.mgz>

input target volume

- - lta <reg.lta>

output registration (transform from mov to dst)

One of the following is required for sensitivity:

- - sat <real>

set outlier sensitivity manually (e.g. - - sat 4.685 ). Higher values mean less sensitivity.

- - satit

auto-detect good sensitivity (recommended for head or full brain scans)

Optional Flagged Arguments

- - mapmov <aligned.mgz>

output image: movable mapped and resampled at destination

- - weights <weights.mgz>

output weights (outliers) in destination space

- - iscale

estimate intensity scale factor (default no). Highly recommended for unnormalized images!

- - iscaleout <fname.txt>

output txt file for iscale value (will activate --iscale). Default: no iscale output

- - iscalein <fname.txt>

initial input txt file for iscale value (probably you want to also activate --iscale to estimate final value?)

- - transonly

find 3 parameter translation only

- - ixform lta

use initial transform lta on source ('id'=identity), default is align center (using moments)

- - initorient

use moments for orientation init (default false). Recommended for stripped brains, but not with full head images with different cropping

- - noinit

skip transform init, default: translation of centers

- - vox2vox

output VOX2VOX lta file (default is RAS2RAS)

- - leastsquares

use least squares instead of robust M-estimator (for testing only)

- - maxit <#>

iterate max # times on each resolution (default 5)

- - highit <#>

iterate max # times on highest resolution (default 5)

- - epsit <real>

stop iterations when all tp transform updates fall below <real> (default 0.01)

- - nomulti

work on highest resolution only (no multiscale)

- - wlimit <real>

sets maximal outlier limit for --satit (default 0.16), reduce to decrease outlier sensitivity

- - subsample <real>

subsample if dim > # on all axes (default no subs.)

- - floattype

convert images to float internally (default: keep input type)

- - doubleprec

double precision (instead of float) internally (large memory usage!!!)

- - maskmov <mask.mgz>

mask mov/src with mask.mgz

- - maskdst <mask.mgz>

mask dst/target with mask.mgz

- - halfmov <hm.mgz>

outputs half-way mov (mapped to halfway space)

- - halfdst <hd.mgz>

outputs half-way dst (mapped to halfway space)

- - halfweights hw.mgz

outputs half-way weights (mapped to halfway space)

- - halfmovlta hm.lta

outputs transform from mov to half-way space

- - halfdstlta hd.lta

outputs transform from dst to half-way space

- - debug

show debug output (default no debug output)

- - verbose

0 quiet, 1 normal (default), 2 detail


Example 1

mri_robust_register --mov vol1.mgz --dst vol2.mgz --lta v1to2.lta --warp v1to2.mgz --weights v1to2-weights.mgz --iscale --satit

Computes the rigid registration (6 degrees of freedom) of vol1.mgz to vol2.mgz using robust statistics and with an additional 7th global intensity scaling parameter (recommended e.g. for orig.mgz). The output is the transform (v1to2.lta) and v1to2.mgz (the aligned vol1.mgz to the target image). Additionally the weights of the robust registation (outlier detection) are saved. Everything can be viewed in tkmedit with:

tkmedit -f vol2.mgz -aux v1to2.mgz -overlay v1to2-weights.mgz

Example 2

mri_robust_register --mov vol1.mgz --dst vol2.mgz --lta v1to2.lta --halfmov h1.mgz --halfdst h2.mgz --halfmovlta h1.lta --halfdstlta h2.lta --iscale --satit

Computes the rigid robust registration with intensity scaling of vol1 to vol2 (the registration will be in v1to2.lta). Additionally outputs the half-way volumes h1 and h2 (with corresponding transforms h1.lta and h2.lta). As both volumes are mapped to the half-way space, they will both be resampled. This can be used to construct an unbiased mean volume (e.g. with mri_average) or to compute change maps. The output can be viewed with:

tkmedit -f h1.mgz -aux h2.mgz


None (of course)

See Also





Reporting Bugs

Report bugs to <freesurfer@nmr.mgh.harvard.edu>



mri_robust_register (last edited 2014-01-31 22:36:30 by MartinReuter)