Motion Correction

From VISTA LAB WIKI

Jump to: navigation, search


There are currently two motion compensation options built into mrVista, both accessible from the menu Analysis | Motion Compensation. One uses the code developed by Nestares and Heeger, while the other uses SPM code.

[edit] Rigid-Body (Nestares Code) Motion Compensation

These use the same algorithm as mrAlign, and performs a rigid-body alignment from each frame to a reference frame. There are 3 types of correction:

  1. Inplane alignment: correct motions within each slice. This is older and does not appear to be used.
  2. Between Scans alignment: compute the mean T2* functional images over time (mean map) for each scan, align the mean maps. You are prompted to specify a reference scan, to which the other scans will be aligned. Saves data in a separate data type, named 'MotionComp_RefScan[#]'.
  3. Within-Scans alignment: for each scan, the frames are aligned to a base frame within that scan. You can also specify an amount of temporal smoothing. This does not smooth the data ; rather, for an amount of smoothing k, the alignment for frame N to the base frame will be computed by aligning the average of N and the neighboring (k-1)/2 frames. E.g., if k=3 frames, frame N will be averaged with the adjacent frames before and after to align. If k=1, no smoothing will occur. The function motionComp.m calls for (and eventually forces) an odd number so that you always have a predictably centered window.

Rory has tried this on high-resolution (1mm, 1.5mm) data, and the combination of the within-scans and between-scans alignment seems to work very well. (He hasn't been using the temporal smoothing so far.)

[edit] Motion Compensation based on Mutual Information (MI)

A more recent tool has been developed which calls the SPM coregistration tools. (This requires that you have SPM2 installed.) To use this option, select 'Analysis' | 'Motion Compensation' | 'Motion Compensation (MI)'. This will take you to an interface (command line: motionCompSetArgs) in which you can select:

  • The data type and scans to be corrected
  • The reference to which to align each temporal volume for each scan (can be the mean volume for a scan, or the Inplane anatomies)
  • The coregistration technique: Mutual-Information-based, Rigid Body as well as MSE, non-linear algorithms
  • The target data type in which to save the motion-corrected scans
  • options for running a GLM, computing the MSE of the new data type, to assess how well things worked.

One advantage of this code over the Nestares code is that the mutual information is intended to be more robust at aligning images with different scan properties -- e.g., T1 anatomies and T2* functionals. So, if you suspect the subject may have moved between your inplane and functional scans, you can align each functional frame onto the inplane anatomies. Rory has tried this and found it works pretty well.

WARNING: There are still some unfixed bugs at the end stages of this code -- it'll pop out errors, though it will have successfully saved the tSeries (trying to fix this, but tough to track down). Also, the MSE correction seems to work poorly on high-resolution data. Here's an example of a severe skew imposed to try to fix a small (~1 voxel) amount of rotational motion:

MSE mistake example.jpg

The blue-green channel shows the first frame of the preceeding scan, the red channel shows what the MSE correction did to try to match that frame.

In addition to the tools within mrVista, Alex Wade has developed some tools to convert data to ANALYZE format, run the FSL tools (FLIRT) for motion correction, then convert it back.

[edit] Evaluating the amount of motion

When you choose within-scans motion compensation, mrVista creates an 'Images' directory, in which it saves a .fig and .jpg of motion during each scan (rotational, translational, and total motion).

With between-scans motion compensation, a text file is generated and saved in the subject's directory, named "Between Scan Motion.txt". This file summarizes the net translational and rotational motion between the mean images between each corrected scan and the reference scan, in voxels.

Personal tools