CMTK used to have a landmarks based registration tool based on VTK code called align_landmarks. In combination with this allowed initialisation of CMTK affine/warp registrations by an initial affine calculated from pairs of landmarks in each sample brain and a corresponding set in a reference brain.

Specifying the Landmarks

You should save landmarks in IGS format from Fiji's Landmarks … Name Landmarks and Register plugin inside the images folder (ie next to the sample images) and also in the refbrain folder next to the reference brain. There is a slight complication because the plugin understands two formats (referred to as .points and .landmarks format). You can only reload the landmarks in the plugin from .points format, but CMTK can only understand .landmarks format. It is therefore necessary to save both (.points so you can fix points in the future, .landmarks for the actual registration).

A sensible set of landmarks has been defined for IS2 and lives here:


To choose landmarks in your sample brain:

  1. Open your sample image
  2. Start plugin
  3. Load reference landmarks mentioned above
  4. Hit Reset All
    1. since the starting landmarks are in IS2 space and don't mean anything for your template brain
  5. Go through landmarks one by one choosing position with point (crosshair) tool from ImageJ toolbar
    1. Don't forget that left means fly's left!
    2. You don't need to use all points (and e.g. protocerebral bridge is probably more prone to disturbance)
    3. 4 points are enough for a 12 dof (but I normally use a few more)
  6. As you go along hit Save to save your work
    1. Save the files as XXX.points right next to the sample image (in the images folder)
  7. When you are finished choose Export to IGS and save as XXX.landmarks right next to the sample image

Using the Landmarks

Reference landmarks

You need to have a set of reference landmarks next to the template brain used by your registration. A typical layout would be:

  • refbrain
    • refbrain/IS2.nrrd
    • refbrain/IS2.landmarks (used by CMTK registration)
    • refbrain/IS2.points (used by Fiji)

or you can just use


as your template since that folder contains the necessary landmarks files.

Running the registration

The align_landmarks tool got removed at some point but lives on in IGSRegistrationTools, latest version here:


In order to use this, you have to run on a registration folder

  1. adding the -L switch
  2. making sure that align_landmarks is in your path
    1. or at the location pointed to by the '-b' switch given to munger

Help for those two switches:

  -L find initial affine transform using landmarks
  -b [path] bin directory

If you have IGSRegistrationTools installed in its normal location and CMTK installed from the NITRC binary installer, you can do something like

sudo ln -s /Applications/IGSRegistrationTools/ /opt/local/bin

to make sure that align_landmarks is in your path. You will need to edit your ~/.profile to ensure that the PATH is set appropriately if you did not do this when you installed CMTK. Note that it is essential that align_landmarks and the other CMTK binaries are in the same folder to ensure that munger behaves.

Log In