<< Chapter < Page | Chapter >> Page > |
In the equation from our discussion of the Haar transform: and to invert: we saw how a 1-D transform could be extended to 2-D by pre- and post-multiplication of a square matrix to give a matrix result . Our example then used matrices, but this technique applies to square matrices of any size.
Hence the DCT may be extended into 2-D by this method.
E.g. the DCT transforms a subimage of pels into a matrix of DCT coefficients.
The 2-D basis functions, from which may be reconstructed, are given by the separate products of the columns of with the rows of . These are shown for in (a) of as 64 subimages of size pels.
The result of applying the DCT to the Lenna image is shown in (b) of . Here each block of pels is replaced by the block of DCT coefficients . This shows the block structure clearly but is not very meaningful otherwise.
Part(c) of shows the same data, reordered into 64 subimages of coefficients each so that each subimage contains all the coefficients of a given type - e.g: the top left subimagecontains all the coefficients for the top left basis function from (a) of . The other subimages and basis functions correspond in the same way.
We see the major energy concentration to the subimages in the top left corner. (d) of is an enlargement of the top left 4 subimages of (c) of and bears a strong similarity to the group of third level Haar subimages in (b) of this figure . To emphasise this thehistograms and entropies of these 4 subimages are shown in .
Comparing with this figure , the Haar transform equivalent, we see that the Lo-Lo bands have identicalenergies and entropies. This is because the basis functions are identical flat surfaces in both cases. Comparing the other 3bands, we see that the DCT bands contain more energy and entropy than their Haar equivalents, which means less energy (and so hopefully less entropy) in the higher DCT bands (not shown) because the total energy isfixed (the transforms all preserve total energy). The mean entropy for all 64 subimages is 1.3622 bit/pel, which comparesfavourably with the 1.6103 bit/pel for the 4-level Haar transformed subimages using the same .
This is a similar question to: What is the optimum number of levels for the Haar transform?
We have analysed Lenna using DCT sizes from to to investigate this. shows the and sets of DCT subimages. The DCT is identical to the level 1 Haar transform (so see (b) of ) and the set is in (c) of .
and show the mesh plots of the entropies of the subimages in .
compares the total entropy per pel for the 4 DCT sizes with the equivalent 4 Haartransform sizes. We see that the DCT is significantly better than the rather simpler Haar transform.
As regards the optimum DCT size, from , the DCT seems to be marginally better than the DCT, but subjectively this is not the case since quantisation artefacts become more visible as the block sizeincreases. In practise, for a wide range of images and viewing conditions, has been found to be the optimum DCT block size and is specified in most current coding standards.
Notification Switch
Would you like to follow the 'Image coding' conversation and receive update notifications?