Professional Documents
Culture Documents
Assignment 4
Cut-off date: 27 December 2020
Spring 2020
Solution
Not all steps given. For reference only.
The distribution of marks for this assignment is shown in the following table:
Question 1 2 3 4 Total
Percentage 25% 25% 25% 25% 100%
Question 1 ( 25 marks )
(a) By inverse warping, a planar image view of 1024 x 576 resolution is obtained from a full
panorama of size 3800 x 1000 (360 degrees). Given that the planar view is rotated by π/4
and the focal length is 500, determine the source pixel coordinates at the panorama for the
destination point (630, 320) at the planar image view. [ 11 marks ]
Answer: The coordinates in the source panorama are (615.2, 537.7).
(b) What are the major technical advantages of using digital terrestrial television (DTT) for
video broadcasting? What are the technical limitations of DTT? [ 8 marks ]
Answer:
Advantage: Not require high cost for network or cabling
Limitation:
- Spectrum in the air is limited
- The delivery is uni-directional instead of interactive
(c) Describe what Over-the-Top (OTT) streaming is. What are the major technical challenges
of using OTT? [ 6 marks ]
Answer:
OTT: Streaming video content through public Internet
Major challenge:
- Video delivery path is not controllable, not easy to guarantee the quality
- High cost for content delivery network (CDN)
Question 2 ( 25 marks )
("#$%)' %
(a) Eight samples are taken from the signal: 𝑝(𝑟) = cos ) %( * − " for r = 0 to 7. A one-
dimensional DCT is performed on p(r) to obtain the DCT output components P(u) for u =
0 to 7. Determine the DCT output components at DC and at u=5. Show your work.
[ 10 marks ]
Answer:
P(0) = -1.414
P(5) = 0
Answer:
p~(0) = 0.845 p~(1) = -0.733
p~(2) = 0.733 p~(3) = -0.845
p~(4) = -0.845 p~(5) = 0.733
p~(6) = -0.733 p~(7) = 0.845
(c) Explain why 2-D DCT is used in JPEG compression. What is the size of each DCT block
in JPEG compression? What are the pros and cons of using larger size of DCT blocks?
[ 5 marks ]
Answer:
- Separate high frequency (texture) from low frequency (gradual color change) component
- High frequency and low frequency components can be applied with different quantization
factor such that smaller bits allocated for less noticeable high frequency components
- 8x8 DCT block
Larger block size:
Cons – Much higher computational cost
Pros – Less blocky even insufficient bits is allocated
Question 3 ( 25 marks )
(a) Describe the differences between MPEG and H.261 in terms of their encoding schemes.
[ 3 marks ]
Answer:
- H.261 only has I-frame and P-frame
- MPEG has I-,P- and B-frame
- H.261 only reference to previous frame, but MPEG reference to previous and future frame
(b) Describe an application in which H.261 is preferred over MPEG. Explain why H.261 is
preferred for the application you described. [ 6 marks ]
Answer: Video conferencing more prefer H.261
- H.261 has less delay as only has I-frame and P-frame.
- MPEG has B-frame which reference to future frame. It induces more delay which is not
beneficial to real-time complication application such as video conferencing.
(c) Some MPEG frames are received in the order: 1, 5, 2, 3, 4, 9, 6, 7, 8, 13, 10, 11, 12 … .
Given that only Frames 1 and 13 are I-frames, what can be said about the identities of the
other frames? What are the M and N of the GOP (Group of Picture)? [ 4 marks ]
Answer: Frames 5, 9 are P-frames. Frames 2, 3, 4, 6, 7, 8, 10, 11, 12 are B-frames
M = 4, N = 12
Answer:
Sequential Search:
All the displacements [i,j] with the (2d+1)×(2d+1) windows are examined.
Logarithm Search:
Similar to a divide-and-conquer or binary search.
Hierarchical Search:
Hierarchical search takes a multi-resolution and iterative approach. The first iteration starts
with a low-resolution image. In each iteration, the resolution is doubled, and at full resolution
the final motion vector is found.
#EXTM3U
#EXT-X-VERSION:4
#EXT-X-TARGETDURATION:8
#EXTINF:7.160,
https://priv.example.com/fileSequence380.ts
#EXTINF:7.840,
https://priv.example.com/fileSequence381.ts
#EXTINF:7.400,
https://priv.example.com/fileSequence382.ts
(iv) What are the effects if we choose a smaller segment size for Live Stream?
- Smaller segment can achieve smaller latency
- But the server loading would be higher
- Too short segment size may lead to insufficient buffer and hence unstable playback
(b) Given the following 64 DCT coefficients, use the obtained actual quantization table from
Part (a) to determine the quantized DCT coefficients. Round your answers to nearest
integers. Show all your work. [ 8 marks ]
653 347 115 106 48 -80 -27 -41
-52 -59 -41 -31 -24 -10 -12 -1
-11 -22 -25 -5 2 -6 5 6
-18 26 16 -23 7 1 -1 11
9 34 -6 -25 22 7 -25 25
9 3 3 28 -20 16 22 3
0 -2 5 3 2 -6 -24 -2
0 -8 -18 34 -40 4 17 27
Answer: Quantized DCT
131 116 38 21 7 -7 -2 -2
-13 -15 -10 -5 -3 -1 -1 0
-3 -6 -5 -1 0 0 0 0
-5 5 2 -3 0 0 0 1
2 5 -1 -1 1 0 -1 1
1 0 0 1 -1 1 1 0
0 0 0 0 0 0 -1 0
0 0 -1 1 -1 0 1 1
Answer:
131 116 38 21 7 -7 -2 -2
-13 -15 -10 -5 -3 -1 -1 0
-3 -6 -5 -1 0 0 0 0
-5 5 2 -3 0 0 0 1
2 5 -1 -1 1 0 -1 1
1 0 0 1 -1 1 1 0
0 0 0 0 0 0 -1 0
0 0 -1 1 -1 0 1 1
(d) Referring to your table and zig-zag pattern from Part (c), write down the sequence of
(runlength, value) for AC run-length encoding.
[ 5 marks ]
Answer:
(-,116),(0,-13),(0,-3),(0,-15),(0,38),(0,21),(0,-10),(0,-6),(0,-5),(0,2),(0,5),(0,-5),(0,-5),(0,7),
(0,-7),(0,-3),(0,-1),(0,2),(0.5),(0,1),(2,-1),(0,-3),(1,-1),(0,2),(0,-2),(0,-1),(2,-1),(5,1),(0,1),
(6,-1),(1,-1),(0,1),(1,1),(0,-1),(0,1),(0,1),(0,1),(1,1),(1,-1),(2,1),(0,1)
[ End of Assignment 4 ]