PCA-Based Face Recognition Using Eigenface Methodology

Resource Overview

Implementation of PCA-based face recognition (Eigenface) involving reading 20 training images, computing mean vectors, covariance matrices, eigenvalues and eigenvectors with timing measurements, displaying Eigenfaces in figure(i). Processing 4 test images with reconstruction in feature space, displaying original vs reconstructed images in figure(i) and figure(10+i) respectively. Calculating reconstruction errors for test images with comparative analysis of differences and underlying causes.

Detailed Documentation

In this study, we implement Principal Component Analysis (PCA)-based face recognition technology, commonly known as the Eigenface method. The implementation begins by loading 20 training images into our MATLAB workspace using imread() function. We then compute the mean face vector by averaging all training images pixel-wise, followed by calculation of the covariance matrix through vectorized operations. The eigenvalue decomposition is performed using MATLAB's eig() or svd() functions to extract eigenvalues and eigenvectors, with computational time recorded using tic-toc commands for performance benchmarking.

For model validation, we process 4 test images by projecting them onto the PCA subspace using dot products with dominant eigenvectors. The reconstruction process involves inverse transformation from feature space back to image space. We visualize comparative results by displaying original test images and their reconstructions in separate figures (figure(i) and figure(10+i)) using subplot() and imshow() functions. Reconstruction error is quantified using Mean Squared Error (MSE) metric computed between original and reconstructed images pixel-wise. Our analysis reveals varying error magnitudes across test images, which we attribute to factors such as lighting variations, facial expression differences, and alignment discrepancies not fully captured during training. The implementation provides practical insights into PCA's dimensionality reduction capabilities and reconstruction limitations in facial recognition systems.