100% found this document useful (1 vote)
113 views3 pages

(EIE529) Assignment 2

This document outlines an assignment for a digital image processing course. It contains two questions worth 50 marks total. Question 1 (25 marks) involves image restoration using inverse filtering and regularization approaches. Question 2 (25 marks) covers image coding and compression, including Lloyd-Max quantization, Huffman coding, and arithmetic coding. Students must submit their solutions via Blackboard Collaborate by the deadline of November 1, 2020 with no late submissions accepted.

Uploaded by

JefferyMak
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
113 views3 pages

(EIE529) Assignment 2

This document outlines an assignment for a digital image processing course. It contains two questions worth 50 marks total. Question 1 (25 marks) involves image restoration using inverse filtering and regularization approaches. Question 2 (25 marks) covers image coding and compression, including Lloyd-Max quantization, Huffman coding, and arithmetic coding. Students must submit their solutions via Blackboard Collaborate by the deadline of November 1, 2020 with no late submissions accepted.

Uploaded by

JefferyMak
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Assignment 2

EIE 529 - Digital Image Processing, Fall 2020-21


Department of Electronic and Information Engineering,
The Hong Kong Polytechnic University

Due 10:59pm, November 1 (Sunday), 2020


**No Late Submission Will be Accepted**

Note:
1) This assignment contains two questions and carries 50 marks in total.
2) Your solutions should be submitted via Blackboard Collaborate before the deadline.

Q1: Image Restoration (25 marks)


Figure 1 shows a standard image degradation and restoration model, i.e., 𝑔(𝑥, 𝑦) = ℎ(𝑥, 𝑦) ∗
𝑓(𝑥, 𝑦) + 𝜂(𝑥, 𝑦), where ℎ(𝑥, 𝑦) is the point spread function. It is known that the noise 𝜂(𝑥, 𝑦)
and image 𝑓(𝑥, 𝑦) are uncorrelated, and 𝜂(𝑥, 𝑦) is white Gaussian with zero mean and variance
𝜎 2.

Figure 1. The image degradation and restoration process.


1) Show that:
𝑃𝑔𝑔 (𝑢, 𝑣) = |𝐻(𝑢, 𝑣)|2 𝑃𝑓𝑓 (𝑢, 𝑣) + 𝑃𝜂𝜂 (𝑢, 𝑣),

where 𝑃𝑓𝑓 (𝑢, 𝑣), 𝑃𝑔𝑔 (𝑢, 𝑣) and 𝑃𝜂𝜂 (𝑢, 𝑣) are the power spectral density of the original image,
degraded image, and addictive noise at frequency (𝑢, 𝑣), respectively. The frequency response
of the point spread function ℎ(𝑥, 𝑦) is denoted by 𝐻(𝑢, 𝑣), ∀𝑢, 𝑣 . (Hint: For a random
variable 𝑥, 𝑃𝑥𝑥 (𝑢, 𝑣) = 𝔼[|𝑋(𝑢, 𝑣)|2 ] = 𝔼[𝑋(𝑢, 𝑣)𝑋 ∗ (𝑢, 𝑣)], 𝑋 is the Fourier transform of 𝑥
and 𝑋 ∗ is the complex conjugate of 𝑋.) (5 marks)
2) Suppose the 𝑓(𝑥, 𝑦) has a size of 𝑀 × 𝑁 (i.e., 𝑥 = 0, ⋯ , 𝑀 − 1, 𝑦 = 0, ⋯ , 𝑁 − 1) where
𝑀, 𝑁 are even numbers, and 𝑔(𝑥, 𝑦) = 𝑓(𝑥, 𝑦) + 2𝑓(𝑥 − 1, 𝑦) + 𝑓(𝑥 − 2, 𝑦) + 𝜂(𝑥, 𝑦):
a) Use the inverse filtering technique to restore the image. Find the expression for both
the inverse filter estimator and the restored image in the frequency domain. (6 marks)

1
b) Find the specific frequency/frequencies for which the restored image cannot be
estimated using the inverse filtering technique. (Hint: It is equivalent to find the
frequency/frequencies where the response of the inverse filter equals infinite.) (4 marks)
c) Consider the regularization approach for image restoration (also known as the
constrained least squares filtering). Suppose the following two-dimensional high-pass
filter 𝑝(𝑥, 𝑦) is applied to the original image to approximate ∇2 𝑓(𝑥, 𝑦) (i.e., the prior
as stated in the lecture notes).
0 0 0
𝑝(𝑥, 𝑦) = [−1 2 −1].
0 0 0

Find the expression of both the image restoration filter and the restored image in the
frequency domain. You may assume the Lagrange multiplier used in the regularization
approach is 𝜆 (𝜆 > 0). (Hint: You need to first obtain the frequency response of 𝑝(𝑥, 𝑦)
in order to apply the related formula(s) in the lecture notes.) (6 marks)
d) Is there any frequency for which the restored image cannot be estimated using the
regularization approach with the 𝑝(𝑥, 𝑦) specified in c)? If yes, find the specific
frequency/frequencies for which the restored image cannot be estimated; If no, please
justify your answers. (4 marks)

Q2: Image Coding and Compression (25 marks)


1) The L-level Lloy-Max quantizer for a random variable 𝑋 distributed within [𝑎, 𝑏] (𝑎 < 𝑏) is
obtained by minimizing the distortion in the following expression,
𝐿 𝑑𝑘
𝐷 = ∑∫ (𝑥 − 𝑟𝑘 )2 𝑝(𝑥)𝑑𝑥 ,
𝑘=1 𝑑𝑘−1

where 𝑟𝑘 , 𝑘 = 1, ⋯ , 𝐿 are the quantization levels, 𝑑𝑘 , 𝑘 = 0,1, ⋯ , 𝐿 are the decision thresholds,
and 𝑝(𝑥) is the probability density function of 𝑋.
a) What is the optimal value of 𝑑0 and 𝑑𝐿 for minimizing 𝐷? Please provide necessary
explanations for your answers. (2 marks)
b) Show that the optimal quantization levels and decision thresholds have the following
relationship as shown in the lecture notes (8 marks):
1
𝑑𝑘 = (𝑟𝑘 + 𝑟𝑘+1 ), 𝑘 = 1,2, ⋯ , 𝐿 − 1,
2
𝑑
∫𝑑 𝑘 𝑥𝑝(𝑥)𝑑𝑥
𝑘−1
𝑟𝑘 = 𝑑𝑘 , 𝑘 = 1, ⋯ , 𝐿.
∫𝑑 𝑝(𝑥)𝑑𝑥
𝑘−1

3) Given that a coding system with an information source that generates 5 symbols
{𝑎1 , 𝑎2 , 𝑎3 , 𝑎4 , 𝑎5 }, with the probabilities of {0.1,0.15,0.25,0.20,0.30}, respectively.

2
a) What is the entropy of the information source? (3 marks)
b) Based on the Huffman coding method, determine the codewords the coding system
would generate if the following input sequence is received {𝑎1 , 𝑎2 , 𝑎4 , 𝑎5 , 𝑎3 }. Give also
the average number of bits for coding this input sequence (i.e., the average number of
bits for coding a symbol). (6 marks)
c) If the coding system now changes to use the arithmetic coding, give the range (in
decimal numbers) where the final codeword would locate. (6 marks)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy