Lab Report

In your lab write-up, include an introduction and conclusion, keeping in mind the following general points:

Also answer the following questions:

Questions

Answer the following questions, and include question in your report to identify which part of your report answers which question. As usual, submit your completed programs through email.
  1. Provide the entropy values, the total number of runs, the run-length entropy and the total number of bits per pixel for all the test images (including the 8 bitplane images). Provide plots of the histograms for all test images in all the parts, i.e.

    In part 3, also give the total number of bits per pixel for all the bit plane images of lena combined. Note that in part 3, you are plotting the histogram of the run-lengths. Arrange the x axis of the plot such that it reflects run length size.

    All these plots can be easily done by MATLAB, use your experience from previous labs in generating these plots.

  2. From your results in Part 1, can you deduce a noticable correlation between entropy and the shape of the histogram? Do you think your conclusion is true in general?
  3. From your results in part 2, what can you say in general about what type of images compress the best? Compare the entropies of lenaerrdiff.raw and weaskedforit.raw? Why do you think one is easier to compress than the other? Answer this both in terms of histograms and general shape of the image (i.e. one is smoother than the other for the most part)
  4. Which bit plane when run length coded provides for the most efficient compression? Which bit plane provides for the least efficiency? Why?
  5. Compare the entropy results from part 4 and part 1 for both Lena and Baboon images, Why do you think predictive coding performs much better than "straightforward-brute force" coding ? (this is what is done essentially in part 1) . Note: The idea of predictive coding is one of the earliest and basic ideas in compression. DPCM scheme is based on this idea.
  6. Could run-length coding of a bi-level image ever result in an expansion of the image in terms of bits per pixel? Why not/why? You do not need to give mathematical proofs, intuitive explanation is sufficient.
  7. Are there 8-bit images for which run-length encoding each bit plane separately takes as many or more bits than Huffman coding done on the 256-level image as in Part 1? Hint: compare the total of your results from part 3 with your result for the lena image in Part 1.