Introduction to image registration

Kaushalya S
3 min readNov 8, 2021

Hi friends. I am going to give you a small introduction to image registration. What is image registration? Image registration is the process of transforming different sets of data into one coordinate system. Technically, that means finding corresponding structures and determining the optimal transformation to correct the misalignment of the images and apply the transformation. Most commonly, one image is moved/rotated/scaled to match it in the coordinate system of the other image.

Types of image registration

1. Translation

2. Rigid body (translation +rotation)

3. Scaled rotation (translation + rotation + scaling)

4. Affine (translation + rotation + scaling + shearing)

5. Bilinear (non-linear transformation, does not preserve straight lines)

Many python libraries are used for image registration. Those are,

1. Image_registration library

2. Pystackreg

3. Itk

4. SimpleITK

5. Open3D

6. OpenCV

7. Skimage

8. Itk-Elastix

9. SimpleElastix

10. Dipy

11. PyElastix

12. Icreg

The below diagram shows the basic components of a typical registration framework. Those are two input images, a transform, a metric, an interpolator, and an optimizer. Different methods used under each component are listed in the below table.

Some code snippets for image registration are given below. The code is implemented in Python. Initially, the required packages are loaded. Here skimage package is used for registration.

The original and shifted images are loaded. The second image was shifted -17.45 in the y-direction and 18.75 in the x-direction.

The shifted values in the x and y direction are found using register translation. The calculated results are almost equal to the original values.

The original image, offset image and registered images are plotted below.

We can clearly see that the original image and shifted image are correctly oriented. Image registration has worked properly. Similarly, 3D image registration can be performed using ITK and SimpleITK libraries in Python.

Hope you enjoyed the article!

References

  1. https://github.com/bnsreenu/python_for_microscopists
  2. https://git.mpi-cbg.de/rhaase/lecture_applied_bioimage_analysis_2020
  3. https://www.youtube.com/playlist?list=PLZsOBAyNTZwbIjGnolFydAN33gyyGP7lT

--

--

Kaushalya S

I am a Biomedical Engineering final year undergraduate at University of Moratuwa.