1
MEDICAL IMAGE COMPUTING (CAP 5937)- SPRING 2017
LECTURE 1: Introduction
Dr. Ulas Bagci
HEC 221, Center for Research in Computer Vision
(CRCV), University of Central Florida (UCF),
Orlando, FL 32814.
bagci@ucf.edu or bagci@crcv.ucf.edu
2
• This is a special
topics course,
offered for the
second time in UCF.
Lorem Ipsum Dolor Sit Amet
CAP5937: Medical Image Computing
3
• This is a special
topics course,
offered for the
second time in UCF.
• Lectures:
Mon/Wed, 10.30am-
11.45am
Lorem Ipsum Dolor Sit Amet
CAP5937: Medical Image Computing
4
• This is a special
topics course,
offered for the
second time in UCF.
• Lectures:
Mon/Wed, 10.30am-
11.45am
• Office hours:
Lorem Ipsum Dolor Sit Amet
Mon/Wed, 1pm-
2.30pm
CAP5937: Medical Image Computing
5
• This is a special topics
course, offered for the
second time in UCF.
• Lectures: Mon/Wed,
10.30am-11.45am
• Office hours:
Mon/Wed, 1pm-
2.30pm
• No textbook is
Lorem Ipsum Dolor Sit Amet required, materials will
be provided.
• Avg. grade was A- last
CAP5937: Medical Image Computing
spring.
6
Image
Processing Computer
Vision
Medical
Image
Imaging Computing
Sciences
(Radiology,
Biomedical) Machine
Learning
7
Motivation
• Imaging sciences is experiencing a tremendous
growth in the U.S. The NYT recently ranked
biomedical jobs as the number one fastest growing
career field in the nation and listed bio-medical
imaging as the primary reason for the growth.
8
Motivation
• Imaging sciences is experiencing a tremendous
growth in the U.S. The NYT recently ranked
biomedical jobs as the number one fastest growing
career field in the nation and listed bio-medical
imaging as the primary reason for the growth.
• Biomedical imaging and its analysis are fundamental
to (1) understanding, (2) visualizing, and (3)
quantifying information.
9
Motivation
• Imaging sciences is experiencing a tremendous
growth in the U.S. The NYT recently ranked
biomedical jobs as the number one fastest growing
career field in the nation and listed bio-medical
imaging as the primary reason for the growth.
• Biomedical imaging and its analysis are fundamental
to (1) understanding, (2) visualizing, and (3)
quantifying information.
• This course will mostly focus on analysis of
biomedical images, and imaging part will be briefly
taught!
10
Syllabus
• Basics of Radiological Image Modalities and their
clinical use (MRI, PET, CT, fMRI, DTI, …)
• Introduction to Medical Image Computing and Toolkits
• Image Filtering, Enhancement, Noise Reduction, and
Signal Processing
• Medical Image Registration
• Medical Image Segmentation
• Medical Image Visualization
• Machine Learning in Medical Imaging
• Shape Modeling/Analysis of Medical Images
11
Syllabus
• Grading:
– In-class Quiz (20%, approximately 20 quizzes, at the end of
each lecture)
– 3 Programming Assignments (each 10%, total 30%)
• ITK/VTK packages should be used
• ITK and VTK provide necessary codes/libraries for medical image
processing and analysis.
• C/C++ or Python can be used and call ITK/VTK functions
• In-class collaboration is encouraged, but individual submission is
required.
– 1 Individual Project (50%)
• Will be selected from a list of projects or you can come withh your
own project
• A short presentation (15%), coding/method (25%), results (10%)
12
Optional Reading List
• Image Processing, Analysis, and Machine Vision. M. Sonka, V.
Hlavac, R. Boyle. Nelson Engineering, 2014.
• Level-set Methods, by J. A. Sethian, Cambridge University Press.
• Visual Computing for Medicine: Theory, Algorithms, and
Applications. B. Preim, C. Botha. Morgan Kaufmann, 2013.
• Medical Image Registration. J. Hajnal, D. Hill, D. Hawkes (eds).
CRC Press, 2001.
• Pattern Recognition and Machine Learning. C. Bishop. Springer,
2007.
• Insight into Images: Principles and Practice for Segmentation,
Registration and Image Analysis, Terry S. Yoo (Editor) (FREE)
• Algorithms for Image Processing and Computer Vision, J. R. Parker
• Medical Imaging Signals and Systems, by Jerry Prince & Jonathan
Links, Publisher: Prentice Hall
13
Conferences and Journals to Follow
• The top-tier conferences (double blind, acceptance rates are below
25%, high quality technical articles):
– MICCAI (medical image computing & computer assisted intervention)
– IPMI (Information Processing in Medical Imaging)
– Other conferences: IEEE ISBI, EMBC and SPIE Med Imaging
– Clinical Conferences: RSNA (>65.000 attendances), ISMRM, SNM
• The top-tier technical journals:
– IEEE TMI, TBME, PAMI, and TIP
– Medical Image Analysis, CMIG, and NeuroImage
• The top-tier clinical journals relevant to MIC:
– Radiology, Journal of Nuclear Medicine, AJR, Nature Methods, Nature
Medicine, PlosOne, …
14
Required skill set
• Basic programming experience (any language is fine)
• Linear Algebra/Matrix Algebra
• Differential Equations
• Basic Statistics
15
Biomedical Images
• (Bio)medical images are different from other
pictures
16
Biomedical Images
• (Bio)medical images are different from other
pictures
– They depict distributions of various physical features
measured from the human body (or animal body).
17
Biomedical Images
• (Bio)medical images are different from other
pictures
– They depict distributions of various physical features
measured from the human body (or animal body).
• Analysis of biomedical images is guided by very
specific expectations
18
Biomedical Images
• (Bio)medical images are different from other pictures
– They depict distributions of various physical features
measured from the human body (or animal).
• Analysis of biomedical images is guided by very
specific expectations
– Automatic detection of tumors, characterizing their types,
– Measurement of normal/abnormal structures,
– Visualization of anatomy, surgery guidance, therapy
planning,
– Exploring relationship between clinical, genomic, and
imaging based markers
19
Free Software to use in this course
• ImageJ (and/or FIJI)
• ITK-Snap
• SimpleITK
• MITK
• FreeSurfer
• SLICER
• OsiriX
• An extensive list of software: www.idoimaging.com and
blue: will be frequently used in this course
20
Medical Image Formats
• Dicom
• Nifti
• Analyze (img/hdr)
• Raw data
• …
21
DICOM (the mostly used)
• Digital Imaging and Communications in Medicine standard
• Since its first publication in 1993, DICOM has revolutionized
the practice of radiology, allowing the replacement of X-ray
film with a fully digital workflow.
• It is the international standard for medical images and related
information (ISO 12052)
• defines the formats for medical images that can be exchanged
with the data and quality necessary for clinical use.
• It is implemented in almost every radiology, cardiology
imaging, and radiotherapy device (X-ray, CT, MRI, ultrasound,
etc.), and increasingly in devices in other medical domains
such as ophthalmology and dentistry.
22
3D Slicer Software
• A software platform for the analysis (including
registration and interactive segmentation) and
visualization (including volume rendering) of
medical images and for research in image guided
therapy.
• A free, open source software available on multiple
operating systems: Linux, MacOSX and Windows
• Extensible, with powerful plug-in capabilities for
adding algorithms and applications.
23
Brief History of 3D Slicer
• 1997: Slicer started
as a research
project between the
Surgical Planning
Lab (Harvard) and
the CSAIL (MIT)
•80 authorized developers • Open Source +
contributing to the source Open Data + Open
code of Slicer Community
24
Slicer Volume Module
25
Slicer Welcome Module
26
Slicer Welcome Module
27
Loading A DICOM Volume
28
Loading A DICOM Volume
29
Loading A DICOM Volume
30
Loading A DICOM Volume
31
Interactive exploration
32
33
Interactive exploration
34
3D Slicer Sources
• http://slicer.org/
• http://www.slicer.org/slicerWiki/index.php/Docum
entation/UserTraining
• https://vimeo.com/37671358
35
Libraries to be Used
• ITK and VTK
– National Library of
Medicine Insight
Segmentation and
Registration Toolkit
(ITK).
– ITK is an open-source,
cross-platform system that
provides developers with
an extensive suite of
software tools for image
analysis.
– C/C++, Python, Matlab,
…
36
Goals of ITK
– Supporting the Visible Human Project.
– Establishing a foundation for future research.
– Creating a repository of fundamental algorithms.
– Developing a platform for advanced product
development.
– Support commercial application of the technology.
– Create conventions for future work.
– Grow a self-sustaining community of software users and
developers.
37
History of ITK
• ITK was initially conceived by the NLM(National
Library of Medicine).
• An initiative for open source software tools to
analyze human dataset
• Developed by group of both commercial and
academic organizations(kitware, GE research,
Mathsoft, Upenn, UT, UNC
• Goal: provide a foundation to enable research in
image processing and biomedical image computing,
Providing catalog of algorithms
38
What is ITK?
• Image Processing
• Segmentation
• Registration
• No Graphical User Interface (GUI)
• No Visualization
39
Coordinate System for Reading Files
• Multiple coordinate frames
– Physical
– Patient
– Index
• ITK uses LPS (Left Posterior Superior)
for DICOM
How to Integrate ITK in application
Credit: itk.org
Installation/Requirements
C++ Compiler
gcc 2.95 – 3.3
Visual C++ 6.0 CMake
Visual C++ 7.0
Visual C++ 7.1 www.cmake.org
Intel 7.1
Intel 8.0
IRIX CC
Borland 5.5
Mac – gcc
Credit: itk.org
Installation process
• Google ITK , go to the download page, download
the zip file (or directly install using github or console
functions in mac/linux)
• Google cmake, go to the download page, get the
binaries and install the binaries.
Configuring ITK – MS-Windows
l Run CMake
l Select the SOURCE directory
l Select the BINARY directory
l Select your Compiler
Configuring ITK
Configuring ITK
l Disable BUILD_EXAMPLES
l Disable BUILD_SHARED_LIBS
l Disable BUILD_TESTING
l Click “Configure” to configure
l Click “OK” to generate project files
Building ITK
l Open ITK.sln in the Binary Directory
l Select ALL_BUILD project
l Build it
…It will take about 15 minutes …
Verify the Built
Libraries will be found in
ITK_BINARY / bin / { Debug, Release }
• The following libraries should be there:
– ITKCommon ITKIO
– ITKBasicFilters ITKStatistics
– ITKAlgorithms ITKMetaIO
itkpng
– ITKNumerics
itkzlib
– ITKFEM
Use ITK from an external Project
Copy
“HelloWorld.cxx”
“CMakeLists.txt”
from the Run • Select Source Dir
Examples/Installation CMake • Select Binary Dir
Directory
into another
directory
Use ITK from an external Project
• accept the default in
CMAKE_BACKBARD_COMPATIBILITY
• leave empty EXECUTABLE_OUTPUT_PATH
• leave empty LIBRARY_OUTPUT_PATH
• Set ITK_DIR to the binary directory
where ITK was built
Build Sample Project
• Open HelloWorld.sln generated by CMake
• Select ALL_BUILD project
• Build it
Run the example
• Locate the file HelloWorld.exe
• Run it…
• It should produce the message:
ITK Hello World !
Starting your own project
• Create a clean new directory
• Write a CMakeLists.txt file
• Write a simple .cxx file
• Configure with CMake
• Build
• Run
Writing CMakeLists.txt
PROJECT( myProject )
FIND_PACKAGE ( ITK )
IF ( ITK_FOUND )
INCLUDE( ${ITK_USE_FILE} )
ENDIF( ITK_FOUND )
ADD_EXECUTABLE( myProject myProject.cxx )
TARGET_LINK_LIBRARIES ( myProject ITKCommon ITKIO)
Writing myProject.cxx
#include "itkImage.h"
#include "itkImageFileReader.h"
#include "itkGradientMagnitudeImageFilter.h"
int main( int argc, char **argv ) {
typedef itk::Image<unsigned short,2> ImageType;
typedef itk::ImageFileReader<ImageType> ReaderType;
typedef itk::GradientMagnitudeImageFilter<
ImageType,ImageType> FilterType;
ReaderType::Pointer reader = ReaderType::New();
FilterType::Pointer filter = FilterType::New();
reader->SetFileName( argv[1] );
filter->SetInput( reader->GetOutput() );
filter->Update();
return 0;
}
Run CMake
How to find what you need?
http://www.itk.org/ItkSoftwareGuide.pdf
http://www.itk.org/Doxygen/html/index.html
• Follow the link Alphabetical List
• Follow the link Groups
• Post to the insight-users mailing list
VTK
• The Visualization Toolkit (VTK) is an open-
source, freely available software system for 3D
computer graphics, image processing, and
visualization.
• Consists of a C++ class library and several
interpreted interface layers including Tcl/Tk, Java,
and Python
VTK
• Download VTK from vtk.org
• Configure VTK
– Run CMake
– Select the SOURCE directory
– Select the BINARY directory
– Select your Compiler (same used for ITK)
Configuring VTK
Disable
• BUILD_EXAMPLES
• BUILD_SHARED
Leave unchanged
• CMAKE_BACKWARD_COMPATIBILITY
• VTK_DATA_ROOT
Enable
• VTK_USE_HYBRID
• VTK_USE_RENDERING
• VTK_USE_PARALLEL
• VTK_USE_PATENTED
Disable
• VTK_WRAP_JAVA
• VTK_WRAP_PYTHON
• VTK_WRAP_TCL
Enable (Advanced)
• VTK_USE_ANSI_STDLIB
Build VTK
• Open VTK.dswin the Binary Directory
• Select ALL_BUILD project
• Build it
…It may take about 90 minutes …
Verify the Build
Libraries will be found in
VTK_BINARY / bin/ { Debug, Release}
Verify the Build
The following libraries
should be there:
• Vtkexpat
• vtkCommon
• Vtkfreetype
• vtkFiltering
• Vtkftgl
• vtkImaging
• Vtkjpeg
• vtkGraphics
• Vtkpng
• vtkHybrid
• Vtktiff
• vtkParallel
• vtkzlib
• vtkPatented
Starting your own project
with ITK + VTK
• Create a clean new directory
• Write a CmakeLists.txtfile
• Write a simple .cxxfile
• Configure with CMake
• Build
• Run
Writing CMakeLists.txt
PROJECT(myProject)
FIND_PACKAGE ( ITK)
IF ( ITK_FOUND)
INCLUDE( ${USE_ITK_FILE} )
ENDIF( ITK_FOUND)
FIND_PACKAGE ( VTK)
IF ( VTK_FOUND)
INCLUDE( ${USE_VTK_FILE} )
ENDIF( VTK_FOUND)
(continue...)
Writing CMakeLists.txt
INCLUDE_DIRECTORIES(
${myProject_SOURCE_DIR}
)
ADD_EXECUTABLE( myProject myProject.cxx)
TARGET_LINK_LIBRARIES ( myProject
ITKBasicFiltersITKCommonITKIO
vtkRenderingvtkGraphicsvtkHybrid
vtkImagingvtkIOvtkFilteringvtkCommon
)
Writing myProject.cxx
Writing myProject.cxx
#include "itkImage.h"
#include "itkImageFileReader.h"
#include "itkImageToVTKImageFilter.h"
#include "vtkImageViewer.h"
#include "vtkRenderWindowInteractor.h"
intmain( intargc, char **argv) {
typedef itk::Image<unsigned short,2> ImageType;
typedef itk::ImageFileReader<ImageType> ReaderType;
typedef itk::ImageToVTKImageFilter<ImageType> connectorType;
ReaderType::Pointer reader= ReaderType::New();
ConnectorType::Pointer connector= ConnectorType::New();
Writing myProject.cxx
reader->SetFileName( argv[1]);
connector->SetInput( reader->GetOutput() );
vtkImageViewer* viewer= vtkImageViewer::New();
vtkRenderWindowInteractor* renderWindowInteractor=
vtkRenderWindowInteractor::New();
viewer->SetupInteractor( renderWindowInteractor);
viewer->SetInput( connector->GetOutput() );
viewer->Render();
viewer->SetColorWindow( 255);
viewer->SetColorLevel( 128);
renderWindowInteractor->Start();
return 0;
}
SimpleITK
• New Wrapper for the insight segmentation &
registration toolkit
• Goal :to help rapid prototyping and expand the user
based of ITK by exposing the algorithms to new users
• Simplify the algorithms so they don’t depend on types
of images.
• Binary built in distributions
• Supports 2D & 3D image , multi component images
• Easy importing & exporting
• data through Numpy
77
• QUESTIONS?
78
Quiz!
(1 pt)