Lab 3

Original image

Contrasted image

Thresholded image

Original image

Contrasted image

Thresholded image

Original image

Contrasted image

Thresholded image

Source Code

Homework 3

1)

  1. If our 8-connected neighborhood is made up of pixels A-I arranged like so:
  2. such that each pixel has a value of a-i between 0 and 255, then our 3x3 mask to calculate the value of E would be

    and we would calculate the value for E as the sum of all those numbers.
  3. Using a mask like this on every pixel we can apply a blur operator.
  4. We have lost some information, as the image will have less clearly defined edges. Although we could recover some of that information using some sort of sharpening algorithm, It would be very difficult to get back to our original image.
  5. A weighted version of the mask would look something like so:

2) The martian is about 1.8 feet straight ahead from the robot and 2 feet to the left of the center line between the cameras. That means the alien is a total of 2.7 feet away from right in between the lenses of the camera.