You are on page 1of 4

VLSI DECODER ARCHITECTURE FOR

EMBEDDED ZEROTREE WAVELET ALGORITHM


Li-minn Ang, Hon Nin Cheung and Kamran Eshraghian

Centre for Very High Speed Microelectronic Systems


Edith Cowan University
Joondalup WA 6027, Australia

ABSTRACT child coefficient and its corresponding parent coefficient stored


in memory. The approach taken by the EZW encoder
In this paper, we present a hardware architecture to implement architecture reported in [8] is based on an efficient scheme to
the decoder for the embedded zerotree wavelet (EZW) algorithm. determine ancestor-descendant relationships in the wavelet
The decoder architecture complements an encoder architecture coefficient data stream by rearrangement of the data stream. The
for the EZW algorithm which has been reported recently. benefits of this approach are that the EZW encoder architecture is
Similar to the reported encoder architecture, the proposed regular and modular and does not require addressing hardware to
decoder architecture is regular and modular and is suitable for locate the parent and children coefficients in memory.
VLSI implementation. The input into the decoder architecture is
the output data stream from the encoder architecture containing In this paper, we present a VLSI architecture to implement the
the- significance map symbols and the successive-approximation decoder to complement the EZW encoder architecture reported in
quantization symbols of the EZW algorithm. The decoding for [8]. The input into the decoder is the output data stream from the
the EZW algorithm is formulated in view of the output data encoder containing the SMAP symbols and the SAQ symbols of
stream from the encoder and the corresponding VLSI the EZW algorithm. One difficulty in designing the decoder
architecture to implement the formulated requirements is architecture is due to the removal of redundant ZTR symbols
presented. The proposed EZW decoder architecture together from the output data stream by the encoder before transmission
with th_e encoder architecture forms a basis for a scalable image to the decoder. For better coding efficiency, the encoder
or'video coding system which is suitable for ASIC VLSI removes from the output data stream the ZTR. symbols which can
implementation. be inferred by the decoder from previous information the decoder
has received from the encoder. The design approach is based on
1. INTRODUCTION developing an efficient scheme using FIFO queues to restore the
removed ZTR. symbols into the output data stream before the
In recent years, image and video coding algorithms have been decoding process. The decoding for the EZW algorithm is
researched for their coding efficiency in general [l] and for their formulated in view of the output data stream from the encoder
scalability [2] in particular. The scalability of an image or video and the corresponding VLSI architecture to implement the
coded bit-stream to allow for screen resolution displays of formulated requirements is reported. The proposed EZW
different sizes and for transmission at different bit-rates is one of decoder architecturetogether with the encoder architecture forms
the most desirable features in image and video coding [3]. a basis for a scalable image or video coding system which is
Amongst the coding algorithms, the embedded zerotree wavelet suitable for ASIC VLSI implementation.
(EZW) algorithm [4] and its variants [5][6] have been found to
be promising solutions not only in terms of coding efficiency, but 2. EZW ENCODER ARCHITECTURE
also in their potential for scalable coding. After performing the
discrete wavelet transform (DWT), the EZW algorithm The EZW encoder architecture reported in [8] uses four symbols
establishes an ancestor-descendant relationship between the POS (positive), NEG (negative), ISZ (isolated zero) and ZTR
wavelet coefficients of the image subbands. The EZW algorithm (zerotree root) to code the SMAP and a futher two symbols
uses the ancestor-descendant relationship contained in the tree UPPER and LOWER for the SAQ of the wavelet coefficients.
.hierarchy to efficiently code the positions and signs of the The SMAP is coded based on the significance of the coefficient
significant coefficients as well as their approximate magnitudes and the combined significance of its descendant coefficients. A
in decreasing order of importance. The positions and signs of the coefficient is defined as significant if the magnitude of the
significant coefficients are encoded in a significance map coefficient value is greater than or equal to the current threshold
(SMAP) and their approximate magnitudes are encoded using value. A coefficient is coded as POS if the coefficient is
successive-approximationquantization (SAQ). One symbol used significant and the value of the coefficient is positive and is
in coding the S M A P is the zerotree root (ZTR) symbol which is coded as NEG if the coefficient is significant and the value of the
used to inform the decoder that all the descendants of a coefficient is negative. A coefficient is coded as ISZ if it is itself
coefficient are not significant. To enable real-time applications, not significant and at least one of its descendants is significant.
researchers have proposed VLSI architectures to implement the A coefficient is only coded as ZTR if it is itself not significant
EZW algorithm [7][8]. The EZW architectures reported in [7] and all its descendants are not significant. After a coefficient has
and [8] are for the EZW encoder. One difficulty in designing the been found to be significant, the encoder uses the symbols
EZW encoder is in locating the corresponding parent coefficient UPPER and LOWER to successively-approximatethe coefficient
for a given child coefficient [8]. The EZW encoder architecture magnitude at subsequent threshold values. The encoder uses the
reported in [7] uses address pointers to specify the addresses of a symbol LOWER if the coefficient magnitude is less than the

0-7803-5471-0/99/$10.0001999IEEE

1-141
approximated magnitude and the symbol UPPER if the contains a maximum of 147 symbols. The information in the
coefficient magnitude is greater than or equal to the sign bits are encoded in the POS and NEG SMAF’ symbols.
approximated magnitude. Each of the six symbols are coded Furthermore, for better coding efficiency, the EZW encoder
using three binary digits. The six symbols and their binary removes fiom the output data stream ZTR symbols if it descends
representations are shown in Fig. 1 where CO, C1 and C2 from an ancestor coefficient which is also a ZTR symbol. This
represent the first, second and third binary digit respectively. removal of ZTR symbols from the output data stream by the
encoder adds a difficulty in designing the decoder architecture.

~ ,, EZW
Cl0..Cl6
POS 1111 ... 0010 ... 0000 ... 0000 1010 ... 0100 encoder
NEG cz, .. cr,
IS2
ZTR Figure 3. EZW encoder
I I I I I
Figure 1. Symbol binary representations
One difficulty in designing the EZW encoder is in locating the 3. PROBLEM FORMULATION
corresponding parent coefficient for a given child coefficient.
The approach taken by the encoder architecture is based on an One difficulty in designing the EZW decoder architecture is due
efficient scheme to determine ancestor-descendant relationships to the removal of redundant ZTR symbols from the output data
in the wavelet coefficient data stream by rearrangement of the stream by the encoder before transmission to the decoder. The
data stream for simpler VLSI implementation. Fig. 2(a) shows decoder design approach is based on developing an efficient
an-example of an ancestor-descendant tree hierarchy using data scheme using FIFO queues to restore the removed ZTR symbols
from [4] and Fig. 201) shows the arrangement in sign-magnitude into the output data stream before the decoding process. A
representation of the coefficient data stream. The m o w in Fig. specific difficulty in the restoration of the ZTR symbols is that
2(b) indicates the direction of the data stream. The bit positions the decoder has to take into account the presence of the LOWER
bo to b6 contains the magnitudes of the coefficients where b6 is and UPPER SAQ symbols and insert the necessary ZTR symbols
the MSB and bo is the LSB. The bit position b7 contains the sign into their correct locations in the output data stream. For
bits oWle coefficients. example, Fig. 4(a)-4(d) shows the four possible interpretations
leu12 .3l and their corresponding decoder output data stream for the
encoder input data stream {UPPER, ZTR} where the ZTR
M I &
,
IS symbol is the first symbol transmitted.

A&&&
UPPER m m m
,mmmU P P E R r n )
Zra UPPER zm m m m UPPm m ZTR m m UPPER

~ITIIIIRUPPuumITIo (zTR.UPpERLTRmm1 ( U P P u V I I L L I R I R r n l
(a) Ancestor-descendant tree hierarchy (a) (b) (c) (4
b,br ... b, Figure 4. Decoder possible interpretations and their
OOMllll correspondingoutput data stream
1 am101

I 0 wola,l
0oOax)ll
} level 0
The decoder selects the correct interpretation from information
the decoder has previously received from the encoder.
Specifically, the decoder keeps track of which wavelet
coefficient has already received a POS or NEG SMAP symbol.
) level 0 Once a POS or NEG SMAP symbol has been received for a
wavelet coefficient, then subsequent symbols for the wavelet
coefficient can only be UPPER or LOWER SAQ symbols. To
I 1 MM011
OowolOl
} level 0 formulate the restoration of the ZTR symbols, two additional
binary symbols DELAY-FLAG and SIG-FLAG are defmed.
The symbol DELAY-FLAG is set to ‘1’ if a ZTR symbol is to be
inserted into the output data stream. The symbol SIG-FLAG is
set to ‘1’ for wavelet coefficients which have already received a
POS or NEG S M A P symbol. Whenever the decoder receives a
(b) Coefficient data stream arrangement symbol from the encoder, it inserts the symbol into a FKFO
Figure 2. Ancestor-descendanttree hierarchy queue, FIFO-SYMBOL. Fig. 5 shows the algorithm for the
and coefficient data stream arrangement restoration of the ZTR symbols into the output data stream.

A single bit-stream is formed from the data stream arrangement i f DELAY-FLAG = 0 or SIG-FLAG = 1
in Fig. 2(b) as the input into the EZW encoder architecture. The remove SYMBOL from FIFO-SYMBOL queue
single bit data stream is formed fiom the sign bits, followed by output SYMBOL into output data stream
the MSBs and ending with the LSBs as shown in Fig. 3. The else
output of the EZW encoder architecture is a data stream output ZTR into output data stream
containing the SMAP symbols and SAQ symbols as represented endif
by the binary digits CO, C1 and C2 shown in Fig. 1. Although
the input stream contains 168 bits, the output stream only Figure 5. Algorithm for restoration of ZTR symbols

I- 142
One way to implement the operation of the DELAY-FLAG is to hierarchy as in Fig. 2. The processors are implemented using
use a counter to keep track of the number of delays before the FIFO queues (FIFO-CO, FIFO-C1, FXFO-C2) to store the data
decoder has to remove a symbol from the FIFO queue. Delays stream symbols, counters (COUNT20, COUNT4) to implement
are only required if the current symbol is a ZTR symbol and the the operation of the DELAY-FLAG, delay elements, logic gates
number of delays required is equal to the number of descendants and multiplexers. The delay elements SRO and SRI can be
the coefficient has and is given by: implemented using single-bit shift registers with the same size as
the number of coefficients to be decoded. The control input
41+1 -1 SIGNMAGNITUDE-SELECTOR selects if sign bits or
delay = -- 1
3 magnitude bits are to be decoded. The control input is set to ‘0’
where the label I denotes the level of the coefficient in the to decode sign bits and is set to ‘1’ to decode magnitude bits.
ancestor-descendant tree hierarchy where the leaf coefficients of The control input LEVEL-SELECTOR selects 1, the level of the
the tree are at level 0 and the root coefficient of the tree is at the coefficient in the ancestor-descendanttree hierarchy.
highest level. After the necessary ZTR symbols have been
inserted into the output data stream, the decoder carries out the Whenever processor P1 receives a symbol from the encoder, it
decoding of the S M A P symbols and the SAQ symbols into the inserts the symbol which is represented by the binary digits CO,
required coefficient bit-stream. Assuming that at each clock C1 and C2 into the FIFO queues FIFO-CO, FIFO-C1 and
cycle i, one symbol represented by the binaxy digits CO, C1 and FIFO-C2 respectively. The insertion into the FIFO queues and
C2 is input into the architecture, then the decoding of the the removal from the FIFO queues are controlled by the fifo-wr
symbols into the required bits b can be determined. The and fifo-rd control signals respectively. Whenever a symbol is
coefficient magnitude bits are decoded by: to be inserted into the queues, the fifo-wr control signal is set to
‘1’ and whenever a symbol is to be removed fiom the queues, the
b, = C1, if CO,=O fifo-rd control signal is set to ‘1’. The counters COUNT4 and
= -Cl, if CO,= 1 COUNT20 are reset whenever the current symbol is a ZTR
symbol and the DELAY-FLAG is ‘0’. The selection of which of
where - is the NOT logical operator. The coefficient sign bits are the counters is to be reset depends on the level of the ZTR
encoded in the POS and NEG S M A P symbols. The decoder symbol in the ancestor-descendant tree hierarchy. For example,
keeps-track of each POS or NEG symbol received for each if the current level is two, then the COUNT20 counter is reset.
wavelet coefficient and decodes the sign bits by: The SIG-FLAG is set to ‘1’ for wavelet coefficients which have
already been decoded to be a POS or NEG SMAF’ symbol.
b, = 1 ifNEGSMAPsymbo1 received (3)
= 0 if POS S W symbol received 5. CONCLUSIONS

4. EZW DECODER ARCHITECTURE In this paper, we have presented a hardware architecture for the
EZW decoder which is regular and modular and is suitable for
Using the algorithm in Fig. 5 and Equations (2)-(3), we can VLSI implementation. The decoder architecture complements an
develop a hardware architecture for the EZW decoder which is EZW encoder architecture which has been reported recently.
regular and modular and is suitable for VLSI implementation. The input into the decoder architecture is the output data stream
Fig. 6 shows the proposed decoder architecture using two from the encoder architecture containing the S W symbols and
processors P1 and P2. The input into processor P1 is the output the SAQ symbols of the EZW algorithm. The decoder design
data stream from the encoder containing the SMAP symbols and approach is based on developing an efficient scheme using FIFO
the SAQ symbols as in Fig. 3. Processor P1 uses the algorithm queues to restore the ZTR symbols which have been removed by
in Fig. 5 to restore the necessary ZTR symbols into the output the encoder before transmission. The decoding for the EZW
data stream. Processor P2 uses Equations (2)-(3) to decode the algorithm have been formulated in view of the output data stream
restored output data stream into the required wavelet coefficient from the encoder and the corresponding VLSI architecture to
bit-stream. Before the decoding process, processor P2 appends implement the formulated requirements has been reported. The
zeros-to &e restored data stream to make the number of input proposed EZW decoder architecture together with the encoder
symbols equal to the number of output bits. The output of architecture forms a basis for a scalable image or video coding
processor P2 are the coefficient magnitude bits followed by the system which is suitable for ASIC VLSI implementation.
coefficient sign bits. The coefficient magnitude bits are decoded
from the symbols CO’, C1’ and C2’. The appended zeros are 6. REFERENCES
used to ‘push out’ the coefficient sign bits after the magnitude
bits have been decoded. [l] R. J. Clarke, “A survey of low-rate digital image coding
techniques,” 1993 Canadian Conference on Electrical and
Computer Engineering, Vol. 1, pp. 27-30, S e p . 1993.
b [2] N. D. Wells and P. N. Tudor, “Standardisation of scalable
CI, c1, 0 O,Cl’, c1;
+ P1 w P2
b7,b0 ’6
coding schemes,” IEEE Colloquium on Digital Terrestrial
c26
c20
- - Television,pp. 611-618, Nov. 1993.
131 D. Taubman and A. Zakhor, “Rate- and resolution-scalable
video and image compression with subband coding,”
Twenty-Seventh Asilomar Conference on Signals, Systems
and Computers, Vol. 2 , pp. 1489-1493,Nov. 1993.

I- 143
J. M. Shapiro, “Embedded image coding using zerotrees of [7] J. Bae and V. K. Prasanna, “A fast and area-efficient VLSI
wavelet coefficients,” IEEE Trans. Signal Processing, Vol. architecture for embedded image coding ” Proceedings
41, No. 12, pp. 3445-3462, Dec. 1993. International Conference on Image Processing, Vol. 3, pp.
A. Said and W. A. Pearlman, “A new fast and efficient 452-455, Oct. 1995.
image codec based on set partitioning in hierarchical trees,” [8] L. Ang, €3. N. Cheung and K. Eshr@an, “VLSI
IEEE Trans. Circuits and Systems for Video Technology, architecture for embedded zerotree wavelet coding,” to be
Vol. 6, NO. 3, pp. 243-250, Jw. 1996. presented at the International Symposium on DSP for
S. A. Martucci, I. Sodagar, T. Chiang and Y. Zhang, “A CommunicationSystems, Feb. 1999.
zerotree wavelet video coder,” IEEE Trans. Circuits and
systems for Video Technology, Vol. 7 , No. 1, pp. 109-118,
Feb. 1997.

LEVEL
SELECTOR

01

00

1
527 I

DELAY-FLAG

SIG-FLAG

-
Figure 7. VLSI architecture for processor P1

0 O,C2’, CTk 4.4 43

0 0 , C l k C’k

0 0,co; CV6
Figure 8. VLSI architecture for processor P2

1-144

You might also like