mri_robust_register - computes symmetric robust registration of two volumes


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


Positional Arguments

No positional arguments

Required Flagged Arguments

- -mov <mov.mgz>

movable input (source)

source volume as mgz file to be registered

- -dst <dst.mgz>

destination input (target)

target volume as mgz file for the registration

- -lta <m2d.lta>

transform output

gives the xform as lta file (mov to dst)

Optional Flagged Arguments

- -warp <outvol.mgz>

warped mov

apply final xform to source, write to outvol.mgz

- -weights <wvol.mgz>

final weights

output weights transformed to target space as wvol.mgz

- -halfmov <hm.mgz>

half-way mov

outputs half-way mov (mapped to halfway space)

- -halfdst <hd.mgz>

half-way dst

outputs half-way dst (mapped to halfway space)

- -halfweights <hw.mgz>

half-way weights

outputs half-way weights (mapped to halfway space)

- -halfmovlta <hm.lta>

half-way mov lta

outputs transform from mov to half-way space

- -halfdstlta <hd.lta>

half-way dst lta

outputs transform from dst to half-way space

- -iscale

intensity scaling

estimate intensity scale factor (default no I-scaling)

- -transonly

only translation

find 3 parameter translation only

- -transform <x.lta>

initial xform

use initial transform lta on source ('id'=identity), default is geometry (RAS2VOX_dst * VOX2RAS_mov)

- -initorient

initial orientation

use moments for orientation initialization (default false), (recommended for stripped brains, but has difficulties with full head images with different cropping)

- -vox2vox

output VOX2VOX

output VOX2VOX lta file (default is RAS2RAS)

- -leastsquares


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

- -maxit <#>

max iterations

iterate max # times on each resolution (default 5)

- -epsit <float>

eps change

stop iterations when change below <float> (default 0.01)

- -nomulti

no multiscale

work on highest resolution

- -sat <float>


set saturation for robust estimator (default 4.685)

- -subsample <#>

subsample image

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

- -maskmov <mask.mgz>

apply mask mov

mask mov/src with mask.mgz

- -maskdst <mask.mgz>

apply mask dst

mask dst/target with mask.mgz

- -uchar

convert to uchar

set volumes type to UCHAR (with intens. scaling)

- -conform

conform volumes

conform volumes to 1mm vox (256^3)

- -satit

for testing

iterate on highest res with different sat, for testing only

- -debug

print debug info

show debug output (default no debug output)


See above


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.


Example 1

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

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

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 view with:

tkmedit -f h1.mgz -aux h2.mgz


None (of course)

See Also




Methods Description



Reporting Bugs

Report bugs to <>