SUBMITTED BY :
NAVEEN KUMAR
M.E.(ECE), 2011(REGULAR)
ROLL NO. : 112610
   Data is not the same thing as information.
   Data is the means with which information is
    expressed. The amount of data can be much larger
    than the amount of information.
   Data that provide no relevant information =
    redundant data or redundancy.
       Image coding or compression has a goal to reduce the
      amount of data by reducing the amount of redundancy
 n1 = data.
 n2 = data − redundancy (i.e., data after
  compression).
 Compression ratio = CR = n1/n2

Relative redundancy = RD = 1 − 1/CR
CR Coding Redundancy.
IR Interpixel Redundancy.
PVR Psycho-Visual Redundancy
Image compression can be:
 Reversible (loss less), with no loss of information.
       A new image is identical to the original image (after
        decompression).
       Reversibility is necessary in most image analysis applications.
       The compression ratio is typically 2 to 10 times.
       Examples are Huffman coding and run-length coding.
   Non reversible (lossy), with loss of some information.
       Lossy compression is often used in image communication,
        video,WWW, etc.
       It is usually important that the image visually is still nice.
       The compression ratio is typically 10 to 30 times.
 There is often correlation between adjacent
  pixels, i.e., the value of the neighbors of an
  observed pixel can often be predicted from the
  value of the observed pixel.
 Coding methods:
     Run-Length coding.
     Difference coding
   Every code word is made up of a pair (g, l) where g is the gray
    level, and l is the number of pixels with that gray level (length,
    or “run”).
   E.g.,
        56 56 56 82 82 82 83 80
        56 56 56 56 56 80 80 80
    creates the run-length code (56, 3)(82, 3)(83, 1)(80, 4)(56, 5).
   The code is calculated row by row.


   Very efficient coding for binary data.
   Important to know position, and the image dimensions must
    be stored with the coded image.
   Used in most fax machines.la University) Image Coding an
Compression Achieved
Original image requires 3 bits per pixel (in total - 8x8x3=192 bits).
Compressed image has 29 runs and needs 3+3=6 bits per
run (in total - 174 bits or 2.72 bits per pixel).
   f (xi ) =        Xi        if i = 0,
                     xi − xi-1 if i > 0

   E.g.,
     original    56 56 56 82 82 82 83 80 80 80 80
     Code f(xi ) 56 0 0 26 0 0 1 −3 0 0 0
   The code is calculated rob by row.



   Both run-length coding, and difference coding are
    reversible, and can be combined with, e.g., Huffman
    coding
   Requires no priori knowledge of pixel probability
    distribution values.

   Assigns fixed length code words to variable
    length sequences.

   Patented Algorithm US 4,558,302

   Included in GIF and TIFF and PDF file formats
39   39   126      126
                                        As the encoder examines image pixels,
39   39   126      126                  gray level sequences (i.e., blocks) that are
                                        not in the dictionary are assigned to a new
39   39   126      126                  entry.
39   39   126      126


          Dictionary Location   Entry

             0                   0          - Is 39 in the dictionary……..Yes
             1                   1          - What about 39-39………….No
             .                   .
                                            - Then add 39-39 in entry 256
             255                 255
             256                 -
                                39-39

             511                 -
 A predictive coding approach.
 Each pixel value (except at the boundaries) is
  predicted based on its neighbors (e.g., linear
  combination) to get a predicted image.
 The difference between the original and
  predicted images yields a differential or residual
  image.
       i.e., has much less dynamic range of pixel values.
   The differential image is encoded using Huffman
    coding.
 Digital Image Processing by Gonzalez &
  Woods
 web.uettaxila.edu.pk/CMS/.../notes/Image
  %20Compression.ppt
 hpourreza.profcms.um.ac.ir/imagesm/196/.../c
  h08-compression.ppt
 discovery.bits-
  pilani.ac.in/discipline/physics/.../compression-
  II.ppt

Interpixel redundancy

  • 1.
    SUBMITTED BY : NAVEENKUMAR M.E.(ECE), 2011(REGULAR) ROLL NO. : 112610
  • 2.
    Data is not the same thing as information.  Data is the means with which information is expressed. The amount of data can be much larger than the amount of information.  Data that provide no relevant information = redundant data or redundancy. Image coding or compression has a goal to reduce the amount of data by reducing the amount of redundancy
  • 3.
     n1 =data.  n2 = data − redundancy (i.e., data after compression).  Compression ratio = CR = n1/n2 Relative redundancy = RD = 1 − 1/CR
  • 4.
    CR Coding Redundancy. IRInterpixel Redundancy. PVR Psycho-Visual Redundancy
  • 6.
    Image compression canbe:  Reversible (loss less), with no loss of information.  A new image is identical to the original image (after decompression).  Reversibility is necessary in most image analysis applications.  The compression ratio is typically 2 to 10 times.  Examples are Huffman coding and run-length coding.  Non reversible (lossy), with loss of some information.  Lossy compression is often used in image communication, video,WWW, etc.  It is usually important that the image visually is still nice.  The compression ratio is typically 10 to 30 times.
  • 7.
     There isoften correlation between adjacent pixels, i.e., the value of the neighbors of an observed pixel can often be predicted from the value of the observed pixel.  Coding methods:  Run-Length coding.  Difference coding
  • 8.
    Every code word is made up of a pair (g, l) where g is the gray level, and l is the number of pixels with that gray level (length, or “run”).  E.g., 56 56 56 82 82 82 83 80 56 56 56 56 56 80 80 80 creates the run-length code (56, 3)(82, 3)(83, 1)(80, 4)(56, 5).  The code is calculated row by row.  Very efficient coding for binary data.  Important to know position, and the image dimensions must be stored with the coded image.  Used in most fax machines.la University) Image Coding an
  • 11.
    Compression Achieved Original imagerequires 3 bits per pixel (in total - 8x8x3=192 bits). Compressed image has 29 runs and needs 3+3=6 bits per run (in total - 174 bits or 2.72 bits per pixel).
  • 12.
    f (xi ) = Xi if i = 0, xi − xi-1 if i > 0  E.g., original 56 56 56 82 82 82 83 80 80 80 80 Code f(xi ) 56 0 0 26 0 0 1 −3 0 0 0  The code is calculated rob by row.  Both run-length coding, and difference coding are reversible, and can be combined with, e.g., Huffman coding
  • 14.
    Requires no priori knowledge of pixel probability distribution values.  Assigns fixed length code words to variable length sequences.  Patented Algorithm US 4,558,302  Included in GIF and TIFF and PDF file formats
  • 15.
    39 39 126 126 As the encoder examines image pixels, 39 39 126 126 gray level sequences (i.e., blocks) that are not in the dictionary are assigned to a new 39 39 126 126 entry. 39 39 126 126 Dictionary Location Entry 0 0 - Is 39 in the dictionary……..Yes 1 1 - What about 39-39………….No . . - Then add 39-39 in entry 256 255 255 256 - 39-39 511 -
  • 16.
     A predictivecoding approach.  Each pixel value (except at the boundaries) is predicted based on its neighbors (e.g., linear combination) to get a predicted image.  The difference between the original and predicted images yields a differential or residual image.  i.e., has much less dynamic range of pixel values.  The differential image is encoded using Huffman coding.
  • 17.
     Digital ImageProcessing by Gonzalez & Woods  web.uettaxila.edu.pk/CMS/.../notes/Image %20Compression.ppt  hpourreza.profcms.um.ac.ir/imagesm/196/.../c h08-compression.ppt  discovery.bits- pilani.ac.in/discipline/physics/.../compression- II.ppt