SlideShare a Scribd company logo
1 of 16
Lossy Image Compression using SVD
Coding Algorithm
- K M Aishwarya
Why is compression needed?
 To store data efficiently
 To transmit data efficiently
 To save:
• Memory
• Bandwidth
• Cost
Why SVD?
 Image compression alone can experience redundancies
which can be overcome by Singular Value Decomposition
(SVD) of the image matrix.
 Image compression and coding techniques explore 3 types
of redundancies:
• Coding redundancy
• Interpixel redundancy
• Psycho-visual redundancy
Howtocompress?
Redundancies
Coding
Redundancy
Neighboring pixels are not
independent but correlated
Interpixel
Redundancy
Also called spatial
redundancy. Explored by
predicting a pixel value based
on the values of its
neighbouring pixels
Psycho-visual
Redundancy
Exists due to
psychophysical aspects of
human vision which prove
that the human eye does
not respond with equal
sensitivity to all incoming
visual information
What is SVD?
 Basic idea:
Taking a high dimensional, highly variable set of data points and
reducing it to a lower dimensional space that exposes the
substructure of the original data more clearly and orders it
from most variation to the least.
 Definition:
In linear algebra, the singular value decomposition is a
factorization of a real or complex, square or non-square matrix.
Consider a matrix A with m rows and n columns with rank r.
Then A can be factorized into three matrices:
A = USV
T
SVD – Overview I
 Diagrammatically,
where,
• U is an m × m orthogonal matrix
• VT
is the conjugate transpose of the n × n orthogonal matrix.
• S is an m × n diagonal matrix with non-negative real numbers
on the diagonal which are known as the singular values of A.
• The m columns of U and n columns of V are called the left-
singular and right-singular vectors of A respectively.
• The numbers σ1
2 ≥ … ≥ σr
2 are the eigenvalues of AA
T
and A
T
A.
SVD – Overview II
 SVD takes a matrix, square or non-square, and divides it into
two orthogonal matrices and a diagonal matrix
 Simply applying SVD on an image does not compress it
 To compress an image, after applying SVD:
 Retain the first few singular values (containing maximum image info)
 Discard the lower singular values (containing negligible info)
 The singular vectors form orthonormal bases, and the
important relation
A vi
= si
ui
 shows that each right singular vectors is mapped onto the
corresponding left singular vector, and the "magnification
factor" is the corresponding singular value
Mathematicalstepsto calculate SVD of a matrix
1. Given an input image matrix A.
2. First, calculate AA
T
and A
T
A.
3. Use AA
T
to find the eigenvalues and eigenvectors to form
the columns of U: (AA
T
- ƛI) ẍ = 0.
4. Use A
T
A to find the eigenvalues and eigenvectors to form
the columns of V: (A
T
A - ƛI) ẍ =0.
5. Divide each eigenvector by its magnitude to form the
columns of U and V.
6. Take the square root of the eigenvalues to find the singular
values, and arrange them in the diagonal matrix S in
descending order: σ1 ≥ σ2 ≥ … ≥ σr ≥ 0
In MATLAB: [U,W,V]=svd(A,0)
SVD Compression Measures
 Parameters for quantitative and qualitative compression of
image:
 Compression Ratio (CR):
CR =
uncompressed image file size
compressed image file size
 Mean Square Error (MSE):
 Signal to Noise Ratio (SNR):
𝑆𝑁𝑅 =
𝑃𝑠𝑖𝑔𝑛𝑎𝑙
𝑃𝑛𝑜𝑖𝑠𝑒
=
𝐴 𝑠𝑖𝑔𝑛𝑎𝑙
𝐴 𝑛𝑜𝑖𝑠𝑒
2
 Peak Signal to Noise Ratio (PSNR):
𝑃𝑆𝑁𝑅 = 10𝑙𝑜𝑔10
𝑀𝐴𝑋𝐼
2
𝑀𝑆𝐸
= 20𝑙𝑜𝑔10
𝑀𝐴𝑋𝐼
𝑀𝑆𝐸
Storage Space Calculations
A = USV
T
𝐴 = 𝑖=1
𝑟
𝜎𝑖 𝑢𝑖 𝑣𝑖
𝑇
𝐴 𝑘 = 𝜎1 𝑢1 𝑣1
𝑇
+ 𝜎2 𝑢2 𝑣2
𝑇
+ . . . + 𝜎𝑟 𝑢 𝑟 𝑣𝑟
𝑇
 When performing SVD compression, the sum is not performed
to the very last Singular Values (SV’s); the SV’s with small
enough values are dropped. The values which fall outside the
required rank are equated to zero. The closet matrix of rank k
is obtained by truncating those sums after the first k terms:
𝐴 𝑘 = 𝜎1 𝑢1 𝑣1
𝑇
+ 𝜎2 𝑢2 𝑣2
𝑇
+ . . . + 𝜎 𝑘 𝑢 𝑘 𝑣 𝑘
𝑇
 Total storage for 𝐴 𝑘 will be:
𝐴 𝑘 = 𝑘(𝑚 + 𝑛 + 1)
 The digital image corresponding to 𝐴 𝑘 will still have very close
resemblance to the original image
Lowest rank-k approximations
 Since σ1 > · · · > σn > 0 , in the singular matrix, the first term of
this series will have the largest impact on the total sum,
followed by the second term, then the third term, etc.
 This means we can approximate the matrix A by adding only
the first few terms of the series.
 As k increases, the image quality increases, but so too does
the amount of memory needed to store the image. This
means smaller ranked SVD approximations are preferable.
 Hence k is limit bound to ensure SVD compressed image
occupies lesser space than original image.
Necessary condition: 𝒌 <
𝒎𝒏
𝒎+𝒏+𝟏
Examplesof SVD compressionin MATLAB
Original Image:
Rank of image = 202
𝐴 𝑘 = 31840
CR = 0.580
SVDcompressedimagesfordifferentvaluesofk
Ak = 30796 Ak = 31679
CR = 61.046 CR = 23.588
k = 2 k = 12
Ak = 31699 Ak = 31781
CR = 12.101 CR = 5.72
k = 22 k = 52
Observation & Inference
 k represents the number of Eigen values used in the
reconstruction of the compressed image
 Smaller the value of k, more is the compression ratio but
image quality deteriorates
 As the value of k increases, image quality improves (i.e.
smaller MSE & larger PSNR) but more storage space is
required to store the compressed image
 When k is equal to the rank of the image matrix (202 here),
the reconstructed image is almost same as the original one
Conclusion
 SVD's applications in world of image and data compression are
very useful and resource-saving.
 SVD allows us to arrange the portions of a matrix in order of
importance. The most important singular values will produce
the most important unit eigenvectors.
 We can eliminate large portions of our matrix without losing
quality.
• Therefore, an optimum value for 'k' must be chosen, with an
acceptable error, which conveys most of the information
contained in the original image, and has an acceptable file size
too.
Thank You

More Related Content

What's hot

Chapter 8 image compression
Chapter 8 image compressionChapter 8 image compression
Chapter 8 image compressionasodariyabhavesh
 
Dimensionality reduction: SVD and its applications
Dimensionality reduction: SVD and its applicationsDimensionality reduction: SVD and its applications
Dimensionality reduction: SVD and its applicationsViet-Trung TRAN
 
03 digital image fundamentals DIP
03 digital image fundamentals DIP03 digital image fundamentals DIP
03 digital image fundamentals DIPbabak danyal
 
Histogram Processing
Histogram ProcessingHistogram Processing
Histogram ProcessingAmnaakhaan
 
Digital Image Processing: Image Segmentation
Digital Image Processing: Image SegmentationDigital Image Processing: Image Segmentation
Digital Image Processing: Image SegmentationMostafa G. M. Mostafa
 
Eigenvectors & Eigenvalues: The Road to Diagonalisation
Eigenvectors & Eigenvalues: The Road to DiagonalisationEigenvectors & Eigenvalues: The Road to Diagonalisation
Eigenvectors & Eigenvalues: The Road to DiagonalisationChristopher Gratton
 
Digital Image Processing: Image Enhancement in the Spatial Domain
Digital Image Processing: Image Enhancement in the Spatial DomainDigital Image Processing: Image Enhancement in the Spatial Domain
Digital Image Processing: Image Enhancement in the Spatial DomainMostafa G. M. Mostafa
 
Matrix decomposition and_applications_to_nlp
Matrix decomposition and_applications_to_nlpMatrix decomposition and_applications_to_nlp
Matrix decomposition and_applications_to_nlpankit_ppt
 
Transform coding
Transform codingTransform coding
Transform codingNancy K
 
ImageProcessing10-Segmentation(Thresholding) (1).ppt
ImageProcessing10-Segmentation(Thresholding) (1).pptImageProcessing10-Segmentation(Thresholding) (1).ppt
ImageProcessing10-Segmentation(Thresholding) (1).pptVikramBarapatre2
 
Image sampling and quantization
Image sampling and quantizationImage sampling and quantization
Image sampling and quantizationBCET, Balasore
 
Eigen values and eigen vectors
Eigen values and eigen vectorsEigen values and eigen vectors
Eigen values and eigen vectorstirath prajapati
 
Image enhancement in the spatial domain1
Image enhancement in the spatial domain1Image enhancement in the spatial domain1
Image enhancement in the spatial domain1shabanam tamboli
 
4.intensity transformations
4.intensity transformations4.intensity transformations
4.intensity transformationsYahya Alkhaldi
 

What's hot (20)

Chapter 8 image compression
Chapter 8 image compressionChapter 8 image compression
Chapter 8 image compression
 
Dimensionality reduction: SVD and its applications
Dimensionality reduction: SVD and its applicationsDimensionality reduction: SVD and its applications
Dimensionality reduction: SVD and its applications
 
03 digital image fundamentals DIP
03 digital image fundamentals DIP03 digital image fundamentals DIP
03 digital image fundamentals DIP
 
Histogram Processing
Histogram ProcessingHistogram Processing
Histogram Processing
 
Digital Image Processing: Image Segmentation
Digital Image Processing: Image SegmentationDigital Image Processing: Image Segmentation
Digital Image Processing: Image Segmentation
 
Eigenvectors & Eigenvalues: The Road to Diagonalisation
Eigenvectors & Eigenvalues: The Road to DiagonalisationEigenvectors & Eigenvalues: The Road to Diagonalisation
Eigenvectors & Eigenvalues: The Road to Diagonalisation
 
Lzw coding technique for image compression
Lzw coding technique for image compressionLzw coding technique for image compression
Lzw coding technique for image compression
 
Digital Image Processing: Image Enhancement in the Spatial Domain
Digital Image Processing: Image Enhancement in the Spatial DomainDigital Image Processing: Image Enhancement in the Spatial Domain
Digital Image Processing: Image Enhancement in the Spatial Domain
 
Matrix decomposition and_applications_to_nlp
Matrix decomposition and_applications_to_nlpMatrix decomposition and_applications_to_nlp
Matrix decomposition and_applications_to_nlp
 
Transform coding
Transform codingTransform coding
Transform coding
 
ImageProcessing10-Segmentation(Thresholding) (1).ppt
ImageProcessing10-Segmentation(Thresholding) (1).pptImageProcessing10-Segmentation(Thresholding) (1).ppt
ImageProcessing10-Segmentation(Thresholding) (1).ppt
 
JPEG Image Compression
JPEG Image CompressionJPEG Image Compression
JPEG Image Compression
 
image compression ppt
image compression pptimage compression ppt
image compression ppt
 
04 Multi-layer Feedforward Networks
04 Multi-layer Feedforward Networks04 Multi-layer Feedforward Networks
04 Multi-layer Feedforward Networks
 
Image sampling and quantization
Image sampling and quantizationImage sampling and quantization
Image sampling and quantization
 
Spatial domain and filtering
Spatial domain and filteringSpatial domain and filtering
Spatial domain and filtering
 
Eigen values and eigen vectors
Eigen values and eigen vectorsEigen values and eigen vectors
Eigen values and eigen vectors
 
Image enhancement in the spatial domain1
Image enhancement in the spatial domain1Image enhancement in the spatial domain1
Image enhancement in the spatial domain1
 
Lecture-11.pdf
Lecture-11.pdfLecture-11.pdf
Lecture-11.pdf
 
4.intensity transformations
4.intensity transformations4.intensity transformations
4.intensity transformations
 

Similar to Singular Value Decomposition Image Compression

A Hybrid SVD Method Using Interpolation Algorithms for Image Compression
A Hybrid SVD Method Using Interpolation Algorithms for Image CompressionA Hybrid SVD Method Using Interpolation Algorithms for Image Compression
A Hybrid SVD Method Using Interpolation Algorithms for Image CompressionCSCJournals
 
Image Encryption and Compression
Image Encryption and Compression Image Encryption and Compression
Image Encryption and Compression Sayantan Sur
 
International Journal of Engineering Research and Development (IJERD)
 International Journal of Engineering Research and Development (IJERD) International Journal of Engineering Research and Development (IJERD)
International Journal of Engineering Research and Development (IJERD)IJERD Editor
 
Face Recognition using PCA-Principal Component Analysis using MATLAB
Face Recognition using PCA-Principal Component Analysis using MATLABFace Recognition using PCA-Principal Component Analysis using MATLAB
Face Recognition using PCA-Principal Component Analysis using MATLABSindhi Madhuri
 
A Video Watermarking Scheme to Hinder Camcorder Piracy
A Video Watermarking Scheme to Hinder Camcorder PiracyA Video Watermarking Scheme to Hinder Camcorder Piracy
A Video Watermarking Scheme to Hinder Camcorder PiracyIOSR Journals
 
maths mini project ( applictions of quadratic forms and SVD ).ppt
maths mini project ( applictions of quadratic forms and SVD ).pptmaths mini project ( applictions of quadratic forms and SVD ).ppt
maths mini project ( applictions of quadratic forms and SVD ).pptManavPatane
 
Iaetsd traffic sign recognition for advanced driver
Iaetsd traffic sign recognition for  advanced driverIaetsd traffic sign recognition for  advanced driver
Iaetsd traffic sign recognition for advanced driverIaetsd Iaetsd
 
image compression in data compression
image compression in data compressionimage compression in data compression
image compression in data compressionZaabir Ali
 
Performance Analysis of Compression Techniques Using SVD, BTC, DCT and GP
Performance Analysis of Compression Techniques Using SVD, BTC, DCT and GPPerformance Analysis of Compression Techniques Using SVD, BTC, DCT and GP
Performance Analysis of Compression Techniques Using SVD, BTC, DCT and GPIOSR Journals
 
Image compression 14_04_2020 (1)
Image compression 14_04_2020 (1)Image compression 14_04_2020 (1)
Image compression 14_04_2020 (1)Joel P
 
Image quality assessment and statistical evaluation
Image quality assessment and statistical evaluationImage quality assessment and statistical evaluation
Image quality assessment and statistical evaluationDocumentStory
 
On image intensities, eigenfaces and LDA
On image intensities, eigenfaces and LDAOn image intensities, eigenfaces and LDA
On image intensities, eigenfaces and LDARaghu Palakodety
 
Scaling Transform Methods For Compressing a 2D Graphical image
Scaling Transform Methods For Compressing a 2D Graphical image Scaling Transform Methods For Compressing a 2D Graphical image
Scaling Transform Methods For Compressing a 2D Graphical image acijjournal
 
Performance Improvement of Vector Quantization with Bit-parallelism Hardware
Performance Improvement of Vector Quantization with Bit-parallelism HardwarePerformance Improvement of Vector Quantization with Bit-parallelism Hardware
Performance Improvement of Vector Quantization with Bit-parallelism HardwareCSCJournals
 
Multimedia lossy compression algorithms
Multimedia lossy compression algorithmsMultimedia lossy compression algorithms
Multimedia lossy compression algorithmsMazin Alwaaly
 

Similar to Singular Value Decomposition Image Compression (20)

Image Compression, Introduction Data Compression/ Data compression, modelling...
Image Compression, Introduction Data Compression/ Data compression, modelling...Image Compression, Introduction Data Compression/ Data compression, modelling...
Image Compression, Introduction Data Compression/ Data compression, modelling...
 
Image compression .
Image compression .Image compression .
Image compression .
 
A Hybrid SVD Method Using Interpolation Algorithms for Image Compression
A Hybrid SVD Method Using Interpolation Algorithms for Image CompressionA Hybrid SVD Method Using Interpolation Algorithms for Image Compression
A Hybrid SVD Method Using Interpolation Algorithms for Image Compression
 
Image Encryption and Compression
Image Encryption and Compression Image Encryption and Compression
Image Encryption and Compression
 
International Journal of Engineering Research and Development (IJERD)
 International Journal of Engineering Research and Development (IJERD) International Journal of Engineering Research and Development (IJERD)
International Journal of Engineering Research and Development (IJERD)
 
Cj36511514
Cj36511514Cj36511514
Cj36511514
 
Face Recognition using PCA-Principal Component Analysis using MATLAB
Face Recognition using PCA-Principal Component Analysis using MATLABFace Recognition using PCA-Principal Component Analysis using MATLAB
Face Recognition using PCA-Principal Component Analysis using MATLAB
 
A Video Watermarking Scheme to Hinder Camcorder Piracy
A Video Watermarking Scheme to Hinder Camcorder PiracyA Video Watermarking Scheme to Hinder Camcorder Piracy
A Video Watermarking Scheme to Hinder Camcorder Piracy
 
maths mini project ( applictions of quadratic forms and SVD ).ppt
maths mini project ( applictions of quadratic forms and SVD ).pptmaths mini project ( applictions of quadratic forms and SVD ).ppt
maths mini project ( applictions of quadratic forms and SVD ).ppt
 
Iaetsd traffic sign recognition for advanced driver
Iaetsd traffic sign recognition for  advanced driverIaetsd traffic sign recognition for  advanced driver
Iaetsd traffic sign recognition for advanced driver
 
image compression in data compression
image compression in data compressionimage compression in data compression
image compression in data compression
 
Performance Analysis of Compression Techniques Using SVD, BTC, DCT and GP
Performance Analysis of Compression Techniques Using SVD, BTC, DCT and GPPerformance Analysis of Compression Techniques Using SVD, BTC, DCT and GP
Performance Analysis of Compression Techniques Using SVD, BTC, DCT and GP
 
B017120611
B017120611B017120611
B017120611
 
Image compression 14_04_2020 (1)
Image compression 14_04_2020 (1)Image compression 14_04_2020 (1)
Image compression 14_04_2020 (1)
 
Image quality assessment and statistical evaluation
Image quality assessment and statistical evaluationImage quality assessment and statistical evaluation
Image quality assessment and statistical evaluation
 
On image intensities, eigenfaces and LDA
On image intensities, eigenfaces and LDAOn image intensities, eigenfaces and LDA
On image intensities, eigenfaces and LDA
 
Scaling Transform Methods For Compressing a 2D Graphical image
Scaling Transform Methods For Compressing a 2D Graphical image Scaling Transform Methods For Compressing a 2D Graphical image
Scaling Transform Methods For Compressing a 2D Graphical image
 
Lecture 3
Lecture 3Lecture 3
Lecture 3
 
Performance Improvement of Vector Quantization with Bit-parallelism Hardware
Performance Improvement of Vector Quantization with Bit-parallelism HardwarePerformance Improvement of Vector Quantization with Bit-parallelism Hardware
Performance Improvement of Vector Quantization with Bit-parallelism Hardware
 
Multimedia lossy compression algorithms
Multimedia lossy compression algorithmsMultimedia lossy compression algorithms
Multimedia lossy compression algorithms
 

Recently uploaded

Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfKamal Acharya
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...Call Girls in Nagpur High Profile
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)simmis5
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...Call Girls in Nagpur High Profile
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINESIVASHANKAR N
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Call Girls in Nagpur High Profile
 
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordCCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordAsst.prof M.Gokilavani
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escortsranjana rawat
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingrknatarajan
 
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...roncy bisnoi
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdfKamal Acharya
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college projectTonystark477637
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesPrabhanshu Chaturvedi
 

Recently uploaded (20)

Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordCCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
 
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdf
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college project
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
 
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and RoutesRoadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and Properties
 

Singular Value Decomposition Image Compression

  • 1. Lossy Image Compression using SVD Coding Algorithm - K M Aishwarya
  • 2. Why is compression needed?  To store data efficiently  To transmit data efficiently  To save: • Memory • Bandwidth • Cost
  • 3. Why SVD?  Image compression alone can experience redundancies which can be overcome by Singular Value Decomposition (SVD) of the image matrix.  Image compression and coding techniques explore 3 types of redundancies: • Coding redundancy • Interpixel redundancy • Psycho-visual redundancy
  • 4. Howtocompress? Redundancies Coding Redundancy Neighboring pixels are not independent but correlated Interpixel Redundancy Also called spatial redundancy. Explored by predicting a pixel value based on the values of its neighbouring pixels Psycho-visual Redundancy Exists due to psychophysical aspects of human vision which prove that the human eye does not respond with equal sensitivity to all incoming visual information
  • 5. What is SVD?  Basic idea: Taking a high dimensional, highly variable set of data points and reducing it to a lower dimensional space that exposes the substructure of the original data more clearly and orders it from most variation to the least.  Definition: In linear algebra, the singular value decomposition is a factorization of a real or complex, square or non-square matrix. Consider a matrix A with m rows and n columns with rank r. Then A can be factorized into three matrices: A = USV T
  • 6. SVD – Overview I  Diagrammatically, where, • U is an m × m orthogonal matrix • VT is the conjugate transpose of the n × n orthogonal matrix. • S is an m × n diagonal matrix with non-negative real numbers on the diagonal which are known as the singular values of A. • The m columns of U and n columns of V are called the left- singular and right-singular vectors of A respectively. • The numbers σ1 2 ≥ … ≥ σr 2 are the eigenvalues of AA T and A T A.
  • 7. SVD – Overview II  SVD takes a matrix, square or non-square, and divides it into two orthogonal matrices and a diagonal matrix  Simply applying SVD on an image does not compress it  To compress an image, after applying SVD:  Retain the first few singular values (containing maximum image info)  Discard the lower singular values (containing negligible info)  The singular vectors form orthonormal bases, and the important relation A vi = si ui  shows that each right singular vectors is mapped onto the corresponding left singular vector, and the "magnification factor" is the corresponding singular value
  • 8. Mathematicalstepsto calculate SVD of a matrix 1. Given an input image matrix A. 2. First, calculate AA T and A T A. 3. Use AA T to find the eigenvalues and eigenvectors to form the columns of U: (AA T - ƛI) ẍ = 0. 4. Use A T A to find the eigenvalues and eigenvectors to form the columns of V: (A T A - ƛI) ẍ =0. 5. Divide each eigenvector by its magnitude to form the columns of U and V. 6. Take the square root of the eigenvalues to find the singular values, and arrange them in the diagonal matrix S in descending order: σ1 ≥ σ2 ≥ … ≥ σr ≥ 0 In MATLAB: [U,W,V]=svd(A,0)
  • 9. SVD Compression Measures  Parameters for quantitative and qualitative compression of image:  Compression Ratio (CR): CR = uncompressed image file size compressed image file size  Mean Square Error (MSE):  Signal to Noise Ratio (SNR): 𝑆𝑁𝑅 = 𝑃𝑠𝑖𝑔𝑛𝑎𝑙 𝑃𝑛𝑜𝑖𝑠𝑒 = 𝐴 𝑠𝑖𝑔𝑛𝑎𝑙 𝐴 𝑛𝑜𝑖𝑠𝑒 2  Peak Signal to Noise Ratio (PSNR): 𝑃𝑆𝑁𝑅 = 10𝑙𝑜𝑔10 𝑀𝐴𝑋𝐼 2 𝑀𝑆𝐸 = 20𝑙𝑜𝑔10 𝑀𝐴𝑋𝐼 𝑀𝑆𝐸
  • 10. Storage Space Calculations A = USV T 𝐴 = 𝑖=1 𝑟 𝜎𝑖 𝑢𝑖 𝑣𝑖 𝑇 𝐴 𝑘 = 𝜎1 𝑢1 𝑣1 𝑇 + 𝜎2 𝑢2 𝑣2 𝑇 + . . . + 𝜎𝑟 𝑢 𝑟 𝑣𝑟 𝑇  When performing SVD compression, the sum is not performed to the very last Singular Values (SV’s); the SV’s with small enough values are dropped. The values which fall outside the required rank are equated to zero. The closet matrix of rank k is obtained by truncating those sums after the first k terms: 𝐴 𝑘 = 𝜎1 𝑢1 𝑣1 𝑇 + 𝜎2 𝑢2 𝑣2 𝑇 + . . . + 𝜎 𝑘 𝑢 𝑘 𝑣 𝑘 𝑇  Total storage for 𝐴 𝑘 will be: 𝐴 𝑘 = 𝑘(𝑚 + 𝑛 + 1)  The digital image corresponding to 𝐴 𝑘 will still have very close resemblance to the original image
  • 11. Lowest rank-k approximations  Since σ1 > · · · > σn > 0 , in the singular matrix, the first term of this series will have the largest impact on the total sum, followed by the second term, then the third term, etc.  This means we can approximate the matrix A by adding only the first few terms of the series.  As k increases, the image quality increases, but so too does the amount of memory needed to store the image. This means smaller ranked SVD approximations are preferable.  Hence k is limit bound to ensure SVD compressed image occupies lesser space than original image. Necessary condition: 𝒌 < 𝒎𝒏 𝒎+𝒏+𝟏
  • 12. Examplesof SVD compressionin MATLAB Original Image: Rank of image = 202 𝐴 𝑘 = 31840 CR = 0.580
  • 13. SVDcompressedimagesfordifferentvaluesofk Ak = 30796 Ak = 31679 CR = 61.046 CR = 23.588 k = 2 k = 12 Ak = 31699 Ak = 31781 CR = 12.101 CR = 5.72 k = 22 k = 52
  • 14. Observation & Inference  k represents the number of Eigen values used in the reconstruction of the compressed image  Smaller the value of k, more is the compression ratio but image quality deteriorates  As the value of k increases, image quality improves (i.e. smaller MSE & larger PSNR) but more storage space is required to store the compressed image  When k is equal to the rank of the image matrix (202 here), the reconstructed image is almost same as the original one
  • 15. Conclusion  SVD's applications in world of image and data compression are very useful and resource-saving.  SVD allows us to arrange the portions of a matrix in order of importance. The most important singular values will produce the most important unit eigenvectors.  We can eliminate large portions of our matrix without losing quality. • Therefore, an optimum value for 'k' must be chosen, with an acceptable error, which conveys most of the information contained in the original image, and has an acceptable file size too.