Wavelet and Multiresolution Image Processing
Wavelet and Multiresolution Image Processing
Wavelets and
Multiresolution
Processing
All this time, the guard was looking at her, first through
a telescope, then through a microscope, and then
through an opera glass.
Lewis Carrol, Through the Looking Glass
Preview
Although the Fourier transform has been the mainstay of transform-based
image processing since the late 1950s, a more recent transformation, called the
wavelet transform, is now making it even easier to compress, transmit, and an-
alyze many images. Unlike the Fourier transform, whose basis functions are si-
nusoids, wavelet transforms are based on small waves, called wavelets, of
varying frequency and limited duration. This allows them to provide the equiv-
alent of a musical score for an image, revealing not only what notes (or fre-
quencies) to play but also when to play them. Fourier transforms, on the other
hand, provide only the notes or frequency information; temporal information
is lost in the transformation process.
In 1987, wavelets were first shown to be the foundation of a powerful new
approach to signal processing and analysis called multiresolution theory (Mallat
[1987]). Multiresolution theory incorporates and unifies techniques from a vari-
ety of disciplines, including subband coding from signal processing, quadrature
mirror filtering from digital speech recognition, and pyramidal image processing.
As its name implies, multiresolution theory is concerned with the representation
and analysis of signals (or images) at more than one resolution. The appeal of
such an approach is obvious—features that might go undetected at one resolu-
tion may be easy to detect at another. Although the imaging community’s inter-
est in multiresolution analysis was limited until the late 1980s, it is now difficult to
keep up with the number of papers, theses, and books devoted to the subject.
461
462 Chapter 7 ■ Wavelets and Multiresolution Processing
7.1 Background
When we look at images, generally we see connected regions of similar texture
and intensity levels that combine to form objects. If the objects are small in
size or low in contrast, we normally examine them at high resolutions; if they
are large in size or high in contrast, a coarse view is all that is required. If both
small and large objects—or low- and high-contrast objects—are present simul-
taneously, it can be advantageous to study them at several resolutions. This, of
course, is the fundamental motivation for multiresolution processing.
From a mathematical viewpoint, images are two-dimensional arrays of inten-
Local histograms are sity values with locally varying statistics that result from different combinations
histograms of the pixels
in a neighborhood (see
of abrupt features like edges and contrasting homogeneous regions.As illustrated
Section 3.3.3). in Fig. 7.1—an image that will be examined repeatedly in the remainder of the
FIGURE 7.1
An image and its
local histogram
variations.
7.1 ■ Background 463
1 1 1 4
N2 ¢ 1 + 1
+ 2
+Á+ P
≤ … N2
(4) (4) (4) 3
Figure 7.2(b) shows a simple system for constructing two intimately related
image pyramids. The Level j - 1 approximation output provides the images
Level 0 (apex)
a
11
b
22 Level 1
FIGURE 7.2
44 Level 2
(a) An image
pyramid. (b) A
simple system for
Level J 1 creating
N/ 2 N/ 2
approximation
Level J (base) and prediction
NN
residual pyramids.
Downsampler
(rows and columns)
Approximation Level j 1
2T
filter approximation
2c Upsampler
(rows and columns)
Interpolation
filter
Prediction
Level j
Level j
prediction
input image
residual
464 Chapter 7 ■ Wavelets and Multiresolution Processing
■ Figure 7.3 shows both an approximation pyramid and a prediction residual EXAMPLE 7.1:
pyramid for the vase of Fig. 7.1. A lowpass Gaussian smoothing filter (see Approximation
and prediction
Section 4.7.4) was used to produce the four-level approximation pyramid in
residual pyramids.
Fig. 7.3(a). As you can see, the resulting pyramid contains the original
512 * 512 resolution image (at its base) and three low-resolution approxima-
tions (of resolution 256 * 256, 128 * 128, and 64 * 64). Thus, P is 3 and levels
9, 8, 7, and 6 out of a possible log 2 (512) + 1 or 10 levels are present. Note the
reduction in detail that accompanies the lower resolutions of the pyramid. The
level 6 (i.e., 64 * 64) approximation image is suitable for locating the window
stiles (i.e., the window pane framing), for example, but not for finding the stems
of the plant. In general, the lower-resolution levels of a pyramid can be used for
the analysis of large structures or overall image context; the high-resolution im-
ages are appropriate for analyzing individual object characteristics. Such a
coarse-to-fine analysis strategy is particularly useful in pattern recognition.
A bilinear interpolation filter was used to produce the prediction residual
pyramid in Fig. 7.3(b). In the absence of quantization error, the resulting predic-
tion residual pyramid can be used to generate the complementary approxima-
tion pyramid in Fig. 7.3(a), including the original image, without error. To do so,
we begin with the level 6 64 * 64 approximation image (the only approxima-
tion image in the prediction residual pyramid), predict the level 7 128 * 128 res-
olution approximation (by upsampling and filtering), and add the level 7
prediction residual. This process is repeated using successively computed ap-
proximation images until the original 512 * 512 image is generated. Note that
the prediction residual histogram in Fig. 7.3(b) is highly peaked around zero; the
approximation histogram in Fig. 7.3(a) is not. Unlike approximation images, pre-
diction residual images can be highly compressed by assigning fewer bits to the
more probable values (see the variable-length codes of Section 8.2.1). Finally, we
note that the prediction residuals in Fig. 7.3(b) are scaled to make small predic-
tion errors more visible; the prediction residual histogram, however, is based on
the original residual values, with level 128 representing zero error. ■
466 Chapter 7 ■ Wavelets and Multiresolution Processing
a
b
FIGURE 7.3
Two image
pyramids and
their histograms:
(a) an
approximation
pyramid;
(b) a prediction
residual pyramid.
The approximation
pyramid in (a) is called a
Gaussian pyramid
because a Gaussian filter
was used to construct it.
The prediction residual
pyramid in (b) is often
called a Laplacian
pyramid; note the
similarity in appearance
with the Laplacian fil-
tered images in Chapter 3.
o
f(0) for n = 2
f(n - 2) = d
f(1) for n = 2 + 1 = 3
o
As the grayed annotations in Fig. 7.4(a) indicate, input sequence f(n) =
f(n - 0) and the K - 1 delayed sequences at the outputs of the unit delays,
denoted f(n - 1), f(n - 2), Á , f(n - K + 1), are multiplied by constants
h(0), h(1), Á , h(K - 1), respectively, and summed to produce the filtered
output sequence
q If the coefficients of the
fN(n) = aqh(k)f(n - k)
filter in Fig. 7.4(a) are
indexed using values of n
k=-
between 0 and K - 1 (as
(7.1-3) we have done), the limits
= f(n) h(n) on the sum in Eq. (7.1-3)
can be reduced to 0 to
where denotes convolution. Note that—except for a change in variables— K - 1 [like Eq. (4.4-10)].
Eq. (7.1-3) is equivalent to the discrete convolution defined in Eq. (4.4-10) of
Chapter 4. The K multiplication constants in Fig. 7.4(a) and Eq. (7.1-3) are
1 1
h(1)
Input sequence f (n) (n)
h(2)
Impulse response h(n)
h(0)
h(K 1)
h(3)
0 0
...
h(4)
1 1
1 0 1 2 . . . ... K1 1 0 1 2 . . . ... K1
n n
a
b c
FIGURE 7.4 (a) A digital filter; (b) a unit discrete impulse sequence; and (c) the impulse response of the filter.
468 Chapter 7 ■ Wavelets and Multiresolution Processing
called filter coefficients. Each coefficient defines a filter tap, which can be
thought of as the components needed to compute one term of the sum in Eq.
(7.1-3), and the filter is said to be of order K.
If the input to the filter of Fig. 7.4(a) is the unit discrete impulse of
Fig. 7.4(b) and Section 4.2.3, Eq. (7.1-3) becomes
q
fN(n) = a h(k)d(n - k)
k = -q (7.1-4)
= h(n)
That is, by substituting d(n) for input f(n) in Eq. (7.1-3) and making use of
the sifting property of the unit discrete impulse as defined in Eq. (4.2-13), we
find that the impulse response of the filter in Fig. 7.4(a) is the K-element se-
quence of filter coefficients that define the filter. Physically, the unit impulse
is shifted from left to right across the top of the filter (from one unit delay to
the next), producing an output that assumes the value of the coefficient at
the location of the delayed impulse. Because there are K coefficients, the im-
pulse response is of length K and the filter is called a finite impulse response
(FIR) filter.
In the remainder of the Figure 7.5 shows the impulse responses of six functionally related filters. Fil-
chapter, “filter h(n)” will
be used to refer to the ter h2(n) in Fig. 7.5(b) is a sign-reversed (i.e., reflected about the horizontal
filter whose impulse axis) version of h1(n) in Fig. 7.5(a). That is,
response is h(n).
1 1 1
h1(n) h2(n) h1(n) h3(n) h1(n)
0 0 0
1 1 1
. . . 3 21 0 1 2 3 4 5 6 7 . . . . . . 3 21 0 1 2 3 4 5 6 7 . . . . . . 3 21 0 1 2 3 4 5 6 7 . . .
n n n
1 1 1
h4(n) h1(K 1 n) h5(n) (1)nh1(n) h6(n) (1)nh1(K 1 n)
0 0 0
1 1 1
. . . 3 21 0 1 2 3 4 5 6 7 . . . . . . 3 21 0 1 2 3 4 5 6 7 . . . . . . 3 21 0 1 2 3 4 5 6 7 . . .
n n n
a b c
d e f
FIGURE 7.5 Six functionally related filter impulse responses: (a) reference response; (b) sign reversal;
(c) and (d) order reversal (differing by the delay introduced); (e) modulation; and (f) order reversal and
modulation.
7.1 ■ Background 469
Filters h3(n) and h4(n) in Figs. 7.5(c) and (d) are order-reversed versions of Order reversal is often
called time reversal when
h1(n): the input sequence is a
sampled analog signal.
h3(n) = h1(-n) (7.1-6)
h4(n) = h1(K - 1 - n) (7.1-7)
Filter h3(n) is a reflection of h1(n) about the vertical axis; filter h4(n) is a re-
flected and translated (i.e., shifted) version of h1(n). Neglecting translation,
the responses of the two filters are identical. Filter h5(n) in Fig. 7.5(e), which is
defined as
h5(n) = (-1)nh1(n) (7.1-8)
This sequence is included to illustrate the fact that sign reversal, order rever-
sal, and modulation are sometimes combined in the specification of the rela-
tionship between two filters.
With this brief introduction to digital signal filtering, consider the two-band
subband coding and decoding system in Fig. 7.6(a). As indicated in the figure,
A filter bank is a collec-
the system is composed of two filter banks, each containing two FIR filters of tion of two or more filters.
the type shown in Fig. 7.4(a). Note that each of the four FIR filters is depicted
flp(n) a
b
h0(n) 2T 2c g0(n)
FIGURE 7.6
(a) A two-band
f(n) Analysis filter bank Synthesis filter bank fˆ(n) subband coding
and decoding
system, and (b) its
h1(n) 2T 2c g1(n)
spectrum splitting
properties.
fhp(n)
H0() H1()
0 / 2
470 Chapter 7 ■ Wavelets and Multiresolution Processing
as a single block in Fig. 7.6(a), with the impulse response of each filter (and the
convolution symbol) written inside it. The analysis filter bank, which includes
filters h0 (n) and h1(n), is used to break input sequence f(n) into two half-
length sequences flp(n) and fhp(n), the subbands that represent the input. Note
that filters h0 (n) and h1(n) are half-band filters whose idealized transfer char-
acteristics, H0 and H1, are shown in Fig. 7.6(b). Filter h0 (n) is a lowpass filter
whose output, subband flp(n), is called an approximation of f(n); filter h1(n) is
a highpass filter whose output, subband fhp (n), is called the high frequency or
detail part of f(n). Synthesis bank filters g0 (n) and g1 (n) combine flp(n) and
fhp(n) to produce fN(n). The goal in subband coding is to select h0 (n), h1(n),
g0 (n), and g1 (n) so that fN(n) = f(n). That is, so that the input and output of the
subband coding and decoding system are identical. When this is accomplished,
the resulting system is said to employ perfect reconstruction filters.
By real-coefficient, we There are many two-band, real-coefficient, FIR, perfect reconstruction fil-
mean that the filter
coefficients are real (not ter banks described in the filter bank literature. In all of them, the synthesis fil-
complex) numbers. ters are modulated versions of the analysis filters—with one (and only one)
synthesis filter being sign reversed as well. For perfect reconstruction, the im-
pulse responses of the synthesis and analysis filters must be related in one of
the following two ways:
Equations (7.1-10) g0 (n) = (-1)nh1(n)
through (7.1-14) are (7.1-10)
described in detail in the
filter bank literature (see, g1 (n) = (-1)n + 1h0 (n)
for example, Vetterli and
Kovacevic [1995]). or
Here, 8hi (2n - k), gj (k)9 denotes the inner product of hi (2n - k) and gj (k).†
When i is not equal to j, the inner product is 0; when i and j are equal, the
product is the unit discrete impulse function, d(n). Biorthogonality will be con-
sidered again in Section 7.2.1.
Of special interest in subband coding—and in the development of the fast
wavelet transform of Section 7.4—are filters that move beyond biorthogonality
and require
The vector inner product of sequences f1 (n) and f2 (n) is 8f1, f29 = a f*1(n)f2 (n), where the * denotes
†
the complex conjugate operation. If f1 (n) and f2 (n) are real, 8f1, f29 = 8f2, f19.
n
7.1 ■ Background 471
where the subscript on Keven is used to indicate that the number of filter coef-
ficients must be divisible by 2 (i.e., an even number). As Eq. (7.1-14) indicates,
synthesis filter g1 is related to g0 by order reversal and modulation. In addi-
tion, both h0 and h1 are order-reversed versions of synthesis filters, g0 and g1,
respectively. Thus, an orthonormal filter bank can be developed around the
impulse response of a single filter, called the prototype; the remaining filters
can be computed from the specified prototype’s impulse response. For
biorthogonal filter banks, two prototypes are required; the remaining filters
can be computed via Eq. (7.1-10) or (7.1-11). The generation of useful proto-
type filters, whether orthonormal or biorthogonal, is beyond the scope of this
chapter. We simply use filters that have been presented in the literature and
provide references for further study.
Before concluding the section with a 2-D subband coding example, we note
that 1-D orthonormal and biorthogonal filters can be used as 2-D separable
filters for the processing of images. As can be seen in Fig. 7.7, the separable fil-
ters are first applied in one dimension (e.g., vertically) and then in the other
(e.g., horizontally) in the manner introduced in Section 2.6.7. Moreover, down-
sampling is performed in two stages—once before the second filtering opera-
tion to reduce the overall number of computations. The resulting filtered
FIGURE 7.7
h0 (n) 2T a(m,n) A two-
Columns
dimensional, four-
(along n) band filter bank
h0 (m) 2T for subband
Rows image coding.
(along m) h1 (n) 2T dV(m,n)
f(m,n) Columns
h0 (n) 2T dH(m,n)
Columns
h1 (m) 2T
Rows
h1 (n) 2T dD(m,n)
Columns
472 Chapter 7 ■ Wavelets and Multiresolution Processing
outputs, denoted a(m, n), dV(m, n), d H(m, n), and dD(m, n) in Fig. 7.7, are
called the approximation, vertical detail, horizontal detail, and diagonal detail
subbands of the input image, respectively. These subbands can be split into
four smaller subbands, which can be split again, and so on—a property that
will be described in greater detail in Section 7.4.
EXAMPLE 7.2: ■ Figure 7.8 shows the impulse responses of four 8-tap orthonormal filters.
A four-band The coefficients of prototype synthesis filter g0 (n) for 0 … n … 7 [in Fig. 7.8(c)]
subband coding of
are defined in Table 7.1 (Daubechies [1992]). The coefficients of the remaining
the vase in Fig. 7.1.
orthonormal filters can be computed using Eq. (7.1-14). With the help of Fig.
7.5, note (by visual inspection) the cross modulation of the analysis and synthe-
sis filters in Fig. 7.8. It is relatively easy to show numerically that the filters are
TABLE 7.1
n g0(n)
Daubechies 8-tap
orthonormal filter 0 0.23037781
coefficients for 1 0.71484657
g0(n) (Daubechies 2 0.63088076
[1992]). 3 -0.02798376
4 -0.18703481
5 0.03084138
6 0.03288301
7 -0.01059740
a b h0(n) h1(n)
c d 1 1
FIGURE 7.8
0.5 0.5
The impulse
responses of four
8-tap Daubechies 0 0
orthonormal
filters. See 0.5 0.5
Table 7.1 for the
values of g0 (n) for 1 n 1 n
0 … n … 7. 0 2 4 6 8 0 2 4 6 8
g0 (n) g1(n)
1 1
0.5 0.5
0 0
0.5 0.5
1 n 1 n
0 2 4 6 8 0 2 4 6 8
7.1 ■ Background 473
a b
c d
FIGURE 7.9
A four-band split
of the vase in
Fig. 7.1 using the
subband coding
system of Fig. 7.7.
The four
subbands that
result are the
(a) approximation,
(b) horizontal
detail, (c) vertical
detail, and
(d) diagonal detail
subbands.
both biorthogonal (they satisfy Eq. 7.1-12) and orthonormal (they satisfy Eq. 7.1-
13). As a result, the Daubechies 8-tap filters in Fig. 7.8 support error-free recon-
struction of the decomposed input.
A four-band split of the 512 * 512 image of a vase in Fig. 7.1, based on the
filters in Fig. 7.8, is shown in Fig. 7.9. Each quadrant of this image is a subband
of size 256 * 256. Beginning with the upper-left corner and proceeding in a
clockwise manner, the four quadrants contain approximation subband a, hori-
zontal detail subband d H, diagonal detail subband dD, and vertical detail sub-
band dV, respectively. All subbands, except the approximation subband in
Fig. 7.9(a), have been scaled to make their underlying structure more visible.
See Section 4.5.4 for
Note the visual effects of aliasing that are present in Figs. 7.9(b) and (c)—the dH more on aliasing.
and dV subbands. The wavy lines in the window area are due to the downsam-
pling of a barely discernable window screen in Fig. 7.1. Despite the aliasing, the
original image can be reconstructed from the subbands in Fig. 7.9 without
error. The required synthesis filters, g0 (n) and g1 (n), are determined from
Table 7.1 and Eq. (7.1-14), and incorporated into a filter bank that roughly
mirrors the system in Fig. 7.7. In the new filter bank, filters hi (n) for i = 50, 16
are replaced by their gi (n) counterparts, and upsamplers and summers are
added. ■
474 Chapter 7 ■ Wavelets and Multiresolution Processing
T = HFH T (7.1-15)
1
h0 (z) = h00 (z) = , z H [0, 1] (7.1-16)
1N
and
1 1 1
H2 = B R (7.1-18)
12 1 -1
7.1 ■ Background 475
k p q
0 0 0
1 0 1
2 1 1
3 1 2
1 1 1 1
1 1 1 -1 -1
H4 = D T (7.1-19)
14 1 2 -12 0 0
0 0 12 -12
Our principal interest in the Haar transform is that the rows of H 2 can be used
to define the analysis filters, h0 (n) and h1(n), of a 2-tap perfect reconstruction
filter bank (see the previous section), as well as the scaling and wavelet vectors
(defined in Sections 7.2.2 and 7.2.3, respectively) of the simplest and oldest
wavelet transform (see Example 7.10 in Section 7.4). Rather than concluding
the section with the computation of a Haar transform, we close with an exam-
ple that illustrates the influence of the decomposition methods that have been
considered to this point on the methods that will be developed in the remainder
of the chapter.
■ Figure 7.10(a) shows a decomposition of the 512 * 512 image in Fig. 7.1 EXAMPLE 7.3:
that combines the key features of pyramid coding, subband coding, and the Haar functions in
Haar transform (the three techniques we have discussed so far). Called the a discrete wavelet
transform.
discrete wavelet transform (and developed later in the chapter), the represen-
tation is characterized by the following important features:
1. With the exception of the subimage in the upper-left corner of Fig. 7.10(a),
the local histograms are very similar. Many of the pixels are close to zero.
Because the subimages (except for the subimage in the upper-left corner)
have been scaled to make their underlying structure more visible, the dis-
played histograms are peaked at intensity 128 (the zeroes have been
scaled to mid-gray). The large number of zeroes in the decomposition
makes the image an excellent candidate for compression (see Chapter 8).
2. In a manner that is similar to the way in which the levels of the prediction
residual pyramid of Fig. 7.3(b) were used to create approximation images
of differing resolutions, the subimages in Fig. 7.10(a) can be used to con-
struct both coarse and fine resolution approximations of the original
vase image in Fig. 7.1. Figures 7.10(b) through (d), which are of size
476 Chapter 7 ■ Wavelets and Multiresolution Processing
a
b c d
FIGURE 7.10
(a) A discrete
wavelet transform
using Haar H 2
basis functions. Its
local histogram
variations are also
shown. (b)–(d)
Several different
approximations
(64 * 64,
128 * 128, and
256 * 256) that
can be obtained
from (a).
64 * 64, 128 * 128, and 256 * 256, respectively, were generated from
the subimages in Fig. 7.10(a). A perfect 512 * 512 reconstruction of the
original image is also possible.
3. Like the subband coding decomposition in Fig. 7.9, a simple real-coefficient,
FIR filter bank of the form given in Fig. 7.7 was used to produce Fig. 7.10(a).
After the generation of a four subband image like that of Fig. 7.9, the
256 * 256 approximation subband was decomposed and replaced by four
128 * 128 subbands (using the same filter bank), and the resulting approx-
imation subband was again decomposed and replaced by four 64 * 64 sub-
bands. This process produced the unique arrangement of subimages that
7.2 ■ Multiresolution Expansions 477
To say that f(x) H V means that f(x) is in the closed span of E wk(x) F and can
be written in the form of Eq. (7.2-1).
478 Chapter 7 ■ Wavelets and Multiresolution Processing
For any function space V and corresponding expansion set E wk(x) F , there is a
set of dual functions denoted E wk(x) F that can be used to compute the ak coeffi-
'
cients of Eq. (7.2-1) for any f(x) H V. These coefficients are computed by taking
'
the integral inner products† of the dual wk(x) and function f(x). That is,
ak = 8wk(x), f(x)9 =
' '
w*k(x)f(x) dx (7.2-3)
L
where the * denotes the complex conjugate operation. Depending on the or-
thogonality of the expansion set, this computation assumes one of three possi-
ble forms. Problem 7.10 at the end of the chapter illustrates the three cases
using vectors in two-dimensional Euclidean space.
The ak are computed as the inner products of the basis functions and f(x).
Case 2: If the expansion functions are not orthonormal, but are an orthog-
onal basis for V, then
and the basis functions and their duals are called biorthogonal. The ak are
computed using Eq. (7.2-3), and the biorthogonal basis and its dual are
such that
The integral inner product of two real or complex-valued functions f(x) and g(x) is 8f(x), g(x)9 =
†
f*(x)g(x) dx. If f(x) is real, f*(x) = f(x) and 8f(x), g(x)9 = f(x)g(x) dx.
L L
The norm of f(x), denoted 7f(x)7, is defined as the square root of the absolute value of the inner prod-
‡
8wk(x), f(x)9wk(x)
1
Aa
f(x) = (7.2-9)
k
Except for the A-1 term, which is a measure of the frame’s redundancy,
this is identical to the expression obtained by substituting Eq. (7.2-5) (for
orthonormal bases) into Eqs. (7.2-1).
7.2.2 Scaling Functions
Consider the set of expansion functions composed of integer translations and
binary scalings of the real, square-integrable function w(x); this is the set
E wj, k(x) F , where
wj, k(x) = 2j>2w(2jx - k) (7.2-10)
for all j, k H Z and w(x) H L2(R).† Here, k determines the position of wj, k(x)
along the x-axis, and j determines the width of wj, k(x)—that is, how broad or
narrow it is along the x-axis. The term 2 j>2 controls the amplitude of the func-
tion. Because the shape of wj, k(x) changes with j, w(x) is called a scaling function.
By choosing w(x) properly, E wj, k(x) F can be made to span L2(R), which is the
set of all measurable, square-integrable functions.
If we restrict j in Eq. (7.2-10) to a specific value, say j = j0 , the resulting
expansion set, E wj0, k(x) F , is a subset of E wj, k(x) F that spans a subspace of L2(R).
Using the notation of the previous section, we can define that subspace as
That is, Vj0 is the span of wj0 , k(x) over k. If f(x) H Vj0, we can write
As will be seen in the following example, increasing j increases the size of Vj,
allowing functions with smaller variations or finer detail to be included in the
subspace. This is a consequence of the fact that, as j increases, the wj, k(x) that
are used to represent the subspace functions become narrower and separated
by smaller changes in x.
†
The notation L2(R), where R is the set of real numbers, denotes the set of measurable, square-integrable,
one-dimensional functions; Z is the set of integers.
480 Chapter 7 ■ Wavelets and Multiresolution Processing
EXAMPLE 7.4: ■ Consider the unit-height, unit-width scaling function (Haar [1910])
The Haar scaling
function.
1 0 … x 6 1
w(x) = b (7.2-14)
0 otherwise
Figures 7.11(a) through (d) show four of the many expansion functions that
can be generated by substituting this pulse-shaped scaling function into
Eq. (7.2-10). Note that the expansion functions for j = 1 in Figs. 7.11(c) and
(d) are half as wide as those for j = 0 in Figs. 7.11(a) and (b). For a given in-
terval on x, we can define twice as many V1 scaling functions as V0 scaling func-
tions (e.g., w1, 0 and w1, 1 of V1 versus w0, 0 of V0 for the interval 0 … x 6 1).
Figure 7.11(e) shows a member of subspace V1. This function does not be-
long to V0, because the V0 expansion functions in 7.11(a) and (b) are too
coarse to represent it. Higher-resolution functions like those in 7.11(c) and (d)
x x
0 1 2 3 0 1 2 3
1 1
0 0
x x
0 1 2 3 0 1 2 3
1 1, 1 1
w1, 1/ 2
0.25 1, 4
0 0
0.5 1, 0 w1,0/ 2
x x
0 1 2 3 0 1 2 3
7.2 ■ Multiresolution Expansions 481
are required. They can be used, as shown in (e), to represent the function by
the three-term expansion
f(x) = 0.5w1, 0 (x) + w1, 1 (x) - 0.25w1, 4 (x)
To conclude the example, Fig. 7.11(f) illustrates the decomposition of
w0, 0 (x) as a sum of V1 expansion functions. In a similar manner, any V0 expan-
sion function can be decomposed using
1 1
w0, k(x) = w1, 2k (x) + w1, 2k + 1 (x)
12 12
Thus, if f(x) is an element of V0, it is also an element of V1. This is because all
V0 expansion functions are contained in V1. Mathematically, we write that V0 is
a subspace of V1, denoted V0 ( V1. ■
The simple scaling function in the preceding example obeys the four funda-
mental requirements of multiresolution analysis (Mallat [1989a]):
MRA Requirement 1: The scaling function is orthogonal to its integer
translates.
This is easy to see in the case of the Haar function, because whenever it has a
value of 1, its integer translates are 0, so that the product of the two is 0. The
Haar scaling function is said to have compact support, which means that it is
0 everywhere outside a finite interval called the support. In fact, the width of
the support is 1; it is 0 outside the half open interval [0, 1). It should be noted
that the requirement for orthogonal integer translates becomes harder to
satisfy as the width of support of the scaling function becomes larger than 1.
MRA Requirement 2: The subspaces spanned by the scaling function at low
scales are nested within those spanned at higher scales.
As can be seen in Fig. 7.12, subspaces containing high-resolution functions
must also contain all lower resolution functions. That is,
V- q ( Á ( V-1 ( V0 ( V1 ( V2 ( Á ( Vq (7.2-15)
Moreover, the subspaces satisfy the intuitive condition that if f(x) H Vj, then
f(2x) H Vj + 1. The fact that the Haar scaling function meets this requirement
V0 V1 V2 FIGURE 7.12
The nested
function spaces
spanned by a
scaling function.
V0
482 Chapter 7 ■ Wavelets and Multiresolution Processing
should not be taken to indicate that any function with a support width of 1
automatically satisfies the condition. It is left as an exercise for the reader
to show that the equally simple function
1 0.25 … x 6 0.75
w(x) = b
0 elsewhere
is not a valid scaling function for a multiresolution analysis (see Problem 7.11).
MRA Requirement 3: The only function that is common to all Vj is f(x) = 0.
If we consider the coarsest possible expansion functions (i.e., j = - q ),
the only representable function is the function of no information. That is,
V- q = 506 (7.2-16)
Vq = E L2(R) F (7.2-17)
where the index of summation has been changed to n for clarity. Substituting
The an are changed to
hw(n) because they are
for wj + 1, n (x) from Eq. (7.2-10) and changing variable an to hw(n), this becomes
used later (see Section
7.4) as filter bank
coefficients. wj, k (x) = a hw(n)2 (j + 1)>2w(2 j + 1x - n)
n
Because w(x) = w0, 0 (x), both j and k can be set to 0 to obtain the simpler non-
subscripted expression
The hw(n) coefficients in this recursive equation are called scaling function co-
efficients; hw is referred to as a scaling vector. Equation (7.2-18) is fundamental
to multiresolution analysis and is called the refinement equation, the MRA
equation, or the dilation equation. It states that the expansion functions of any
subspace can be built from double-resolution copies of themselves—that is,
from expansion functions of the next higher resolution space. The choice of a
reference subspace, V0, is arbitrary.
7.2 ■ Multiresolution Expansions 483
■ The scaling function coefficients for the Haar function of Eq. (7.2-14) EXAMPLE 7.5:
are hw(0) = hw(1) = 1> 12, the first row of matrix H 2 in Eq. (7.1-18). Thus, Haar scaling
function
Eq. (7.2-18) yields
coefficients.
C 12w(2x) D + C 12w(2x - 1) D
1 1
w(x) =
12 12
This decomposition was illustrated graphically for w0, 0 (x) in Fig. 7.11(f), where
the bracketed terms of the preceding expression are seen to be w1, 0 (x) and
w1, 1 (x). Additional simplification yields w(x) = w(2x) + w(2x - 1). ■
for all k H Z that span the Wj spaces in the figure. As with scaling functions, we
write
Wj = Span E cj, k (x) F (7.2-20)
k
and note that if f(x) H Wj,
L2(R) = V0 { W0 { W1 { Á (7.2-24)
or
L2(R) = V1 { W1 { W2 { Á (7.2-25)
or even
where the hc(n) are called the wavelet function coefficients and hc is the
wavelet vector. Using the condition that wavelets span the orthogonal comple-
ment spaces in Fig. 7.13 and that integer wavelet translates are orthogonal, it
can be shown that hc(n) is related to hw(n) by (see, for example, Burrus,
Gopinath, and Guo [1998])
Note the similarity of this result and Eq. (7.1-14), the relationship governing
the impulse responses of orthonormal subband coding and decoding filters.
EXAMPLE 7.6: ■ In the previous example, the Haar scaling vector was defined as
The Haar wavelet hw(0) = hw(1) = 1> 12. Using Eq. (7.2-29), the corresponding wavelet
function vector is hc(0) = (-1)0hw(1 - 0) = 1> 12 and hc(1) = (-1)1hw(1 - 1)
coefficients.
= -1> 12. Note that these coefficients correspond to the second row of ma-
trix H2 in Eq. (7.1-18). Substituting these values into Eq. (7.2-28), we get
7.2 ■ Multiresolution Expansions 485
c(x) = w(2x) - w(2x - 1), which is plotted in Fig. 7.14(a). Thus, the Haar
wavelet function is
1 0 … x 6 0.5
c(x) = c -1 0.5 … x 6 1 (7.2-30)
0 elsewhere
Using Eq. (7.2-19), we can now generate the universe of scaled and translated
Haar wavelets.Two such wavelets, c0, 2 (x) and c1, 0 (x), are plotted in Figs. 7.14(b)
and (c), respectively. Note that wavelet c1, 0 (x) for space W1 is narrower than
c0, 2 (x) for W0; it can be used to represent finer detail.
Figure 7.14(d) shows a function of subspace V1 that is not in subspace V0. This
function was considered in an earlier example [see Fig. 7.11(e)]. Although the
function cannot be represented accurately in V0, Eq. (7.2-22) indicates that it can
be expanded using V0 and W0 expansion functions. The resulting expansion is
f(x) = fa (x) + fd (x)
1 1
0 0
1 1
x x
0 1 2 3 0 1 2 3
fa(x) H V0 fd (x) H W0
3 2/4 w0, 0
1 1 2/8 c0, 2
0 0
x x
0 1 2 3 0 1 2 3
486 Chapter 7 ■ Wavelets and Multiresolution Processing
where
312 12
fa (x) = w0, 0 (x) - w (x)
4 8 0, 2
and
- 12 12
fd (x) = c0, 0 (x) - c (x)
4 8 0, 2
Here, fa (x) is an approximation of f(x) using V0 scaling functions, while fd (x)
is the difference f(x) - fa (x) as a sum of W0 wavelets. The two expansions,
which are shown in Figs. 7.14(e) and (f), divide f(x) in a manner similar to a
lowpass and highpass filter as discussed in connection with Fig. 7.6. The low
frequencies of f(x) are captured in fa (x)—it assumes the average value of
f(x) in each integer interval—while the high-frequency details are encoded in
fd (x). ■
q
f(x) = a cj0(k)wj0, k (x) + a a dj(k)cj, k (x) (7.3-1)
k j = j0 k
where j0 is an arbitrary starting scale and the cj0(k) and dj (k) are relabeled ak
from Eqs. (7.2-12) and (7.2-21), respectively. The cj0(k) are normally called
approximation and/or scaling coefficients; the dj (k) are referred to as detail
and/or wavelet coefficients. This is because the first sum in Eq. (7.3-1) uses scal-
ing functions to provide an approximation of f(x) at scale j0 [unless f(x) H Vj0
so that the sum of the scaling functions is equal to f(x)]. For each higher scale
j Ú j0 in the second sum, a finer resolution function—a sum of wavelets—is
added to the approximation to provide increasing detail. If the expansion
7.3 ■ Wavelet Transforms in One Dimension 487
functions form an orthonormal basis or tight frame, which is often the case, the
expansion coefficients are calculated—based on Eqs. (7.2-5) and (7.2-9)—as
cj0(k) = 8f(x), wj0, k (x)9 = f(x)wj0, k (x) dx (7.3-2) Because f is real, no con-
L jugates are needed in the
inner products of Eqs.
and (7.3-2) and (7.3-3).
shown in Fig. 7.15(a). Using Haar wavelets—see Eqs. (7.2-14) and (7.2-30)—
and a starting scale j0 = 0, Eqs. (7.3-2) and (7.3-3) can be used to compute the
following expansion coefficients:
` =
1 1
x3 1 1
c0(0) = x 2w0,0 (x) dx = x2 dx =
L0 L0 3 0 3
1 0.5 1
1
d0(0) = x2c0,0 (x) dx = x 2 dx - x2 dx = -
L0 L0 L0.5 4
0.25 0.5
1
12
d1(0) = x2c1,0 (x) dx = x 2 12 dx - x 2 12 dx = -
L0 L0 L0.25 32
1 0.75 1
312
d1(1) = x 2c1,1 (x) dx = x 2 12 dx - x2 12 dx = -
L0 L0.5 L0.75 32
Substituting these values into Eq. (7.3-1), we get the wavelet series expansion
12
w0,0(x) + c - c0,0(x) d + c - d
1 1 312 c (x) + Á
y = c1,0(x) - 1,1
3
¯˘˚ ˙ ¯˚ 4
˚˘˚˙ 32
¯˚˚˚˚ 32
˚˚˘˚˚˚˚˚˚˙
¯˚˚V0 ˚˚˚˘˚˚˚˚˙ W0 W1
V1 = V0 { W0
¯˚˚˚˚˚˚˚˚˚˚˚˚˘˚˚˚˚˚˚˚˚˚˚˙
V2 = V1 { W1 = V0 { W0 { W1
488 Chapter 7 ■ Wavelets and Multiresolution Processing
a b 1 1
c d y x2 V0
1/ 3 w0, 0
e f
0.5 0.5
FIGURE 7.15 1/3
A wavelet series
0 0
expansion of
y = x2 using Haar
wavelets. 0.5 x 0.5 x
0 0.25 0.5 0.75 1 0 0.25 0.5 0.75 1
1 1
W0 V1
7/12
0.5 1/4 c0, 0
1/4
1/12
0
1/4
0.5 0.5 x
x
0 0.25 0.5 0.75 1 0 0.25 0.5 0.75 1
1 1
W1 37/48 V2
3 2/ 32 c1, 1
2/ 32 c1, 0
19/48
3/16
7/48
1/16 1/48
1/16
3/16
0.5
x x
0 0.25 0.5 0.75 1 0 0.25 0.5 0.75 1
The first term in this expansion uses c0 (0) to generate a subspace V0 approxima-
tion of the function being expanded. This approximation is shown in Fig. 7.15(b)
and is the average value of the original function. The second term uses d0 (0) to
refine the approximation by adding a level of detail from subspace W0. The
added detail and resulting V1 approximation are shown in Figs. 7.15(c) and
(d), respectively. Another level of detail is added by the subspace W1 coeffi-
cients d1(0) and d1(1). This additional detail is shown in Fig. 7.15(e), and the
resulting V2 approximation is depicted in 7.15(f). Note that the expansion is
now beginning to resemble the original function. As higher scales (greater lev-
els of detail) are added, the approximation becomes a more precise represen-
tation of the function, realizing it in the limit as j : q . ■
the wavelet series expansion coefficients for f(x) [defined by Eqs. (7.3-2) and
(7.3-3)] become the forward DWT coefficients for sequence f(n):
1
1M a
Ww (j0, k) = f(n)wj0, k (n) (7.3-5)
n
1
1M a
Wc (j, k) = f(n)cj, k (n) for j Ú j0 (7.3-6)
n
The wj0, k (n) and cj, k (n) in these equations are sampled versions of basis func-
tions wj0, k (x) and cj, k (x). For example, wj0, k (n) = wj0, k (xS + n¢xs) for some
xs, ¢xs, and n = 0, 1, 2, Á , M - 1. Thus, we employ M equally spaced sam-
ples over the support of the basis functions (see Example 7.8 below). In accor-
dance with Eq. (7.3-1), the complementary inverse DWT is
q
1 1
f(n) = a
1M k
Ww (j0, k)wj0, k (n) +
1 M ja a Wc (j, k)cj, k (n) (7.3-7)
= j0 k
■ To illustrate the use of Eqs. (7.3-5) through (7.3-7), consider the discrete EXAMPLE 7.8:
function of four points: f(0) = 1, f(1) = 4, f(2) = -3, and f(3) = 0. Because Computing a one-
M = 4, J = 2 and, with j0 = 0, the summations are performed over dimensional
discrete wavelet
x = 0, 1, 2, 3, j = 0, 1, and k = 0 for j = 0 or k = 0, 1 for j = 1. We will use transform.
the Haar scaling and wavelet functions and assume that the four samples of
490 Chapter 7 ■ Wavelets and Multiresolution Processing
f(x) are distributed over the support of the basis functions, which is 1 in width.
Substituting the four samples into Eq. (7.3-5), we find that
1 3
2 na
Ww(0, 0) = f(n)w0, 0 (n)
=0
C1 # 1 + 4 # 1 - 3 # 1 + 0 # 1D = 1
1
=
2
because w0, 0 (n) = 1 for n = 0, 1, 2, 3. Note that we have employed uniformly
spaced samples of the Haar scaling function for j = 0 and k = 0. The values
correspond to the first row of Haar transformation matrix H4 of Section 7.1.3.
Continuing with Eq. (7.3-6) and similarly spaced samples of cj, k (x), which cor-
respond to rows 2, 3, and 4 of H4, we get
C 1 # 1 + 4 # 1 - 3 # (-1) + 0 # (-1) D = 4
1
Wc(0, 0) =
2
C 1 # 12 + 4 # A - 12 B - 3 # 0 + 0 # 0 D = -1.5 12
1
Wc(1, 0) =
2
C 1 # 0 + 4 # 0 - 3 # 12 + 0 # A - 12 B D = -1.5 12
1
Wc(1, 1) =
2
Thus, the discrete wavelet transform of our simple four-sample function rela-
tive to the Haar wavelet and scaling function is E 1, 4, -1.512, -1.512 F ,
where the transform coefficients have been arranged in the order in which
they were computed.
Equation (7.3-7) lets us reconstruct the original function from its transform.
Iterating through its summation indices, we get
C 1 # 1 + 4 # 1 - 1.512 # A 12 B - 1.512 # 0 D = 1
1
f(0) =
2
As in the forward case, uniformly spaced samples of the scaling and wavelet
functions are used in the computation of the inverse. ■
q
Wc(s, t) = f(x)cs,t(x) dx (7.3-8)
L- q
where
1 x - t
cs,t(x) = c¢ ≤ (7.3-9)
1s s
and s and t are called scale and translation parameters, respectively. Given
Wc(s, t), f(x) can be obtained using the inverse continuous wavelet transform
q q
1 cs,t(x)
f(x) = Wc(s, t) dt ds (7.3-10)
Cc L0 L- q s2
where
q
ƒ ° (m) ƒ 2
Cc = dm (7.3-11)
L- q ƒmƒ
and °(m) is the Fourier transform of c(x). Equations (7.3-8) through (7.3-11)
define a reversible transformation as long as the so-called admissibility criterion,
Cc 6 q , is satisfied (Grossman and Morlet [1984]). In most cases, this sim-
ply means that °(0) = 0 and °(m) : 0 as m : q fast enough to make
Cc 6 q .
The preceding equations are reminiscent of their discrete counterparts—
Eqs. (7.2-19), (7.3-1), (7.3-3), (7.3-6), and (7.3-7). The following similarities
should be noted:
1. The continuous translation parameter, t, takes the place of the integer
translation parameter, k.
2. The continuous scale parameter, s, is inversely related to the binary scale
parameter, 2j. This is because s appears in the denominator of
c A (x - t)>s B in Eq. (7.3-9). Thus, wavelets used in continuous transforms
are compressed or reduced in width when 0 6 s 6 1 and dilated or ex-
panded when s 7 1. Wavelet scale and our traditional notion of frequency
are inversely related.
492 Chapter 7 ■ Wavelets and Multiresolution Processing
Its Fourier spectrum, shown in Fig. 7.16(b), reveals the close connection be-
tween scaled wavelets and Fourier frequency bands. The spectrum contains
two broad frequency bands (or peaks) that correspond to the two Gaussian-
like perturbations of the function.
Figure 7.16(c) shows a portion (1 … s … 10 and t … 100) of the CWT of
the function in Fig. 7.16(a) relative to the Mexican hat wavelet. Unlike the
Fourier spectrum in Fig. 7.16(b), it provides both spatial and frequency infor-
mation. Note, for example, that when s = 1, the transform achieves a maxi-
mum at t = 10, which corresponds to the location of the c1, 10 (x) component
of f(x). Because the transform provides an objective measure of the similarity
between f(x) and the wavelets for which it is computed, it is easy to see how it
can be used for feature detection. We simply need wavelets that match the fea-
tures of interest. Similar observations can be drawn from the intensity plot in
Fig. 7.16(d), where the absolute value of the transform ƒ Wc(s, t) ƒ is displayed
as intensities between black and white. Note that the continuous wavelet
transform turns a 1-D function into a 2-D result. ■
7.4 ■ The Fast Wavelet Transform 493
f(x) F(m) a b
1 0.035 c d
FIGURE 7.16
0.03
The continuous
wavelet transform
(c and d) and
Fourier spectrum
(b) of a
continuous 1-D
function (a).
0
0.005
0.4 x 0 m
0 10 80 100 0
20
Wc(s, t)
1
0.8
0.6
0.4
0.2
0 s
0.2
0.4
0.6 10
0.8
10
8 100
6 80
4 60
s 40
2 20 t
1
0 0 0 10 t 80 100
= a hw(n)12w (2 j + 1x - 2k - n)
m
Note that scaling vector hw can be thought of as the “weights” used to expand
w(2jx - k) as a sum of scale j + 1 scaling functions. A similar sequence of
operations—beginning with Eq. (7.2-28)—provides an analogous result for
c(2jx - k). That is,
where scaling vector hw(n) in Eq. (7.4-2) corresponds to wavelet vector hc(n)
in Eq. (7.4-3).
The wavelet series Now consider Eqs. (7.3-2) and (7.3-3) of Section 7.3.1. They define the
expansion coefficients
become the DWT wavelet series expansion coefficients of continuous function f(x). Substituting
coefficient when f is Eq. (7.2-19)—the wavelet defining equation—into Eq. (7.3-3), we get
discrete. Here, we begin
with the series expansion
coefficients to simplify
the derivation; we will be dj (k) = f(x)2 j>2 c(2 jx - k) dx (7.4-4)
able to substitute freely L
from earlier results (like
the scaling and wavelet
function definitions). which, upon replacing c(2jx - k) with the right side of Eq. (7.4-3), becomes
Interchanging the sum and integral and rearranging terms then gives
and note that the detail coefficients at scale j are a function of the approxima-
tion coefficients at scale j + 1. Using Eqs. (7.4-2) and (7.3-2) as the starting
point of a similar derivation involving the wavelet series expansion (and
DWT) approximation coefficients, we find similarly that
Because the cj (k) and dj (k) coefficients of the wavelet series expansion be-
come the Ww(j, k) and Wc(j, k) coefficients of the DWT when f(x) is discrete
(see Section 7.3.2), we can write
7.4 ■ The Fast Wavelet Transform 495
FIGURE 7.17
hc(n) 2T Wc(j, n) An FWT analysis
bank.
Ww( j 1, n)
hw(n) 2T Ww(j, n)
496 Chapter 7 ■ Wavelets and Multiresolution Processing
a
hc(n) 2T Wc(J 1, n)
b
FIGURE 7.18
f (n)
(a) A two-stage or hc(n) 2T Wc(J 2, n)
Ww(J, n)
two-scale FWT
analysis bank and
(b) its frequency hw(n) 2T Ww(J 1, n)
splitting
characteristics.
hw(n) 2T Ww(J 2, n)
|H(v)|
VJ
VJ 1
VJ 2 WJ 2 WJ 1
v
0 p/4 p/2 p
scale. [In accordance with Section 7.2.2, f(x) H VJ, where VJ is the scaling
space in which f(x) resides.] The first filter bank in Fig. 7.18(a) splits the origi-
nal function into a lowpass, approximation component, which corresponds to
scaling coefficients Ww(J - 1, n); and a highpass, detail component, correspond-
ing to coefficients Wc(J - 1, n). This is illustrated graphically in Fig. 7.18(b),
where scaling space VJ is split into wavelet subspace WJ - 1 and scaling subspace
VJ - 1. The spectrum of the original function is split into two half-band compo-
nents. The second filter bank of Fig. 7.18(a) splits the spectrum and subspace
VJ - 1, the lower half-band, into quarter-band subspaces WJ - 2 and VJ - 2 with
corresponding DWT coefficients Wc(J - 2, n) and Ww(J - 2, n), respectively.
The two-stage filter bank of Fig. 7.18(a) is extended easily to any number of
scales. A third filter bank, for example, would operate on the Ww(J - 2, n) co-
efficients, splitting scaling space VJ - 2 into two eighth-band subspaces WJ - 3
and VJ - 3. Normally, we choose 2J samples of f(x) and employ P filter banks
(as in Fig. 7.17) to generate a P-scale FWT at scales J - 1, J - 2, Á , J - P.
The highest scale (i.e., J - 1) coefficients are computed first; the lowest scale
(i.e., J - P) last. If function f(x) is sampled above the Nyquist rate, as is usu-
ally the case, its samples are good approximations of the scaling coefficients at
the sampling resolution and can be used as the starting high-resolution scaling
coefficient inputs. In other words, no wavelet or detail coefficients are needed
at the sampling scale. The highest-resolution scaling functions act as unit dis-
crete impulse functions in Eqs. (7.3-5) and (7.3-6), allowing f(n) to be used as
the scaling (approximation) input to the first two-band filter bank (Odegard,
Gopinath, and Burrus [1992]).
7.4 ■ The Fast Wavelet Transform 497
■ To illustrate the preceding concepts, consider the discrete function f(n) EXAMPLE 7.10:
= 51, 4, -3, 06 from Example 7.8. As in that example, we will compute the Computing a 1-D
transform based on Haar scaling and wavelet functions. Here, however, we will fast wavelet
transform.
not use the basis functions directly, as was done in the DWT of Example 7.8.
Instead, we will use the corresponding scaling and wavelet vectors from
Examples 7.5 and 7.6:
1> 12 n = 0, 1
hw(n) = b (7.4-13)
0 otherwise
and
1> 12 n = 0
hc(n) = c -1> 12 n = 1 (7.4-14)
0 otherwise
These are the functions used to build the FWT filter banks; they provide the filter
coefficients. Note that because Haar scaling and wavelet functions are orthonor-
mal, Eq. (7.1-14) can be used to generate the FWT filter coefficients from a single
prototype filter—like hw(n) in Table 7.2, which corresponds to g0(n) in Eq. (7.1-14):
Since the DWT computed in Example 7.8 was composed of elements
E Ww(0, 0), Wc(0, 0), Wc(1, 0), Wc(1, 1) F , we will compute the corresponding
two-scale FWT for scales j = 50, 16. That is, J = 2 (there are 2J = 22 sam-
ples) and P = 2 (we are working with scales J - 1 = 2 - 1 = 1 and
J - P = 2 - 2 = 0 in that order). The transform will be computed using the
two-stage filter bank of Fig. 7.18(a). Figure 7.19 shows the sequences that re-
sult from the required FWT convolutions and downsamplings. Note that func-
tion f(n) itself is the scaling (approximation) input to the leftmost filter bank.
To compute the Wc(1, k) coefficients that appear at the end of the upper
branch of Fig. 7.19, for example, we first convolve f(n) with hc(-n). As ex-
plained in Section 3.4.2, this requires flipping one of the functions about the ori-
gin, sliding it past the other, and computing the sum of the point-wise product of
the two functions. For sequences 51, 4, -3, 06 and E -1> 12, 1> 12 F , this
produces
where the second term corresponds to index k = 2n = 0. (In Fig. 7.19, under-
lined values represent negative indices, i.e., n 6 0.) When downsampled by
{2.5, 4, 1.5}
{1/ 2, 1/ 2 } 2T
{2.5, 1, 1.5}
FIGURE 7.19 Computing a two-scale fast wavelet transform of sequence 51, 4, -3, 06 using Haar scaling and
wavelet vectors.
taking the even-indexed points, we get Wc(1, k) = E -3> 12, -3> 12 F for
k = 50, 16. Alternatively, we can use Eq. (7.4-12) to compute
= a hc(l - 2k)x(l) `
l k = 0, 1
x(2k + 1) `
1 1
= x(2k) -
12 12 k = 0, 1
As one might expect, a fast inverse transform for the reconstruction of f(n)
from the results of the forward transform can be formulated. Called the
inverse fast wavelet transform (FWT -1), it uses the scaling and wavelet vectors
employed in the forward transform, together with the level j approximation
7.4 ■ The Fast Wavelet Transform 499
FIGURE 7.20
Wc( j, n) 2c hc(n)
The FWT -1
synthesis filter
bank.
WW( j 1, n)
Ww( j, n) 2c hw(n)
FIGURE 7.21
Wc(J 1, n) 2c hc(n)
A two-stage or
two-scale FWT -1
synthesis bank.
Wc(J 2, n) 2c hc(n) Ww(J, n)
Ww(J 1, n)
2c hw(n)
Ww(J 2, n) 2c hw(n)
500 Chapter 7 ■ Wavelets and Multiresolution Processing
EXAMPLE 7.11: ■ Computation of the inverse fast wavelet transform mirrors its forward coun-
Computing a 1-D terpart. Figure 7.22 illustrates the process for the sequence considered in Example
inverse fast
7.10.To begin the calculation, the level 0 approximation and detail coefficients are
upsampled to yield 51, 06 and 54, 06, respectively. Convolution with filters
wavelet
g0(n) = hw(n) = E 1> 12, 1> 12 F g1(n) = hc(n) = E 1> 12, -1> 12 F
transform.
and
produces E 1> 12, 1> 12, 0 F and E 4> 12, -4> 12, 0 F , which when added give
Ww(1, n) = E 5> 12, -3> 12 F . Thus, the level 1 approximation of Fig. 7.22, which
matches the computed approximation in Fig. 7.19, is reconstructed. Continuing in
this manner, f(n) is formed at the right of the second synthesis filter bank. ■
2c {1/ 2, 1/ 2 }
{2.5, 2.5, 1.5,1.5, 0}
{5/ 2, 0, 3/ 2, 0}
Ww(0, 0) {1} 2c {1/ 2, 1/ 2}
{1/ 2, 1/ 2, 0}
{1, 0}
FIGURE 7.22 Computing a two-scale inverse fast wavelet transform of sequence E 1, 4, -1.512, -1.512 F
with Haar scaling and wavelet functions.
Frequency 7.5 ■ Wavelet Transforms in Two Dimensions 501
a b c
FIGURE 7.23 Time-frequency tilings for the basis functions associated with (a) sampled
data, (b) the FFT, and (c) the FWT. Note that the horizontal strips of equal height
rectangles in (c) represent FWT scales.
basis. Each tile is a rectangular region in Figs. 7.23(a) through (c); the height
and width of the region defines the frequency and time characteristics of the
functions that can be represented using the basis function. Note that the stan-
dard time domain basis in Fig. 7.23(a) pinpoints the instants when events occur
but provides no frequency information [the width of each rectangle in Fig. 7.23(a)
should be considered one instant in time]. Thus, to represent a single frequency
sinusoid as an expansion using impulse basis functions, every basis function is
required. The sinusoidal basis in Fig. 7.23(b), on the other hand, pinpoints the
frequencies that are present in events that occur over long periods but pro-
vides no time resolution [the height of each rectangle in Fig. 7.23(b) should be
considered a single frequency]. Thus, the single frequency sinusoid that was
represented by an infinite number of impulse basis functions can be represented
as an expansion involving one sinusoidal basis function. The time and frequency
resolution of the FWT tiles in Fig. 7.23(c) vary, but the area of each tile (rec-
tangle) is the same.At low frequencies, the tiles are shorter (i.e., have better fre-
quency resolution or less ambiguity regarding frequency) but are wider (which
corresponds to poorer time resolution or more ambiguity regarding time). At
high frequencies, tile width is smaller (so the time resolution is improved) and
tile height is greater (which means the frequency resolution is poorer). Thus,
the FWT basis functions provide a compromise between the two limiting cases
in Fig. 7.23(a) and (b). This fundamental difference between the FFT and FWT
was noted in the introduction to the chapter and is important in the analysis of
nonstationary functions whose frequencies vary in time.
1
1MN a a Ww(j0, m, n)wj0, m, n(x, y)
f(x, y) =
m n
q
1 i i
1MN i =a a a a W c(j, m, n)cj, m, n (x, y)
+ (7.5-9)
H,V,D j = j0 m n
Like the 1-D discrete wavelet transform, the 2-D DWT can be implemented
using digital filters and downsamplers. With separable two-dimensional scaling
and wavelet functions, we simply take the 1-D FWT of the rows of f(x, y), fol-
lowed by the 1-D FWT of the resulting columns. Figure 7.24(a) shows the
7.5 ■ Wavelet Transforms in Two Dimensions 503
hc(m) 2T
D
Wc (j, m, n)
Rows
hc(n) 2T (along m)
Columns
V
(along n) hw(m) 2T Wc(j, m, n)
Ww(j 1, m, n) Rows
H
hc(m) 2T Wc (j, m, n)
Rows
hw(n) 2T
Columns
hw(m) 2T Ww(j, m, n)
Rows
H
Ww( j, m, n) Wc ( j, m, n)
Ww( j 1, m, n)
V D
Wc( j, m, n) Wc ( j, m, n)
D
Wc (j, m, n) 2c hc(m)
Rows
(along m) 2c hc(n)
Columns
V
Wc(j, m, n) 2c hw(m) (along n)
Rows
Ww(j 1, m, n)
H
Wc (j, m, n) 2c hc(m)
Rows
2c hw(n)
Columns
Ww(j, m, n) 2c hw(m)
Rows
a
b
c
FIGURE 7.24 The 2-D fast wavelet transform: (a) the analysis filter bank; (b) the
resulting decomposition; and (c) the synthesis filter bank.
504 Chapter 7 ■ Wavelets and Multiresolution Processing
process in block diagram form. Note that, like its one-dimensional counterpart
in Fig. 7.17, the 2-D FWT “filters” the scale j + 1 approximation coefficients
to construct the scale j approximation and detail coefficients. In the two-
dimensional case, however, we get three sets of detail coefficients—the hori-
zontal, vertical, and diagonal details.
The single-scale filter bank of Fig. 7.24(a) can be “iterated” (by tying the ap-
proximation output to the input of another filter bank) to produce a P scale
transform in which scale j is equal to J - 1, J - 2, Á , J - P. As in the one-
dimensional case, image f(x, y) is used as the Ww(J, m, n) input. Convolving
its rows with hw( -n) and hc(-n) and downsampling its columns, we get two
subimages whose horizontal resolutions are reduced by a factor of 2. The high-
pass or detail component characterizes the image’s high-frequency informa-
tion with vertical orientation; the lowpass, approximation component contains
its low-frequency, vertical information. Both subimages are then filtered
columnwise and downsampled to yield four quarter-size output subimages—
Note how Ww, WH V
c , Wc , Ww, W H V D
c , W c , and W c . These subimages, which are shown in the middle of
and WD c are arranged in
Fig. 7.24(b). For each Fig. 7.24(b), are the inner products of f(x, y) and the two-dimensional scaling
scale that is computed, and wavelet functions in Eqs. (7.5-1) through (7.5-4), followed by downsam-
they replace the previous
scale approximation on pling by two in each dimension. Two iterations of the filtering process pro-
which they were based. duces the two-scale decomposition at the far right of Fig. 7.24(b).
Figure 7.24(c) shows the synthesis filter bank that reverses the process just
described. As would be expected, the reconstruction algorithm is similar to the
one-dimensional case. At each iteration, four scale j approximation and detail
subimages are upsampled and convolved with two one-dimensional filters—
one operating on the subimages’ columns and the other on its rows. Addition
of the results yields the scale j + 1 approximation, and the process is repeated
until the original image is reconstructed.
EXAMPLE 7.12: ■ Figure 7.25(a) is a 128 * 128 computer-generated image consisting of 2-D
Computing a 2-D sine-like pulses on a black background. The objective of this example is to
fast wavelet illustrate the mechanics involved in computing the 2-D FWT of this image.
transform.
Figures 7.25(b) through (d) show three FWTs of the image in Fig. 7.25(a). The
2-D filter bank of Fig. 7.24(a) and the decomposition filters shown in Figs. 7.26(a)
and (b) were used to generate all three results.
The scaling and wavelet Figure 7.25(b) shows the one-scale FWT of the image in Fig. 7.25(a). To
vectors used in this
example are described
compute this transform, the original image was used as the input to the filter
later. Our focus here is bank of Fig. 7.24(a). The four resulting quarter-size decomposition outputs (i.e.,
on the mechanics of the
transform computation,
the approximation and horizontal, vertical, and diagonal details) were then
which are independent of arranged in accordance with Fig. 7.24(b) to produce the image in Fig. 7.25(b). A
the filter coefficients
employed.
similar process was used to generate the two-scale FWT in Fig. 7.25(c), but the
input to the filter bank was changed to the quarter-size approximation subim-
age from the upper-left-hand corner of Fig. 7.25(b). As can be seen in Fig.
7.25(c), that quarter-size subimage was then replaced by the four quarter-size
7.5 ■ Wavelet Transforms in Two Dimensions 505
a b
c d
FIGURE 7.25
Computing a 2-D
three-scale FWT:
(a) the original
image; (b) a one-
scale FWT; (c) a
two-scale FWT;
and (d) a three-
scale FWT.
(now 1 > 16th of the size of the original image) decomposition results that were
generated in the second filtering pass. Finally, Fig. 7.25(d) is the three-scale
FWT that resulted when the subimage from the upper-left-hand corner of Fig.
7.25(c) was used as the filter bank input. Each pass through the filter bank pro-
duced four quarter-size output images that were substituted for the input from
which they were derived. Note the directional nature of the wavelet-based
subimages, WH V D
c , Wc , and Wc , at each scale. ■
The decomposition filters used in the preceding example are part of a well-
known family of wavelets called symlets, short for “symmetrical wavelets.” Al- Recall that the compact
though they are not perfectly symmetrical, they are designed to have the least support of a function is
asymmetry and highest number of vanishing moments† for a given compact the interval in which the
function has non-zero
support (Daubechies [1992]). Figures 7.26(e) and (f) show the fourth-order values.
†
The kth moment of wavelet c(x) is m(k) = 1 xkc(x) dx. Zero moments impact the smoothness of the
scaling and wavelet functions and our ability to represent them as polynomials. An order-N symlet has
N vanishing moments.
506 Chapter 7 ■ Wavelets and Multiresolution Processing
c(x) w(x)
2 1.4
1.5 1.2
1 1
0.8
0.5
0.6
0
0.4
0.5 0.2
1 0
1.5 x 0.2 x
0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7
c(x) w( y)
1.5
0.5
0.5
1
8
6 8
4 6
y 2 4 x
2
0
7.5 ■ Wavelet Transforms in Two Dimensions 507
1-D symlets (i.e., wavelet and scaling functions). Figures 7.26(a) through (d)
show the corresponding decomposition and reconstruction filters. The co-
efficients of lowpass reconstruction filter g0(n) = hw(n) for 0 … n … 7 are
given in Table 7.3. The coefficients of the remaining orthonormal filters are
obtained using Eq. (7.1-14). Figure 7.26(g), a low-resolution graphic depiction
of wavelet cV(x, y), is provided as an illustration of how a one-dimensional
scaling and wavelet function can combine to form a separable, two-dimensional
wavelet.
We conclude this section with two examples that demonstrate the useful-
ness of wavelets in image processing. As in the Fourier domain, the basic ap-
proach is to
Because the DWT’s scaling and wavelet vectors are used as lowpass and high-
pass filters, most Fourier-based filtering techniques have an equivalent
“wavelet domain” counterpart.
■ Figure 7.27 provides a simple illustration of the preceding three steps. In EXAMPLE 7.13:
Fig. 7.27(a), the lowest scale approximation component of the discrete wavelet Wavelet-based
edge detection.
transform shown in Fig. 7.25(c) has been eliminated by setting its values to
zero. As Fig. 7.27(b) shows, the net effect of computing the inverse wavelet
transform using these modified coefficients is edge enhancement, reminiscent
of the Fourier-based image sharpening results discussed in Section 4.9. Note
how well the transitions between signal and background are delineated, de-
spite the fact that they are relatively soft, sinusoidal transitions. By zeroing the
horizontal details as well—see Figs. 7.27(c) and (d)—we can isolate the verti-
cal edges. ■
508 Chapter 7 ■ Wavelets and Multiresolution Processing
a b
c d
FIGURE 7.27
Modifying a DWT
for edge
detection: (a) and
(c) two-scale
decompositions
with selected
coefficients
deleted; (b) and
(d) the
corresponding
reconstructions.
EXAMPLE 7.14: ■ As a second example, consider the CT image of a human head shown in
Wavelet-based Fig. 7.28(a). As can be seen in the background, the image has been uniformly
noise removal.
corrupted with additive white noise. A general wavelet-based procedure for
denoising the image (i.e., suppressing the noise part) is as follows:
Step 1. Choose a wavelet (e.g. Haar, symlet, Á ) and number of levels
(scales), P, for the decomposition. Then compute the FWT of the noisy
image.
Step 2. Threshold the detail coefficients. That is, select and apply a thresh-
old to the detail coefficients from scales J - 1 to J - P. This can be ac-
complished by hard thresholding, which means setting to zero the elements
whose absolute values are lower than the threshold, or by soft threshold-
ing, which involves first setting to zero the elements whose absolute values
are lower than the threshold and then scaling the nonzero coefficients to-
ward zero. Soft thresholding eliminates the discontinuity (at the threshold)
that is inherent in hard thresholding. (See Chapter 10 for a discussion of
thresholding.)
Step 3. Compute the inverse wavelet transform (i.e., perform a wavelet recon-
struction) using the original approximation coefficients at level J - P and the
modified detail coefficients for levels J - 1 to J - P.
7.5 ■ Wavelet Transforms in Two Dimensions 509
a b
c d
e f
FIGURE 7.28
Modifying a DWT
for noise removal:
(a) a noisy CT of a
human head; (b),
(c) and (e) various
reconstructions
after thresholding
the detail
coefficients;
(d) and (f) the
information
removed during
the reconstruction
of (c) and (e).
(Original image
courtesy
Vanderbilt
University
Medical Center.)
Figure 7.28(b) shows the result of performing these operations with fourth-
order symlets, two scales (i.e., P = 2), and a global threshold that was de-
termined interactively. Note the reduction in noise and blurring of image
edges. This loss of edge detail is reduced significantly in Fig. 7.28(c), which
510 Chapter 7 ■ Wavelets and Multiresolution Processing
a b Ww(J, n) f (n) VJ
FIGURE 7.29
An (a) coefficient
Ww(J 1, n) Wc(J 1, n) VJ 1 WJ 1
tree and
(b) analysis tree
for the two-scale
Ww(J 2, n) Wc(J 2, n) VJ 2 WJ 2
FWT analysis
bank of Fig. 7.18.
7.6 ■ Wavelet Packets 511
which are samples of the function itself, while the leaves inherit the transform’s
approximation and detail coefficient outputs. The lone intermediate node,
Ww(J - 1, n), is a filter bank approximation that is ultimately filtered to become
two leaf nodes. Note that the coefficients of each node are the weights of a linear
expansion that produces a band-limited “piece” of root node f(n). Because any
such piece is an element of a known scaling or wavelet subspace (see Sections
7.2.2 and 7.2.3), we can replace the generating coefficients in Fig. 7.29(a) by the
corresponding subspace.The result is the subspace analysis tree of Fig. 7.29(b).Al-
though the variable W is used to denote both coefficients and subspaces, the two
quantities are distinguishable by the format of their subscripts.
These concepts are further illustrated in Fig. 7.30, where a three-scale FWT
analysis bank, analysis tree, and corresponding frequency spectrum are depicted.
Unlike Fig. 7.18(a), the block diagram of Fig. 7.30(a) is labeled to resemble the
analysis tree in Fig. 7.30(b)—as well as the spectrum in Fig. 7.30(c). Thus, while
the output of the upper-left filter and subsampler is, to be accurate,
Wc(J - 1, n), it has been labeled WJ - 1—the subspace of the function that is
generated by the Wc(J - 1, n) transform coefficients. This subspace corre-
sponds to the upper-right leaf of the associated analysis tree, as well as the right-
most (widest bandwidth) segment of the corresponding frequency spectrum.
Analysis trees provide a compact and informative way of representing mul-
tiscale wavelet transforms. They are simple to draw, take less space than their
corresponding filter and subsampler-based block diagrams, and make it relatively
a
hc(n) 2T WJ 1
b c
FIGURE 7.30
f(x)H VJ hc(n) 2T WJ 2 A three-scale
FWT filter bank:
hw(n) 2T VJ 1 hc(n) 2T WJ 3 (a) block diagram;
(b) decomposition
space tree; and
hw(n) 2T VJ 2 (c) spectrum
splitting
characteristics.
hw(n) 2T VJ 3
VJ |H(v)|
VJ
VJ 1
VJ 1 WJ 1 VJ 2
VJ 3 WJ 3 v
0 p/8 p/4 p/2 p
512 Chapter 7 ■ Wavelets and Multiresolution Processing
easy to detect valid decompositions. The three-scale analysis tree of Fig. 7.30(b),
for example, makes possible the following three expansion options:
VJ = VJ - 1 { WJ - 1 (7.6-1)
VJ = VJ - 2 { WJ - 2 { WJ - 1 (7.6-2)
VJ = VJ - 3 { WJ - 3 { WJ - 2 { WJ - 1 (7.6-3)
FIGURE 7.31 VJ
A three-scale
wavelet packet
analysis tree. VJ 1 WJ 1
hc(n) WJ 1, DD
a
2T
b
hc(n) 2T WJ 1, D
hw(n) 2T WJ 1, DA FIGURE 7.32
The (a) filter bank
hc(n) 2T WJ 1 and (b) spectrum
hc(n) 2T WJ 1, AD splitting
hw(n) 2T WJ 1, A characteristics of
hw(n) 2T WJ 1, AA a three-scale full
f(x)H VJ wavelet packet
analysis tree.
hc(n) 2T WJ 2, D
hc(n) 2T WJ 2
hw(n) 2T WJ 2, A
hw(n) 2T VJ 1
hc(n) 2T WJ 3
hw(n) 2T VJ 2
hw(n) 2T VJ 3
|H(v)|
VJ
VJ 1 WJ 1
VJ 2 WJ 2 WJ 1, D WJ 1, A
v
0 p/8 p/4 p/ 2 p
v
0 p/ 2 5p/ 8 3p/4 p
514 Chapter 7 ■ Wavelets and Multiresolution Processing
D(P + 1) = C D(P) D + 1
2
(7.6-6)
a b v vertical
p
FIGURE 7.34
The first D V D
WJ 1 WJ 1 WJ 1
decomposition of
a two-dimensional
FWT: (a) the
spectrum and H H
(b) the subspace WJ 1 VJ 1 WJ 1 vhorizontal
p p
analysis tree.
VJ
D V D
WJ 1 WJ 1 WJ 1
H V D
VJ 1 WJ 1 WJ 1 WJ 1
p
7.6 ■ Wavelet Packets 515
VJ
H V D
VJ 1 WJ 1 WJ 1 WJ 1
H H
VJ 2 WJ 2 WJ 1, V
H V D H H H H H H H H
VJ 3 WJ 3 WJ 3 WJ 3 WJ 2, A WJ 2,H WJ 2, V WJ 2, D WJ 1, VA WJ 1, VH WJ 1, VV WJ 1, VD
FIGURE 7.35 A three-scale, full wavelet packet decomposition tree. Only a portion of the tree is provided.
unique expansions, where D(1) = 1. Thus, the three-scale tree of Fig. 7.35 of-
fers 83,522 possible decompositions. The problem of selecting among them is
the subject of the next example.
■ As noted in the above discussion, a single wavelet packet tree presents nu- EXAMPLE 7.15:
merous decomposition options. In fact, the number of possible decompositions is Two-dimensional
often so large that it is impractical, if not impossible, to enumerate or examine wavelet packet
decompositions.
them individually.An efficient algorithm for finding optimal decompositions with
respect to application specific criteria is highly desirable. As will be seen, classical
entropy- and energy-based cost functions are applicable in many situations and
are well suited for use in binary and quaternary tree searching algorithms.
Consider the problem of reducing the amount of data needed to represent
the 400 * 480 fingerprint image in Fig. 7.36(a). Image compression is dis-
cussed in detail in Chapter 8. In this example, we want to select the “best”
three-scale wavelet packet decomposition as a starting point for the com-
pression process. Using three-scale wavelet packet trees, there are 83,522
[see Eq. (7.6-7)] potential decompositions. Figure 7.36(b) shows one of
them—a full wavelet packet, 64-leaf decomposition like the analysis tree of The 64 leaf nodes in
Fig. 7.35 correspond to
Fig. 7.35. Note that the leaves of the tree correspond to the subbands of the the 8 * 8 array of 64
8 * 8 array of decomposed subimages in Fig. 7.36(b). The probability that this subimages in Fig. 7.36(b).
Despite appearances,
particular 64-leaf decomposition is in some way optimal for the purpose of they are not square. The
compression, however, is relatively low. In the absence of a suitable optimality distortion (particularly
noticeable in the
criterion, we can neither confirm nor deny it. approximation subim-
One reasonable criterion for selecting a decomposition for the compression age) is due to the
program used to produce
of the image of Fig. 7.36(a) is the additive cost function the result.
a b
FIGURE 7.36 (a) A scanned fingerprint and (b) its three-scale, full wavelet packet decomposition. (Original
image courtesy of the National Institute of Standards and Technology.)
Other possible energy This function provides one possible measure of the energy content of two-
measures include the
sum of the squares of
dimensional function f. Under this measure, the energy of function f(m, n) = 0
f(x, y), the sum of the for all m and n is 0. High values of E, on the other hand, are indicative of func-
log of the squares, etc.
Problem 7.27 defines one
tions with many nonzero values. Since most transform-based compression
possible entropy-based schemes work by truncating or thresholding the small coefficients to zero, a cost
cost function.
function that maximizes the number of near-zero values is a reasonable criterion
for selecting a “good” decomposition from a compression point of view.
The cost function just described is both computationally simple and easily
adapted to tree optimization routines. The optimization algorithm must use
the function to minimize the “cost” of the leaf nodes in the decomposition
tree. Minimal energy leaf nodes should be favored because they have more
near-zero values, which leads to greater compression. Because the cost func-
tion of Eq. (7.6-8) is a local measure that uses only the information available at
the node under consideration, an efficient algorithm for finding minimal energy
solutions is easily constructed as follows:
For each node of the analysis tree, beginning with the root and proceeding
level by level to the leaves:
Step 1. Compute both the energy of the node, denoted EP (for parent
energy), and the energy of its four offspring—denoted EA, EH, EV, and
ED. For two-dimensional wavelet packet decompositions, the parent is
a two-dimensional array of approximation or detail coefficients; the
7.6 ■ Wavelet Packets 517
FIGURE 7.37
An optimal
wavelet packet
decomposition for
the fingerprint of
Fig. 7.36(a).
518 Chapter 7 ■ Wavelets and Multiresolution Processing
VJ
V D
VJ1 WJ1 WJ1
H V D V V V V
VJ2 WJ2 WJ2 WJ2 WJ1,A WJ1,H WJ1,V WJ1,D
H V D H H H H V V V V D D D D V V V V
VJ3 WJ3 WJ3 WJ3 WJ2,A WJ2,H WJ2,V WJ2,D WJ2,A WJ2,H WJ2,V WJ2,D WJ2,A WJ2,H WJ2,V WJ2,D WJ1,AA WJ1,AH WJ1,AV WJ1,AD
H
WJ1
H H H H
WJ1,A WJ1,H WJ1,V WJ1,D
H H H H H H H H
WJ1,AA WJ1,AH WJ1,AV WJ1,AD WJ1,DA WJ1,DH WJ1,DV WJ1,DD
FIGURE 7.38 The optimal wavelet packet analysis tree for the decomposition in Fig. 7.37.
images (FBI [1993]). Using biorthogonal wavelets, the standard achieves a typical
compression ratio of 15:1. The advantages of wavelet-based compression over
the more traditional JPEG approach are examined in the next chapter.
The decomposition filters used in Example 7.15, as well as by the FBI, are
part of a well-known family of wavelets called Cohen-Daubechies-Feauveau
biorthogonal wavelets (Cohen, Daubechies, and Feauveau [1992]). Because
the scaling and wavelet functions of the family are symmetrical and have simi-
lar lengths, they are among the most widely used biorthogonal wavelets.
Figures 7.39(e) through (h) show the dual scaling and wavelet functions.
Figures 7.39(a) through (d) are the corresponding decomposition and recon-
struction filters. The coefficients of the lowpass and highpass decomposition
filters, h0(n) and h1(n) for 0 … n … 17 are shown in Table 7.4. The corre-
sponding coefficients of the biorthogonal synthesis filters can be computed
using g0(n) = (-1)n + 1h1(n) and g1(n) = (-1)n h0(n) of Eq. (7.1-11). That is,
they are cross-modulated versions of the decomposition filters. Note that zero
padding is employed to make the filters the same length and that Table 7.4 and
Fig. 7.39 define them with respect to the subband coding and decoding system
of Fig. 7.6(a); with respect to the FWT, hw(-n) = h0(n) and hc(-n) = h1(n).
h0(n) h1(n) a b
1.2 0.6 c d
1 0.4 e f
g h
0.8 0.2
FIGURE 7.39
0.6 0
A member of the
0.4 0.2 Cohen-
0.2 0.4 Daubechies-
Feauveau
0 0.6
biorthogonal
0.2 n 0.8 n wavelet family:
0 4 8 12 16 0 4 8 12 16
(a) and (b)
g0(n) g1(n) decomposition
0.8 0.5 filter coefficients;
(c) and (d)
0.6 reconstruction
0 filter coefficients;
0.4 (e)–(h) dual
wavelet and
0.2 scaling functions.
0.5
See Table 7.3 for
0 the values of
h0(n) and h1(n)
0.2 n 1 n
0 4 8 12 16 0 4 8 12 16 for 0 … n … 17.
~
w(x) w(x)
1.4 1.5
1.2
1 1
0.8
0.6 0.5
0.4
0
0.2
0 0.5
0.2
0.4 x 1 x
0 2 4 6 8 10 12 14 16 18 0 2 4 6 8 10 12 14 16 18
~
c(x) c(x)
1.2 1.5
1
1
0.8
0.6 0.5
0.4 0
0.2
0.5
0
0.2 x 1 x
0 2 4 6 8 10 12 14 16 18 0 2 4 6 8 10 12 14 16 18
520 Chapter 7 ■ Wavelets and Multiresolution Processing
Summary
The material of this chapter establishes a solid mathematical foundation for under-
standing and accessing the role of wavelets and multiresolution analysis in image pro-
cessing. Wavelets and wavelet transforms are relatively new imaging tools that are
being rapidly applied to a wide variety of image processing problems. Because of their
similarity to the Fourier transform, many of the techniques in Chapter 4 have wavelet
domain counterparts. A partial listing of the imaging applications that have been ap-
proached from a wavelet point of view includes image matching, registration, segmen-
tation, denoising, restoration, enhancement, compression, morphological filtering, and
computed tomography. Since it is impractical to cover all of these applications in a sin-
gle chapter, the topics included were chosen for their value in introducing or clarifying
fundamental concepts and preparing the reader for further study in the field. In
Chapter 8, we will apply wavelets to the compression of images.
Problems
7.1 Design a system for decoding the prediction residual pyramid generated by the
encoder of Fig. 7.2(b) and draw its block diagram. Assume there is no quantiza-
tion error introduced by the encoder.
7.2 Construct a fully populated approximation pyramid and corresponding predic-
tion residual pyramid for the image
1 2 3 4
5 6 7 8
f(x, y) = D T
9 10 11 12
13 14 15 16
Use 2 * 2 block neighborhood averaging for the approximation filter in Fig. 7.2(b)
and assume the interpolation filter implements pixel replication.
7.3 Given a 2 J * 2 J image, does a J + 1-level pyramid reduce or expand the
amount of data required to represent the image? What is the compression or ex-
pansion ratio?
7.4 Is the two-band subband coding filter bank containing filters h0(n) = E 1> 12,
1> 12 F , h1(n) = E -1> 12, 1> 12 F , g0(n) = E 1> 12, 1> 12 F , and g1(n)
= E 1> 12, -1> 12 F orthonormal, biorthogonal, or both?
7.5 Given the sequence f(n) = 50, 0.5, 0.25, 16 where n = 0, 1, 2, 3, compute:
(a) The sign-reversed sequence.
(b) The order-reversed sequence.
(c) The modulated sequence.
(d) The modulated and then order-reversed sequence.
(e) The order-reversed and then modulated sequence.
(f) Does the result from (d) or (e) correspond to Eq. (7.1-9)?
7.6 Compute the coefficients of the Daubechies synthesis filters g0(n) and g1(n)
for Example 7.2. Using Eq. (7.1-13) with m = 0 only, show that the filters are
orthonormal.
7.7 Draw a two-dimensional four-band filter bank decoder to reconstruct input
f(m, n) in Fig. 7.7.
7.8 Obtain the Haar transformation matrix for N = 8.
7.9 (a) Compute the Haar transform of the 2 * 2 image
3 -1
F = B R
6 2