0% found this document useful (0 votes)
6 views6 pages

MLSP Exp03 60002200083

The document discusses compressing and reconstructing an image using singular value decomposition (SVD). It explains how SVD decomposes an image matrix into singular values and vectors. Retaining more singular values yields higher quality compressed images but larger file sizes, while fewer singular values increases compression but reduces quality. The experiment compresses an image using 5, 10, 20 and 30 singular values and reconstructs it with the same numbers, demonstrating the tradeoff between quality and file size.

Uploaded by

Raj mehta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views6 pages

MLSP Exp03 60002200083

The document discusses compressing and reconstructing an image using singular value decomposition (SVD). It explains how SVD decomposes an image matrix into singular values and vectors. Retaining more singular values yields higher quality compressed images but larger file sizes, while fewer singular values increases compression but reduces quality. The experiment compresses an image using 5, 10, 20 and 30 singular values and reconstructs it with the same numbers, demonstrating the tradeoff between quality and file size.

Uploaded by

Raj mehta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

DEPARTMENT OF ELECTRONICS AND TELECOMMUNICATION ENGINEERING

Sem/Branch: VIII/ EXTC Course: Machine Learning for Signal Processing– Laboratory Course code - DJ19ECEL8014

Name : Raj Mehta SAP : 60002200083

Experiment No.: 3 Date: 09/02/2024

Aim: IMAGE COMPRESSION AND RECONSTRUCTION BY SVD DECOMPOSITION


The aim of this experiment is to compress an image using Singular Value Decomposition
(SVD) for singular values 5, 10, 20, and 30 and to reconstruct the compressedimage using the
same number of singular values.
The experiment aims to demonstrate the effectiveness of SVD in image compression and to
evaluate the trade-off between image quality and compression ratio for different numbers of
singular values.

Tools Required: PYTHON


Theory:
Image compression with Singular Value Decomposition (SVD) is a technique that involves
decomposing an image into its singular value components. SVD is a mathematical technique
that decomposes a matrix into three components: a matrix of left singular vectors, a matrix of
right singular vectors, and a diagonal matrix of singular values. The singular values represent
the magnitude of the principal components of the matrix.
In image compression, SVD is used to reduce the dimensionality of the image by retaining only
the most significant singular values. The image is first represented as a matrix of pixel values,
which is then decomposed using SVD. The singular values are sorted in descending order, and
the matrix is truncated by retaining only the top k singular values, where k is the desired
compression level.
The compressed image is then reconstructed by multiplying the truncated matrices of left and
right singular vectors and the diagonal matrix of singular values. The resulting matrix is an
approximation of the original matrix of pixel values, but with a reduced number of dimensions.
By choosing a smaller number of singular values, the resulting compressed image will have a
lower file size and can be transmitted and stored more efficiently.
The effectiveness of image compression with SVD depends on the number of singular values
used for compression. Increasing the number of singular values used will result in a higher
quality image but with a larger file size. On the other hand, using fewer singular values will
result in a lower quality image but with a smaller file size.
Overall, image compression with SVD is an effective technique for reducing the file size of
images while preserving most of the image information. It is widely used in various
applications such as image storage, transmission, and analysis.
CONCLUSION:
In conclusion, the experiment on Image Compression with Singular Value Decomposition
(SVD) for singular values 5, 10, 20, 30 and reconstruction of the image for singular values 5,
10, 20, 30 has demonstrated the effectiveness of SVD in reducing the size of an image while
preserving most of the information.
The first step in the experiment was to apply SVD to the image matrix and obtain the singular
values and singular vectors. The singular values were sorted in descending order and a subset
of them was selected for compression. The image was compressed by setting the singular
values beyond the selected subset to zero.
The effectiveness of the compression was evaluated by comparing the compressed image with
the original image. The results showed that the compressed image with a higher number of
singular values closely approximated the original image, while the compressed image with a
lower number of singular values had a higher level of distortion.
The next step was to reconstruct the image using the compressed data and the original singular
vectors. The reconstructed images for different numbers of singular values were compared with
the original image to evaluate the effectiveness of the reconstruction. The results showed that
the reconstructed images with a higher number of singular values closely approximated the
original image, while the reconstructed images with a lower number of singular values had a
higher level of distortion.
SCREENSHOTS:

You might also like