(IP'22) Lecture 1 - Intro + Acquisition - G
(IP'22) Lecture 1 - Intro + Acquisition - G
Digital Image
Processing
10/3/2022 3
Team
• Teachers
– Dr. Maryam Al-Berry
maryam_nabil@cis.asu.edu.eg
• TAs
– Mohammed Ali
– Mohammed Rashad
– Mohammed Mostafa
– Mostafa Elkabeer
– Nadeen Halawa
10/3/2022 4
ILOs
• A working knowledge of the most commonly used
methods and procedures for image processing.
• Understanding of the mathematics/theory behind the
procedures as well as the ability to write software to
implement the mathematics.
• Make use of data structures, linear algebra, and signal
processing in the implementations.
• Given an image and a goal for its processing the student
should be able to select and implement an appropriate
procedure to achieve that goal.
• The ability to explain results in writing is essential for a
successful
10/3/2022 engineer→ reports/papers. 5
Introduction and
Image Acquisition
Today’s Contents
Analog to Digital
Human Visual Perception
Structure of the Human Eye
Brightness adaptation and discrimination
Human Visual Perception – (cont.)
Image Formation in the Eye
10/3/2022 10
Human Visual Perception – (cont.)
10/3/2022 11
Digital Image Acquisition
• Digital Camera
10/3/2022 12
Digital Image Acquisition
• Digital Camera
• Color filter arrays - Bayer
10/3/2022 13
Digital Image Acquisition – (cont.)
The Electromagnetic Spectrum
• Light is a part of the EM spectrum that can
be sensed by the human eye.
Digital Image Acquisition – (cont.)
Digital Image Acquisition – (cont.)
• Incoming energy lands on a sensor material
responsive to that type of energy and this
generates a voltage.
• Collections of sensors are arranged to
capture images. Line of Image
Sensors
sample
sample sample
Digital Image Acquisition – (cont.)
Sampling and Quantization Q. Which?
10/3/2022 19
Digital Image Acquisition – (cont.)
Sampling and Quantization Example
• Quality depends on the
number of samples and
discrete intensity levels used
in sampling and quantization.
Digital Image Acquisition – (cont.)
• A digital image is a representation of a two-
dimensional picture as a finite set of digital
values, called picture elements or pixels.
y 1 pixel
(0,0)
x
10/3/2022 f(x,y) 21
Digital Image Acquisition – (cont.)
• Color image
10/3/2022 22
Digital Image Acquisition – (cont.)
Image Representation
• The image now is composed of M rows
and N columns of pixels each storing a
value f(x,y).
• In practice, the grey scale is shifted to
[0, L-1].
• x and y are called spatial coordinates.
Digital Image Acquisition – (cont.)
Image Representation
• The number L of discrete intensity
levels is typically a power of 2.
L = 2k
• k = bits required to store the image.
• k-bit image, e.g. 8-bit image.
Digital Image Acquisition – (cont.)
Image Representation
• That representation can take several forms.
10/3/2022 26
Digital Image Acquisition – (cont.)
Image Representation - Gray-scale (intensity) Image
• 2D array of integer numbers where each pixel
has a value in the range [0-1], or most
commonly [0-255]
for an 8-bit image.
10/3/2022 27
Digital Image Acquisition – (cont.)
Image Representation - RGB (truecolor) Image
• 3D array that defines red, green, and blue
color components for each individual pixel.
• Each of the three values is in the range [0-1] or [0-255] for an 8-bit image.
Black = (0, 0, 0)
White = (1, 1, 1 )
or = (255, 255, 255)
10/3/2022 28
Digital Image Acquisition – (cont.)
Image Representation - Indexed Image
• 2D array of integer numbers (indexes)
representing a row in a color map.
• Each row of map specifies the red, green, and
blue components of a single color.
10/3/2022 29
Digital Image Acquisition – (cont.)
• An 8-bit image has a its grey scale [0,
255], however, not all images use the
whole range.
• The actual range used by an image is
called the dynamic range.
• Dynamic range affects contrast and the
contrast ratio.
Digital Image Acquisition – (cont.)
Contrast Examples
Digital Image Acquisition – (cont.)
Most Popular Image File Formats
Compressed Vs. raw
10/3/2022 32
Effects of Sampling & Quantization – (cont.)
Image Resolution
• A measure of quality of the image.
• How close the lines can be to each other
and still be visibly resolved.
• Depends strongly on the number of
• Samples → Pixel
• Device → Spatial Resolution
• Gray levels → Intensity Resolution
Effects of Sampling & Quantization – (cont.)
1- Pixel Resolution
• Refers to the pixel count of the image.
• Conventions:
The number of pixel columns (width) times the number of
pixel rows (height), e.g. as 640 by 480.
64 32
128
256
512
1024
Effects of Sampling & Quantization – (cont.)
1024×1024
Effects of Sampling & Quantization – (cont.)
512×512
Effects of Sampling & Quantization – (cont.)
256×256
Effects of Sampling & Quantization – (cont.)
128×128
Effects of Sampling & Quantization – (cont.)
64×64
Effects of Sampling & Quantization – (cont.)
32×32
Effects of Sampling & Quantization – (cont.)
10/3/2022 42
Effects of Sampling & Quantization – (cont.)
3- Intensity Resolution
• Refers to the number of intensity levels
used to represent the image.
– More intensity levels = finer discernable detail.
– In terms of number of bits used to store each
intensity level.
Effects of Sampling & Quantization – (cont.)
3- Intensity Resolution
256 grey levels (8 bits per pixel) 128 grey levels (7 bpp) 64 grey levels (6 bpp) 32 grey levels (5 bpp)
16 grey levels (4 bpp) 8 grey levels (3 bpp) 4 grey levels (2 bpp) 2 grey levels (1 bpp)
Effects of Sampling & Quantization – (cont.)
• Why?
–Improvement of pictorial information for
human interpretation (low-level).
–Processing of scene data for autonomous
machine perception (computer vision).
10/3/2022 48
Digital Image Processing
10/3/2022 49
Example Applications
- Image Enhancement/restoration: One of the
most common uses of DIP techniques: improve
quality, remove noise, etc.
10/3/2022 50
Example Applications – (cont.)
- Image Enhancement/restoration: One of the
most common uses of DIP techniques: improve
quality, remove noise, etc.
10/3/2022 51
Example Applications – (cont.)
- Medical Visualization:
Computerized Axial Tomography (CAT) scans.
Magnetic Resonance Imaging (MRI).
10/3/2022 52
Example Applications – (cont.)
- Industrial Inspection:
detecting anomalies.
10/3/2022 53
Example Applications – (cont.)
- Special Effects: make images more visually
appealing, or make composites.
10/3/2022 54
Example Applications – (cont.)
- Image Forensics: authentication and forgery
detection.
10/3/2022 55
Example Applications – (cont.)
- Image Forensics: authentication and forgery
detection.
10/3/2022 56
Example Applications – (cont.)
- Law Enforcement: automated detection,
tracking, and identification.
10/3/2022 57
Example Applications – (cont.)
- HCI: Try to make human computer interfaces
more natural
– Face recognition
– Gesture recognition
– Computer Graphics
10/3/2022 58
Most Common Topics in DIP
1. Image formation
2. Sampling and quantization
3. Point processing and equalization
4. Re-sampling and geometric transformations
5. Convolution and spatial filtering
7. Fourier transform and frequency filtering
8. Restoration and noise reduction
9. Morphology
10. Segmentation
10/3/2022 59
Fundamental Steps of DIP
Image Morphological
Restoration Processing
Image
Segmentation
Enhancement
Image Object
Acquisition Recognition
Representation
Problem Domain
& Description
Colour Image Image
Processing Compression
10/3/2022 60
Fundamental Steps of DIP – (cont.)
Image Morphological
Restoration Processing
Image
Segmentation
Enhancement
Image Object
Acquisition Recognition
Representation
Problem Domain
& Description
Colour Image Image
Processing Compression
10/3/2022 61
Fundamental Steps of DIP – (cont.)
Image Morphological
Restoration Processing
Image
Segmentation
Enhancement
Image Object
Acquisition Recognition
Representation
Problem Domain
& Description
Colour Image Image
Processing Compression
10/3/2022 62
Fundamental Steps of DIP – (cont.)
Image Morphological
Restoration Processing
Image
Segmentation
Enhancement
Image Object
Acquisition Recognition
Representation
Problem Domain
& Description
Colour Image Image
Processing Compression
10/3/2022 63
Fundamental Steps of DIP – (cont.)
Image Morphological
Restoration Processing
Image
Segmentation
Enhancement
Image Object
Acquisition Recognition
Representation
Problem Domain
& Description
Colour Image Image
Processing Compression
10/3/2022 64
Fundamental Steps of DIP – (cont.)
Image Morphological
Restoration Processing
Image
Segmentation
Enhancement
Image Object
Acquisition Recognition
Representation
Problem Domain
& Description
Colour Image Image
Processing Compression
10/3/2022 65
Fundamental Steps of DIP – (cont.)
Image Morphological
Restoration Processing
Image
Segmentation
Enhancement
Image Object
Acquisition Recognition
Representation
Problem Domain
& Description
Colour Image Image
Processing Compression
10/3/2022 66
Course Outline
Wavelet and
Multi- Compression
resolution
Output is generally images
Knowledge base
Restoration Segmentation
Representation
Enhancement and
Description
Object
Acquisition Recognition
Problem Domain
Winner
• Diagnose the image(s).
• Develop a solution/process.
• Describe the why.
• Know the how.
• Write about it. Assessment (CH)
Assessment (Old Bylaw) Final Test 50 %
Final Test 65 % Midterm 15 %
Midterm 10 % Practical 20%
Practical + Tasks 25%) Quizzes 5%
10/3/2022 68
Yearwork 10%
Textbook
• Digital Image Processing, 3rd edition, Rafael C.
Gonzalez and Richard E. Woods, Prentice Hall,
2008.
http://www.imageprocessingplace.com
10/3/2022 69
Next Lecture
Image Enhancement in the Spatial Domain
Assignment
- Textbook Chapter 1
Chapter 2: 1, 2, 3, 4, 4.1, 4.2, 4.3
- Check associated problems:
Chapter 2 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 22, 23
10/3/2022 71