You are on page 1of 2

E9 241 Digital Image Processing Practice Problem Set 1

1. Basic Global Thresholding


Consider the following algorithm to determine the threshold for thresholding gray scale images
to obtain binary images.

(a) Select an initial estimate for the global threshold T0 and set n = 0.
(b) Use the global threshold Tn to classify the image pixels into two classes, Class 0 and
Class 1
(c) Compute the corresponding average intensity values µn0 and µn1 (note that these average
intensities are computed using the gray scale image pixel intensities)
(d) Compute a new threshold Tn+1 such that Tn+1 = 21 (µn0 + µn1 ).
(e) Increment n as n = n + 1. If the difference in successive iterates |Tn+1 − Tn | > ∆T , go
to Step (b). Else stop.

Now answer the following questions:


(a) Write expressions for µn0 and µn1 in terms of the normalized histogram of the image p(k).
Also write expressions for successive iterates of µn0 and µn1 by reusing computations in
the previous iteration.
(b) Show that if T1 ≤ T0 , then successive iterates satisfy Tn+1 ≤ Tn for n ≥ 1. (Note that a
similar result is true in the other direction i.e. if T0 ≤ T1 , then Tn+1 ≥ Tn .)
(c) Prove that the algorithm converges in a finite number of steps for ∆T = 0 (Hint: Use
the above and also note that if successive iterates are in the same interval [k, k + 1] for
any k ∈ {0, 1, 2, . . . , K − 2}, then the algorithm would have converged.).
(d) Is the threshold to which the algorithm converges dependent on the initial threshold T0 ?
Justify.
(e) Suppose that the above algorithm is implemented for a hypothetical image with contin-
uous pixel intensities in [0, 1] having a probability density function described as
(
1 if x ∈ [0, 1]
p(x) = .
0 otherwise
Find limn→∞ Tn for any T0 ∈ (0, 1).
2. Binary Morphology
Find a sequence of binary morphological operators (along with the respective structural ele-
ments) that can transform the input image in Fig. 1(a) to Fig. 1(b) and Fig. 1(c) respectively.

1
Figure 1: Binary Morphology

(a) Input Image (b) Output 1

(c) Output 2

You might also like