COMP 776 Spring 2008
Assignment 3: Eigenfaces for recognition
Due date: April 17 before beginning of class
The goal of the assignment is to implement a nearest-neighbor face recognition algorithm based on Eigenfaces
as discussed in the April 8 lecture (PowerPoint,
PDF). We will be using a database consisting
of 10 images each of 40 different people. The image resolution is 32x32, corresponding to the extrinsic
dimension of 1024. The task is to correctly identify the person from a test image using a low-dimensional
eigenface representation.
Homework materials
Here are the materials, including the face database
(from here), training and test indices,
and sample code.
Directions
- Load the face database and partition it into training and test sets (this is already done in the sample
code provided for the assignment). We will be using 7 images per person for training and 3 images for testing.
- Find the mean face image. Perform PCA on the training faces and extract top K components. Use the MATLAB
princomp function.
- Compute its K-dimensional projection of the test images onto the face space.
- For each test image, find the training image that is ``closest'' (in the sense of Euclidean distance)
to the test image in the face space, and assign the label (person index) of the training image
to the test image.
What to hand in
- The picture of the mean face and top 20 eigenfaces computed by PCA.
- A plot of the nearest-neighbor classification rate as a function of K. You can choose any sampling of values K from 1 to 1024,
as long as it captures the trend of how classification performance changes as a function of K (i.e., we expect
performance to be poor for extremely low K, but then to rise very rapidly and level off at some point).
- Pictures of incorrectly classified faces and their nearest neighbors from the training set for K=100.
The sample code can be easily adapted to do this.
- As usual, include your MATLAB code and a brief report addressing the above issues.
For bonus points
- Extract a few 32x32 patches from non-face images and
investigate their behavior when they are projected onto the ``face space.'' Project these patches
onto the face space for different values of K, and display the reconstructed versions of these patches,
along with the reconstruction errors. Compare the reconstruction errors to those for face images from
the database. You can also try it with 32x32 face patches not from the database. Try to decide what
threshold on the reconstruction error can distinguish between face and non-face images.
|