Lect 07
Lect 07
Image Segmentation-01
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Fundamentals
• Let R represent the entire spatial region
occupied by an image. Image segmentation is a
process that partitions R into n sub-regions, R1,
R2, …, Rn, such that
n
(a) Ri R.
i 1
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Background
• First-order derivative
f
f '( x) f ( x 1) f ( x)
x
• Second-order derivative
2 f
f ( x 1) f ( x 1) 2 f ( x)
x 2
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
x y
f ( x 1, y ) f ( x 1, y ) f ( x, y 1) f ( x, y 1)
4 f ( x, y )
9
1 if | R( x, y ) | T R wk zk
g ( x, y ) k 1
0 otherwise
7
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Line Detection
• Second derivatives to result in a stronger
response and to produce thinner lines than first
derivatives
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
10
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
• Let R1, R2, R3, and R4 denote the responses of the masks in Fig. 10.6.
If, at a given point in the image, |Rk|>|Rj|, for all j≠k, that point is
said to be more likely associated with a line in the direction of mask
k.
11
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
12
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Edge Detection
• Edges are pixels where the brightness function
changes abruptly
• Edge models
13
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
14
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
15
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
16
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
g y
The direction of the edge
- 90 17
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
19
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
20
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
21
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
22
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
23
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
24
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
25
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
26
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
27
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
28
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
2e 2 e 2
x y
x2 y 2 x2 y 2
x 2
1 y 1
2
4 2 e 2 2
4 2 e 2 2
x2 y 2
x2 y 2 2
e 2 2
4
29
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
30
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Marr-Hildreth Algorithm
1. Filter the input image with an nxn Gaussian
lowpass filter. N is the smallest odd integer
greater than or equal to 6
2.
1. Compute the Laplacian of the image resulting
from step1
g ( x, y ) G ( x, y ) f ( x, y )
2
31
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
32
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
• The Objective
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
37
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Hysteresis thresholding:
g NH ( x, y ) g N ( x, y ) TH
g NL ( x, y ) g N ( x, y ) TL
and
g NL ( x, y ) g NL ( x, y ) g NH ( x, y )
38
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
41
TL 0.04;TH 0.10; 4 and a mask of size 25 25
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
42
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
43
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
44
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad
Image and Video Processing
Topic
Computer Vision & Biometrics Lab, Indian Institute of Information Technology, Allahabad 45