ECE 563 Assignment 5
Images and m-files for this assignment may be downloaded from
impro5.zip and MacbethColor.zip.
Read Section 11.4 (p 842-852) on principal components. See also
the routine princomp.m from DIPUM.
- Select a color photograph with bright colors.
- Find its principal component transformation.
Show the resulting transformed images (scaled), their eigenvalues, and eigenvectors.
- Use the co-occurance histogram method in cohist.m from the handout
for the pairs (RG, RB, and GB) for your color photograph.
- Run
rgbcube.m
. Rotate the cube to center the body diagonal with the red-green-blue
primary faces showing, and capture a screen shot. Why are the interior edges of the cube so obvious?
- For the three images in MacbethColor.zip and your own image,
- Find the mean RGB values for each of the 24 squares.
- Find the mean and rms of the grayscale squares (19-24) in the bottom row of the
four Macbeth color images. Plot the mean value vs. Y using values from
MacbethGray.xls. Find the best-fitting power-law exponent for each image.
- Plot your measured RGB values for the Macbeth chart images with the "true" values
in the speadsheet. Find a linear transformation (RGB_corrected = C * (RGB_uncorrected) to
perform a color correction. Calculate the rms difference for the color squares before and
after correction. Note that there are two images of the Macbeth chart, one with a digital
camera and one with a scanner. Which device had better color correction?
- Find an equation for the perimeter of the binary polygon images generated in assignment 3.
Measure the perimeter length using bwperim.
Compare the results to the theoretical values for the perimeter.
- Correct the spatial variations in the image uneven.tif
by fitting
z = a0 + a1 x + a2 y + a3 rsq
where x is a x-ramp image (0-1), y is a y-ramp image (0-1),
and rsq is a quadratic ramp rsq = x.*x+y.*y. Determine the
coefficients, subtract the fitted image from the test image, display the
scaled difference image, and calculate the rms residual difference.
Reference: Bernd Jahne, Digital Image Processing,
4th Ed., Springer, 1997. p. 229.
- Repeat the fit described above on the image c_backgr.tif. Divide the fitted
image point-by-point into the image c_inhomo.tif. Threshold the resulting image to allow
bwlabel to count the number of dark and light dust particles.
Reference: Bernd Jahne, Digital Image Processing,
4th Ed., Springer, 1997. p. 236.
Maintained by John Loomis,
last updated 29 Feb 2016