Mathematica 9 is now available

Block Transform Coding

download notebookDownload this example as a Mathematica notebook.


Digital Image Processing allows you to apply powerful transform domain techniques to your data. Transform methods are typically used in filtering, compression, and image texture analysis.

[Graphics:Images/index_gr_1.gif]

Transform coding compresses image data by representing the original signal with a small number of transform coefficients. It exploits the fact that for typical images a large amount of signal energy is concentrated in a small number of coefficients. Transform coding is an integral part of the Joint Photographic Experts Group (JPEG) standard for lossy image compression.

This loads one of the example images.

[Graphics:Images/index_gr_2.gif]

Block transform coding divides an image into blocks of equal size and processes each block independently. Block processing allows the coder to adapt to local image statistics, exploit the correlation present among neighboring image pixels, and reduce computational and storage requirements. The baseline JPEG algorithm uses nonoverlapping blocks of dimensions 8x8.

Here we compute the block discrete cosine transform of an example image. As required by JPEG, the image is first normalized with respect to the middle gray level.

[Graphics:Images/index_gr_3.gif]

Here a multiblock segment of the original image and the corresponding DCT coefficient blocks are shown.

[Graphics:Images/index_gr_4.gif]

[Graphics:Images/index_gr_5.gif]