entropy coding present by 陳群元. outline constraints compression efficiency computational...

45
Entropy coding Present by 陳陳陳

Upload: clinton-hines

Post on 11-Jan-2016

254 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Entropy coding

Present by 陳群元

Page 2: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

constraints Compression efficiency Computational efficiency Error robustness

Page 3: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Encoding DCT Reordering Run-level coding Entropy coding

Page 4: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Encoding DCT Reordering Run-level coding Entropy coding

Page 5: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

DCT

Page 6: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Reordering The optimum method of reordering the

quantised data depends on the distribution of the non-zero coefficients.

Page 7: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Evenly distribution

Page 8: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Zigzag reordering pattern

Page 9: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Interlaced video-vary more in vertical

Page 10: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Modified reordering pattern

Page 11: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Encoding DCT Reordering Run-level coding Entropy coding

Page 12: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Run-level coding Long sequences of identical values (zeros in

this case) can be represented as a (run, level) code

(run) indicates the number of zeros preceding a non-zero value

(level) indicates the sign and magnitude of the non-zero coefficient

Page 13: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Run-level coding(ex)

Page 14: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Encoding DCT Reordering Run-level coding Entropy coding

Page 15: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Huffman Coding ‘True’ Huffman Coding Modified Huffman Coding Table Design Entropy Coding Example Variable Length Encoder Design Variable Length Decoder Design Dealing with Errors

Page 16: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Huffman Coding ‘True’ Huffman Coding Modified Huffman Coding Table Design Entropy Coding Example Variable Length Encoder Design Variable Length Decoder Design Dealing with Errors

Page 17: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

True Huffman Coding

Page 18: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Generating the HufSman code tree 1. Order the list of data in increasing order of

probability. 2. Combine the two lowest-probability data

items into a ‘node’ and assign the joint probability of the data items to this node.

3. Reorder the remaining data items and node(s) in increasing order of probability and repeat step 2.

Page 19: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness
Page 20: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

encoding

Page 21: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

decoding

Page 22: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

disadvantage the decoder must use the same codeword set

as the encoder reduces compression efficiency.

calculating the probability table for a large video sequence a significant computational overhead cannot be done until after the video data is

encoded

Page 23: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Huffman Coding ‘True’ Huffman Coding Modified Huffman Coding Table Design Entropy Coding Example Variable Length Encoder Design Variable Length Decoder Design Dealing with Errors

Page 24: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Table design

Final pair

Page 25: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Table design

Page 26: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

H.263/MPEG-4 motion vector difference (MVD) The H.263MPEG-4 differentially coded motion

vectors (MVD) are each encoded as a pair of VLCs, one for

the x-component and one for the y-component

Page 27: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

mvd

Page 28: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

mvd

Page 29: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

H.26L universal VLC (UVLC) The emerging H.26L standard takes a step

away from individually calculated Huffman tables by using a ‘universal’ set of VLCs for any coded element. Each codeword is generated from the following systematic list:

Page 30: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness
Page 31: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness
Page 32: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Huffman Coding ‘True’ Huffman Coding Modified Huffman Coding Table Design Entropy Coding Example Variable Length Encoder Design Variable Length Decoder Design Dealing with Errors

Page 33: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Entropy Coding Example

Page 34: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Huffman Coding ‘True’ Huffman Coding Modified Huffman Coding Table Design Entropy Coding Example Variable Length Encoder Design Variable Length Decoder Design Dealing with Errors

Page 35: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Variable Length Encoder Design

Page 36: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Huffman Coding ‘True’ Huffman Coding Modified Huffman Coding Table Design Entropy Coding Example Variable Length Encoder Design Variable Length Decoder Design Dealing with Errors

Page 37: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Variable Length Decoder Design

Page 38: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Huffman Coding ‘True’ Huffman Coding Modified Huffman Coding Table Design Entropy Coding Example Variable Length Encoder Design Variable Length Decoder Design Dealing with Errors

Page 39: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Dealing with Errors

Page 40: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Arithmetic Coding

Page 41: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Ex . encode (0,-1,0,2)

0.394

Page 42: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness
Page 43: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Ex . decode (0,-1,0,2)

Page 44: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

Arithmetic coding vs huffman Ideal

0.394 in this case, which can be represented as a fixed-point number with sufficient accuracy using 9 bits

Huffman: 1;0011;1;0000110=>13 bits

Page 45: Entropy coding Present by 陳群元. outline constraints  Compression efficiency  Computational efficiency  Error robustness

The end Thank you