Computer Science 101: Lab #9

In this lab we'll have a chance to revisit some of the imaging work from Lab #6 and related concepts from the lecture notes. As usual, there are some differences between what we'll do and what is mentioned in the book. So please read the following carefully as you progress through the lab, before asking me a question about why something doesn't work. Also, we have a short lab today, so don't panic if you don't get through the whole chapter. Do as many of the Do This: exercises as you can, then answer the two questions below for your writeup (and of course send me any videos as well):

Question 9.1 Comparing a few PNG and JPG images, what is the average compression ratio you're getting with JPEG?

Question 9.2 When you do myColor = pickAColor(), you'll see the kind of color-wheel / settings dialog we talked about in class. As you move around in the wheel or change the Hue/Saturation/Value or Red/Green/Blue settings, the “Color name“ at the bottom changes. Explain the contents of this “name”.  Hint: You may want to review Question 1.2 from the first lab.

Question 9.3 Why do we add or subtract 1 to/from certain values, as in MAX+1 in the program at the top of p. 189, and the for x in range(1,X-1): in the code at the top of p. 194?