Friday, 20 April 2012

JPEG vs JPEG 2000

Assalamualaikum. Hello readers, balqis here. This time, I would like to discuss the comparison between JPEG and JPEG 2000. Have you ever heard about JPEG? What is JPEG? JPEG stands for 'Joint Photographic Experts Group'. It is a standard method of compressing photographic images. The file extensions for this format are .JPEG, .JFIF, .JPG, OR .JPE although .JPG is the most common on all platforms. JPEG format enable lossless compression. Example of lossless compression technique are Huffman coding, run-length coding, and many more.



Here, I put some of the jpeg compression implementation code. To implement basic JPEG compression using only basic Matlab functions. .  This included going from a basic grayscale bitmap image all the way to a fully encoded file readable by standard image readers.

Step1:  Converting the base image to 8x8 matrices, DCT transform, quantizing
Step 2:  Zig-Zag Encoding of Quantized Matrices.
Step 3:  Conversion of quantized vectors into the JPEG defined bitstream
Step 4:  Construction of the JPEG File header, Writing the File

Lets try this :)







You must wonder, what is Huffman coding right? Emm, Huffman code, developed by D. Huffman in 1952, is a popular technique for removing coding redundancy. The result after Huffman coding is variable length code, where the code words are unequal length. Lets see, the Huffman example :)






Then, JPEG 2000 was introduced. But why they introduce JPEG 2000 and what is the difference between JPEG  and JPEG 2000?   Ok, let me explain it one by one. To be able to manipulate more and more data, image compression must not only reduce the necessary storage and bandwidth requirements, but also allow extraction for editing, processing, and targeting particular devices and applications.

The JPEG-2000 image compression system has a rate-distortion advantage over the original JPEG. More importantly, it also allows extraction of different resolutions, pixel fidelities, regions of interest, components, and more, all from a single compressed bitstream.



To be shortened, let me list the advantages of JPEG 2000 over JPEG :)

  • JPEG 2000 advantage is it offers both lossy and lossless compression at the same time while JPEG usually utilize lossless compression.
  • JPEG 2000 format includes much richer content than existing JPEG files.
  • JPEG 2000 can display an image at different resolution and size from the same image file.

Below is the differences of JPEG and JPEG 2000. Can you spot the differences? 



That's a little bit explanation about JPEG and JPEG 2000. Don't forget to read our previous post by Raihan entitled Image Enhancement. Have a nice day.



References:
  1. http://www.verypdf.com/pdfinfoeditor/jpeg-jpeg-2000-comparison.htm
  2. http://www.photozone.de/jpeg2000-vs-jpeg-vs-tiff
  3. http://ce.sharif.ac.ir/courses/84-85/2/ce342/resources/root/Lecture%20Notes/dcc2000_jpeg2000_note.pdf



Monday, 9 April 2012

Image Enhancement

Hello readers... this week we are back with new topic in Image Processing which is: Image Processing in Spatial Domain and Frequency Domain.

Why we need to enhance image???
It is because  it improves the interpret-ability or perception of information in images for human viewers. It is also providing better input for other automated image processing techniques

Now, let's take a look about what it is all about with these two different domains..


Spatial Domain
Frequency Domain
2D function f(x,y) represents pixel values
2D function f(x,y) represents frequency values
Techniques that operate directly on pixels
Techniques are based on modifying the Fourier Transform (FT) of an image.
The computational cost of filtering depends on filter size
Cost-filtering is fixed (not-dependant on size of the equivalent spatial domain convolution filter)
Changes in pixel positions correspond to changes in scene.
Changes in image position correspond to changes into spatial frequency
General model:
g(x,y) = h(x,y) * f(x,y) + n(x,y)
g(x,y) = Degraded image
h(x,y) = Degradation function
f(x,y) = Original image
n(x,y) = Additive noise function
General model:
G(u,v) = H(u,v) *F(u,v) + N(u,v)
G(u,v) = FT of degraded image
H(u,v) = FT of degradation function
F(u,v) = FT of original image
N(u,v) = FT of noise function





Do you ever know how to determine the frequency of one particular image???
What do frequencies mean in an image ??








Related Posts Plugin for WordPress, Blogger...