0% found this document useful (0 votes)
32 views

Lecture01 Image Processing

The document is the first lecture on digital image processing. It introduces key concepts including that digital images are composed of pixels with intensity values, and can be represented as matrices. The lecture covers topics like image enhancement, restoration, understanding, and compression. It also discusses the electromagnetic spectrum used in imaging, scales of imaging from large to small, and how digital images are formed and represented as bitplanes and matrices. Finally, it introduces concepts related to the human visual system.

Uploaded by

Hatem Dheer
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
32 views

Lecture01 Image Processing

The document is the first lecture on digital image processing. It introduces key concepts including that digital images are composed of pixels with intensity values, and can be represented as matrices. The lecture covers topics like image enhancement, restoration, understanding, and compression. It also discusses the electromagnetic spectrum used in imaging, scales of imaging from large to small, and how digital images are formed and represented as bitplanes and matrices. Finally, it introduces concepts related to the human visual system.

Uploaded by

Hatem Dheer
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 51

Lecture 1

Image Processing

Dr.eng. Ahmed H. Abo absa

E-mail: [email protected]

1
1
Lecture 1

What is Digital Image Processing

 Processing digital images by means of a


digital computer.
 A digital image can be modeled as a two
dimensional function , f ( x, y ) ,where x and y
are spatial coordinates, and the value of
the function is the intensity or gray level of
the image at that point.

2
Lecture 1

What is Digital Image Processing

 A digital image is composed of a finite


number of elements, each of which has a
particular location and value. These elements
are referred to as picture elements, pixels,
and pels.

3
Lecture 1

Digital Image Processing


 Image Enhancement

 Image Restoration

 Image Understanding (or Computer Vision)

 Image Coding (or Image Data Compression)

4
Lecture 1

Image Enhancement
 Goal
 to accentuate certain image features for subsequent
analysis or for image display

Input : image Output : image

5
Lecture 1

Image Enhancement
 Techniques
 Contrast enhancement
 histogram equalization
 pseudo coloring
 noise filtering
 edge sharpening
 smoothing

 Applications
 processing of remote-sensed image via satellite
 radar, SAR, Ultrasonic image processing

6
Lecture 1

Image Restoration
 Goal
 to remove or minimize known/unknown degradations in
image

Input : image Output : image

7
Lecture 1

Image Restoration
 Techniques
 De-blurring
 noise filtering
 correction of geometric distortion
 inverse filtering
 Least mean square(Wiener) filtering

 Applications
 remote-sensed image processing
 noise cancellation

8
Lecture 1

Image Understanding
 Goal
 to interpret or describe the meaning contained in the
image
Input : image Output : interpretation(description)

“ME”

“circle”

9
Lecture 1

Image Understanding
 Techniques
 boundary descriptor
 regional descriptor
 relational descriptor

 Applications
 character recognition
 automatic inspection of industrial parts
 ATR(automatic target recognition)
 target tracking

10
Lecture 1

Image Data Compression


 Goal
 to reduce the amount of data required to represent
images

Input : image Output : bit-stream data

“010100101100110101001 . . . .”

11
Lecture 1

Image Data Compression


 Techniques
 Error-free coding( or lossless coding)
 Lossy compression
 Image Compression Standard
 JPEG, H.261, H.263, MPEG-1,2,4 etc

 Applications
 Transmission
 teleconferencing ,TV system, remote sensing via satellite
 Storage
 VOD(video on demand), Video CD, DVD(digital video disk),
medical imaging, educational and business documents

12
Lecture 1

Imaging
The whole electromagnetic spectrum is used by “imagers”

Electromagnetic Spectrum radio


frequency
microwave
visible (SAR)
gamma
cosmic rays
X-Rays UV
rays IR

-4 -2 2 4 6 8 10 12
10 10 1 10 10 10 10 10 10
wavelength (Angstroms)
-1 0
1 Å = 10 m

13
Lecture 1

Scales of Imaging

From the gigantic…

14
Lecture 1

Scales of Imaging

… to the everyday …

video camera

1m

15
Lecture 1

Scales of Imaging

… to the tiny.

16
Lecture 1

Digital Image Formation

17
Lecture 1

Matrix Representation
183 160 94 153 194 163 132 165
183 153 116 176 187 166 130 169

179 168 171 182 179 170 131 167 
177 177 179 177 179 165 131 167 
178 178 179 176 182 164 130 171
 
179 180 180 179 183 169 132 169
179 179 180 182 183 170 129 173
 
180 179 181 179 181 170 130 169

Divide into
8x8 blocks
H=256

W=256
18
Lecture 1

Image Resolution

19
Lecture 1

Image Resolution

20
Lecture 1

Bitplanes

Original 8bits/pixel Bitplane 7 Bitplane 6


one 8-bit byte Bitplane 7

Bitplane 0 Bitplane 5 Bitplane 4


21
Lecture 1

Bitplanes

Original 8bits/pixel Bitplane 3 Bitplane 2


one 8-bit byte Bitplane 7

Bitplane 0 Bitplane 1 Bitplane 0


22
Lecture 1

Dimensionality of Digital Images

 Images and videos are multi-dimensional (≥ 2


dimensions) signals.

Dimension 3

Dimension 2 2-D image


3-D Image
Dimension 2 Sequence
or video

Dimension 1
Dimension 1

23
Lecture 1

The Human Visual System (HVS)

left eye right eye


pupil
cornea
retina retina

lens

LGN
retina

primary visual
fovea
cortex
optic nerve
visual axis
higher level vision
and cognition

24
Lecture 1

HVS: Foveated Vision


Foveated vision: non-uniform resolution of the visual field,
highest at the point of fixation and decreasing rapidly

25
Lecture 1

HVS: Visual Illusion

26
Lecture 1

HVS: Visual Illusion

Find the black dot

27
Lecture 1

HVS: Visual Illusion

What is this?
28
Lecture 1

HVS: Visual Illusion

Which lines are straight?

29
Lecture 1

Color

30
Lecture 1

Color: RGB Cube

31
Lecture 1

Color: RGB Representation

32
Lecture 1

Where Are We?

Display/Printing?

Computer
Imaging?
Vision?
Digital Image
Processing

Computer Biological
Graphics? Vision?

33
Lecture 1

What Do We Do?

Image Processing/
Manipulation

Digital Image
Processing

Image Analysis/ Image Coding/


Interpretation Communication

34
Lecture 1

Image Processing: Image Enhancement

Enhance

36
Lecture 1

Image Processing: Image Denoising

Denoise

37
Lecture 1

Image Processing: Image Deblurring

Deblur

38
Lecture 1

Image Processing: Image Inpainting

39
Lecture 1

Image Processing: Image Stylization

40
Lecture 1

Image Analysis: Edge Detection

41
Lecture 1

Image Analysis: Face Detection

42
Lecture 1

Image Analysis: Image Segmentation

43
Lecture 1

Image Analysis: Image Matching

Two deceivingly similar fingerprints of two different people

44
Lecture 1

Image Coding: Image Compression

original image From [Gonzalez From [Gonzalez


262144 Bytes & Woods] & Woods]

image compressed bitstream image


00111000001001101…
encoder decoder
(2428 Bytes)
compression ratio (CR) = 108:1
45
Lecture 1

Image Coding: Image Compression

• Lossless image compression


– Information preserving
original image can be exactly recovered
– Low compression ratio
– JPEG-LS, JBIG …

• Lossy image compression


– Lose information
original image can be recovered, but not the same
– High compression ratio
– JPEG, JPEG2000 …

46
Lecture 1

Image Coding: From JPEG to JPEG 2000

discrete cosine transform based wavelet transform based


JPEG (CR=64) JPEG2000 (CR=64)

47
Lecture 1

Image Coding: Video Compression

• From static images and image sequences (video)


– From 2D to 3D
– Strong correlations between frames
– Representing motion

• Video compression
– Compress each frame independently
– Motion-compensated video compression
high compression ratio
– MPEG1, MPEG2, MPEG4, H.264 …

48
Lecture 1

Image Quality/Distortion Measures

_
=

_
|X Y| = Z
For each _
pixel:
| xij yij | = zij

1 M N
Mean Absolute Error (MAE): MAE = ∑∑
MN i =1 j =1
xij − yij

49
Lecture 1

Image Quality/Distortion Measures


1 M N
∑∑
2
Mean Squared Error (MSE): MSE = xij − yij
MN i =1 j =1

Peak Signal-to-Noise Ratio (PSNR)  in decibel (dB):


 
 
 L 
 = 10 log10  
2 2
L
PSNR = 10 log10   1 M N 2 
 
∑∑
MSE
 xij − yij 
 MN i =1 j =1 
L: Dynamic range of pixel intensity
L = 2B – 1, where B is the number of bits to represent a pixel
Examples:
8bits/pixel gray-scale image  L = 255
12bits/pixel gray-scale image  L = 4095
50
Lecture 1

Image Quality/Distortion Measures

original noisy image 1 noisy image 2 noisy image 3

MAE = 0 MAE = 7.99 MAE = 15.9 MAE = 38.2


MSE = 0 MSE = 100 MSE = 394 MSE = 2250
PSNR = infinity PSNR = 28.1dB PSNR = 22.2dB PSNR = 14.6dB

51
Lecture 1

Image Quality/Distortion Measures


• Example: two 4 x 4, 4bits/pixel image

1 8 6 6 2 8 8 7 1 0 2 1
6 3 11 8 _ 6 3 12 8 0 0 1 0
8 8 9 10 5 4 9 1
= 3 4 0 9
9 10 10 7 15 9 11 9 6 1 1 2
|X _ Y| = Z
| xij _ yij | = zij

MAE =
1
(1 + 0 + 2 + 1 + 0 + 0 + 1 + 0 + 3 + 4 + 0 + 9 + 6 + 1 + 1 + 2) = 1.9375
4× 4
MSE =
1
(1 + 0 + 4 + 1 + 0 + 0 + 1 + 0 + 9 + 16 + 0 + 81 + 36 + 1 + 1 + 4) = 9.6875
4× 4
 (2 B − 1) 2   152 
PSNR = 10 log10   = 10 log10   = 13.7 dB
 MSE  52
 9.6875 

You might also like