File Exchange

image thumbnail

Image Compression

version (10.5 KB) by Luigi Rosa
Demo source code for image compression.


Updated 20 Apr 2004

View License

Image Compression

A collection of simple routines for image compression using different techniques.

Image compression Using Block Truncation Coding.

Image compression based on Gaussian Pyramids.

Image compression based on Discrete Cosine Transform.

Image compression based on Singular Value Decomposition.

The given codes can be also used in 2D noise suppression.

The function "conv2fft" performs a 2D FFT-based convolution.
Type "help conv2fft" on MATLAB command window for more informations.

For a more detailed description see:

Ohad Gal's file submission

Vallabha Hampiholi's file submission

Type "helpwin functionname" on MATLAB command window to see the references and how to use these functions.

Please contribute if you find this software useful.
Report bugs to

Luigi Rosa
Via Centrale 27
67042 Civita di Bagno
L'Aquila --- ITALY
mobile +39 340 3463208


Cite As

Luigi Rosa (2021). Image Compression (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (29)

syed faysal

Can you please send me the code of Image compression "Compressive sensing using SRM'. I will be grateful
my Email:

Yon Xing Chai

can i have to code by using DCT? thanks, my email is


can u please send me the code for image compression by using 'SVD'.


can you send me the information about image compression by using 'svd'
which is useful for my project.thanq!

Hoang Hon Suong


Anthony Kwo

Thanks, i can learn a lot from your code

Zeeshan Alam

Hi there
i want image compression code..?

sonam sharma

Fatma Amer

good job


how to view the code


hello i am doing a project on microarray image compression using svd can you please help me with the code
thank u
my email id is


i want to do thesis in image compression....i dnt have much knowledge od image compression can any 1 guide id is

subhash chandra


eman nasaar


subathra suba

sure geo

Berat Dogan

final image "im" is a floating point image...I am not sure if it is a real compression..

Ganesh AS

why haveu messed up the ct based compression? why have u squared the array? its completely unnecessary..

dwi pramestya


abebe gemeda

I will be very happy

Alvise Sommariva

A good implementation. Highly suggested for a good lesson on SVD.

sivaji m

very good


very good code source

kanaga valli

jhhtgf bvggbv

venkateswararao arvapalli

Rod Smith

i prefer optimize Image compression tool at


please, if you work in SPIHT send me

Luigi Rosa

Download here the functions used to perform FFT-based 2D and 1D convolution:

MATLAB Release Compatibility
Created with R13
Compatible with any release
Platform Compatibility
Windows macOS Linux

Inspired by: JPEG Compression, Lossy Image Compression

Inspired: Manchester

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!