Efficient Huffman Decoding Source 2000 Proceedings 2000 International

  • Slides: 10
Download presentation
Efficient Huffman Decoding Source: 2000. Proceedings. 2000 International Conference on Image Processing, Volume: 1

Efficient Huffman Decoding Source: 2000. Proceedings. 2000 International Conference on Image Processing, Volume: 1 , 2000, pp. 936– 939 Author: Aggarwal, M. ; Narayan, A. Speaker: Hsien-Wen Tseng Date: 11/15/2001 1

Outline • Introduction • Lookup Table Method • Proposed Algorithm • Discussion 2

Outline • Introduction • Lookup Table Method • Proposed Algorithm • Discussion 2

Introduction Memory: O(2 h) Complexity: O(h) A B L K J I H GF

Introduction Memory: O(2 h) Complexity: O(h) A B L K J I H GF E D C Memory: O(n) Complexity: a few computations 3

Lookup Table Method 4

Lookup Table Method 4

Proposed Algorithm Huffman Table 5

Proposed Algorithm Huffman Table 5

LMBC Function lmbc( ): The position of the first-bit-change. Example: 11011 LMBC = 2

LMBC Function lmbc( ): The position of the first-bit-change. Example: 11011 LMBC = 2 000101011 LMBC = 3 Decoding procedure: 1. Determine the partition 2. Search the codeword sequentially Example B = 0000111000111 6

Canonical Huffman Code • Canonical codes are a subclass of Human codes, that have

Canonical Huffman Code • Canonical codes are a subclass of Human codes, that have a numerical sequence property, i. e. codewords with the same length are binary representations of consecutive integers. • The usage of canonical codes is simple decoding technique. 7

Modified Huffman Table 8

Modified Huffman Table 8

Decoding Algorithm • Determine the partition – Using first bit and lmbc( ) function

Decoding Algorithm • Determine the partition – Using first bit and lmbc( ) function – B = “ 0001011001”, LMBC = 3 • Determine the common length Li and the numerically least codeword FCi in Pi – Li = 7, FCi = “ 0001000” • Let C be the first Li bits of B, then (C-FCi) can be used as an index into lookup table yielding the desired symbol and its actual length li – C = “ 0001011”, C-FCi = 3, li = 5 • The bitstream is left-shifted by li and process iterated until the last symbol 9

Discussion • The proposed algorithm requires very few computations to decode a codeword. •

Discussion • The proposed algorithm requires very few computations to decode a codeword. • The memory requirement would be large in worst case. – Codewords {000100, 00011111} – Require 24=16 entries • In the MPEG-1, MPEG-2, H. 261, H. 263 standards, require additional memory only about one-third of n. 10