100% found this document useful (1 vote)
400 views30 pages

Image Compression Using DCT: - Rohan Kumar Sinha - Raghavendra Karthik D - Bijay Kalikotay

This document discusses image compression using the discrete cosine transform (DCT). It explains that DCT converts images from the time domain to the frequency domain, decorrelating pixel values. In JPEG compression, DCT is applied to 8x8 pixel blocks, then quantization discards less important frequency coefficients before entropy encoding. The process involves DCT, quantization, zigzag ordering, and decompression using the inverse DCT. DCT exhibits good energy compaction and decorrelation properties beneficial for compression.

Uploaded by

redpaladin
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
400 views30 pages

Image Compression Using DCT: - Rohan Kumar Sinha - Raghavendra Karthik D - Bijay Kalikotay

This document discusses image compression using the discrete cosine transform (DCT). It explains that DCT converts images from the time domain to the frequency domain, decorrelating pixel values. In JPEG compression, DCT is applied to 8x8 pixel blocks, then quantization discards less important frequency coefficients before entropy encoding. The process involves DCT, quantization, zigzag ordering, and decompression using the inverse DCT. DCT exhibits good energy compaction and decorrelation properties beneficial for compression.

Uploaded by

redpaladin
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 30

Image Compression Using

DCT
-Rohan Kumar Sinha
-Raghavendra Karthik D
-Bijay Kalikotay
CONTENTS
1) Introduction
2) The JPEG Process
3) The Discrete Cosine Transform
a) 1D DCT
b) 2D DCT
4) DCT Matrix
5) Quantization
6) ZigZag
7) Decompression
8) Properties of DCT
9) Conclusion
10) Demonstration in Matlab
11) References
INTRODUCTION
 Efficient ways of storing large amounts of data and storage
limitations, images must be compressed before transmission
and storage.
 For example, someone with a web page or online catalog.
This is because the amount of space required to hold
unadulterated images can be prohibitively large in terms of
cost.
 This fall into two general categories:
lossless and lossy image compression.

 However, the compression will reduce the image fidelity,


especially when the images are compressed at lower bit rates.
The reconstructed images suffer from blocking artifacts and
the image quality will be severely degraded under the
circumstance of high compression ratios. In order to have a
good compression ratio without losing too much of
information when the image is decompressed we use DCT.
Concept on DCT :-
 expresses a sequence of finitely many data points in terms of
a sum of cosine functions oscillating at different frequencies.
 
 The JPEG process is used form of lossy image compression
that center s on the DCT.

 DCT convert images from time-domain to frequency-domain


to decorrelate pixels.

 The DCT works by separating images into parts of differing


frequencies. During a step called quantization, where part of
compression actually occurs, the less important frequencies
are discarded, hence the use of the term “lossy“.
The JPEG Process
More comprehensive understanding of the process may be acquired
as such given under:

 1. The image is broken into 8x8 blocks of pixels.

 2. Working from left to right, top to bottom, the DCT is applied to


each block.

 3. Each block is compressed through quantization.

 4. The array of compressed blocks that constitute the image is stored


in a drastically reduced amount of space.

 5. When desired, the image is reconstructed through decompression,


a process that uses the Inverse Discrete Cosine Transform (IDCT).
The Process
Image compression(DCT)
 An image compression system has three main
blocks.
 – a transform (usually DCT on 8x8 blocks)
 – a quantizer
 – a lossless (entropy) coder
 Each tries to throw away information which is

not essential to understand the image, but


costs bits.
Discrete Cosine Transformation
 The Discrete Cosine Transform (DCT) attempts to decorrelate the
image data. After decorrelation each transform coefficient can be
encoded independently without losing compression efficiency. This
section describes the DCT and some of its important properties.
1) The one-Dimensional DCT
Note:
 f(x) represents inverse transformations.

 C(x) represents most common definition of a 1-D sequence of

length N
 Thus, the first transform coefficient is the

average value of the sample sequence. In literature, this value is


referred to as the DC
Coefficient. All other transform coefficients are called the AC
Coefficients.
2) The Two-Dimensional DCT

- The 2-D DCT is just a 1-D DCT applied


twice, once in the x direction, and again in
the y direction. One can imagine the
computational complexity of doing so for a
large image.
- algorithm like FFT, created to speed the
computation.
THE DCT MATRIX:
To get the matrix form of Equation we
will use the following equation

For an 8x8 block its results in this matrix


Cont..
Cont...
Because the DCT is designed to work on pixel values ranging
from -128 to 127, the original block is “leveled off“ by
subtracting 128 from each entry. This results in the following
matrix
We are now ready to perform the Discrete Cosine Transform,
which is accomplished by matrix multiplication
D = TMT’
In Equation matrix M is first multiplied on the left by
the DCT matrix T from the previoussection; this transforms the
rows. The columns are then transformed by multiplying on theright
by the transpose of the DCT matrix. This yields the following
matrix.----
QUANTIZATION
 Subjective experiments involving the human visual system have
resulted in the JPEG standard quantization matrix. With a quality
level of 50, this matrix renders both high compression and excellent
decompressed image quality.

 Major role in Image compression process.


 Quantization is achieved by dividing each element in
the transformed image matrix D by corresponding
element in the quantization matrix, and then
rounding to the nearest integer value.
For the following step, quantization matrix Q50 is
used.
ZIGZAG:
 JPEG takes advantage of this by encoding
quantized coefficients in the zig-zag
sequence shown in Figure as under.

 Advantage: consolidation of relatively large


runs of zeroes. Which compresses very well.
DECOMPRESSION:
 Reconstruction of our image begins by
decoding the bit stream representing the
Quantized matrix C. Each element of C is
then multiplied by the corresponding element
of the quantization matrix originally used

R i, j =Q i, j ×C i, j


 The IDCT is next applied to matrix R, which is
rounded to the nearest integer. Finally, 128 is
added to each element of that result, giving
us the decompressed JPEG version N of our
original 8x8 image block M

 N = round (T’RT) + 128


PROPERTIES OF DCT
 a) Decorrelation: The principle advantage of
image transformation is the removal
of redundancy between neighboring pixels.
This leads to uncorrelated transform
coefficients which can be encoded
independently. It can be inferred that DCT
exhibits excellent decorrelation properties
 b) Energy Compaction: Efficacy(effectiveness)
of a transformation scheme can be directly
gauged by its ability to pack input data into
as few coefficients as possible.
This allows the quantizer to discard
coefficients with relatively small amplitudes
without introducing visual distortion in the
reconstructed image. DCT exhibits excellent
energy compaction for highly correlated
images
 c) Separability: The DCT transform equation
can be expressed as
 d) Symmetry: Another look at the row and
column operations in above Equation reveals
that these operations are functionally
identical. Such a transformation is called a
symmetric transformation
Conclusions

 DCT as application example


 Create multiple implementations from a

single description
 Helps to explore tradeoffs among accuracy,

area, latency and throughput


 Designers can concentrate on higher level

algorithmic issues
 Reduces turnaround time, improves

productivity
References

 1) Digital Image Processing by “Gonzalez and


Woods”.
 2) IEEE Journals and Research papers.

3) Wikipedia.org.
4) Mathworks Matlab Central.
5) fip-Contents.html

You might also like