Saturday, 20 December 2014

Medical Image Analysis IPython Tutorials

As the Christmas break approaches and the Autumn term will soon be over, I am glad that I've been given the opportunity to feature on this blog the teaching material for the course Medical Image Computing that was newly introduced this year at Imperial College. This course, taught by Prof. Daniel Rueckert and Dr. Ben Glocker, aims to provide MSc students with the necessary skills to carry out research in medical image computing: visualisation, image processing, registration, segmentation and machine learning. The lectures were accompanied by tutorials in the form of IPython notebooks developped by Ozan Oktay, using SimpleITK to process medical images in Python and scikit-learn for Machine Learning. These tutorials are made available on github. They provide an introduction to medical imaging in Python that complements SimpleITK's official notebooks.

There are 4 tutorials:
  1. Basic manipulation of medical image, image filtering, contrast enhancement, and visualisation
  2. Image registration, multi-modal registration, Procrustes analysis
  3. EM segmentation and gaussian mixtures models, atlas prior, Otsu thresholding
  4. Machine learning: classification, regression and PCA.

Image registration is the process of aligning images (rigid registration) and warping them (non-rigid registration) in order to compare or combine images. A typical application is a patient being scanned twice at a few months interval and the two scans are registered in order to assess the evolution of a disease. Another application illustrated below (see tutorial 2) is a patient having an MRI and a CT scan, each modality highlighting different characteristics of a patient's anatomy, and a registration process is required before the doctors can overlay both images.

Image registration:
the CT scan (red) and the MRI scan (green) are registered in order to be combined in a single image.

Image segmentation is the process of assigning a label to each pixel in the image, namely giving a name to distinct parts of the image. This can be done manually, semi-automatically where the user initialises and/or correct an automated process, or fully automatically, such as in the gaussian mixture model illustrated below (see tutorial 3). Image registration is a key step for image segmentation methods that use a database of manually segmented images in order to automatically segment a new image. Such a database is called an atlas. For instance, the atlas can provide a spatial prior to guide the segmentation process as in the second part of tutorial 3.

Image segmentation:
the MR image has been automatically labelled into 4 classes using a gaussian mixture model: white matter (black), grey matter (dark blue), cerebrospinal fluid (light blue) and background (green).

The 4 gaussians that have been fitted to the image data in order to obtain a segmentation are overlayed on the histogram of pixel intensities.

If you would like to know more on medical imaging, a next step could be SimpleITK's official notebooks as well as The ITK Software Guide. If you are looking for images to play with, there is a head MR scan in VTK data and some files that accompany ITK's examples. If you are really motivated, then take a look at some past (or current) MICCAI challenges, download the data and if you are successful at solving the proposed tasks, submit your solutions!


  1. Hello and thanks for the information.
    I tried to check the tutorials but the links don't work.
    Is there a way I can acquire these tutorials?

    Thank you very much,


  2. Hello!
    Does anyone here knows a place where I can find these tutorials? the links are broken :/

  3. ok, I think I found a link with the tutorials that works :)
    Maybe this can save other people some time.

    1. Thanks for your help. I am learning brain tumor segmentation. May I talk about some questions with you? My email:

  4. Thank you for sharing this information.

  5. Thanks for sharing this useful info. Check it on: health

  6. A perfect sleep is achieved when a tired mind is totally disconnected from the sense. A CBD for sleep

  7. It is an insurance that offers the best kind of health care one could ever need. It is an arrangement that surpasses NHS wards which are normally very crowded. how to request an itemized hospital bill

  8. Ready assignments are available just send us message by typing write my assignment for me.

  9. We are providing essay help . You can reach out us now! we are providing this help since the past 10 years.

  10. you are really a good webmaster. The website loading speed is incredible. It seems that you’re doing any unique trick. Moreover, The contents are masterpiece. you’ve done a great job on this topic! First Medicals Consultants

  11. Its fantastic as your other articles : D, thankyou for putting up. boots pcr test for travel

  12. All students need to do to get Homework Help or assignment help is registered on our website, pay a minor charge, and submit the assignment by the deadline. As soon as we receive the project, we send it to one of our expert professional tutors, who will complete it within the deadline. The assignment is only given to the student after it has been thoroughly checked.

  13. All types of custom printed donut boxes styles are available with printing and coating are done in many various ways. Different colors of custom designer donut boxes are what bring out the best in retail boxes.

  14. Magnificent website you have got here. It really worth surfing through, keep up the good work and thanks for sharing such an elucidates reads... check novelty polytechnic ND form closing date

  15. Astronomy Observation Log this assignment is an astronomy observation log. just add weeks oct 21- question dec 2 one log per week except oct 29,30 pretty easy. just find date and research what wouldve been seen in the sy that night and make up an object used/ no more iphone! ( binoculars of an affordable brand can be computers listed/ and telescope of affordable brand) once you see attachment there its pretty …

  16. This is a very interesting blog. After reading this guide for bloggers, I have greatly improved my profile.
    I also wrote a profile with a lot of research to let you know about my latest profile. See it here. Kohi Click Test

  17. Global Assignment Expert has a team of highly qualified pharmacology assignment writers, who put utmost effort to complete any assignment on pharmacology flawlessly and at any level of study, therefore making our pharmacology course assignment help service superior than others.