Skip to content

🔎 Facial detection and recognition using PCA and LDA for feature extraction and SVM for classification

Notifications You must be signed in to change notification settings

filipbagen/facial-recognition

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

66 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Facial Detection and Recognition

Overview

This project, part of Linköping University’s Advanced Image Processing (TNM034) course, implemented facial recognition using image processing and machine learning. The program utilized the Caltech Faces Dataset 1999 and it trained a model to identify 16 out of 27 individuals, assigning each a unique ID. The program recognized faces within its training set and labels unknown faces as ‘0’. It integrates techniques like the Viola-Jones algorithm for detection, PCA and LDA for feature extraction and SVM for classification.

Methods

  • Image Processing: Involves manual feature extraction and comparison.
  • Machine Learning: Uses the Viola-Jones algorithm for face detection and SVM for classification.
  • Image Degradation: To test accuracy with varied data, the program applies a random rotation (±5 degrees), scaling (±10%), and brightness adjustment (±15%) to the input image.

Datasets

  • DB1: Contains images for recognition.
  • DB2: Provides images with different backgrounds and lighting for testing robustness.

Results

Model Accuracy DB1 Accuracy DB2
Fisherfaces 93.75% 89.47%
Eigenfaces 25% 2.63%

Technologies

  • MATLAB with Computer Vision and Image Processing Toolboxes.
  • Principal Component Analysis (PCA) and Fisher Linear Discriminant (FLD) for feature reduction and classification.

Usage

To run the program:

  1. Set the MATLAB working directory to the source directory
  2. Execute the command id = tnm034(image, method);

Where:

  • image: The face image for recognition (from DB1 or DB2).
  • method: The recognition method (‘fisherface’ or ‘eigenface’).
  • id: The output, representing the recognized person’s ID (1-16) or 0 for unknown faces.

About

🔎 Facial detection and recognition using PCA and LDA for feature extraction and SVM for classification

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages