An Introduction To Face Detection and Recognition
An Introduction To Face Detection and Recognition
100
80
60
40
20
0
Face OR Skin Face AND Skin Face Skin
100
80
60
40
20
0
Face OR Skin Face AND Skin Face Skin
100
80
60
40
20
0
Face OR Skin Face AND Skin Face Skin
100
80
60
40
20
0
Face OR Skin Face AND Skin Face Skin
100
80
60
40
20
0
Face OR Skin Face AND Skin Face Skin
“Rectangle filters”
Value =
∑ (pixels in white area) –
∑ (pixels in black area)
Example
Source
Result
Fast computation with integral images
• The integral image computes
a value at each pixel (x,y)
that is the sum of the pixel
values above and to the left (x,y)
of (x,y), inclusive
• This can quickly be
computed in one pass
through the image
Computing the integral image
Computing the integral image
ii(x, y-1)
s(x-1, y)
i(x, y)
-1 +1
+2 -2
-1 +1
Feature selection
• For a 24x24 detection region, the number of possible rectangle
features is ~160,000!
Feature selection
• For a 24x24 detection region, the number of possible rectangle
features is ~160,000!
• At test time, it is impractical to evaluate the entire feature set
• Can we create a good classifier using just a small subset of all possible
features?
• How to select such a subset?
Boosting
• Boosting is a classification scheme that works by combining weak
learners into a more accurate ensemble classifier
• A weak learner need only do better than chance
• Training consists of multiple boosting rounds
• During each boosting round, we select a weak learner that does well on
examples that were hard for the previous weak learners
• “Hardness” is captured by weights attached to training examples
• Store a template
• Predefined: based on edges or regions
• Deformable: based on facial contours
(e.g., Snakes)
• Templates are hand-coded (not
learned)
• Use correlation to locate faces
Template-Based Methods: Summary
• Pros:
• Simple
• Cons:
• Templates needs to be initialized near the face images
• Difficult to enumerate templates for different poses (similar to knowledge-
based methods)
Appearance-Based Methods: Classifiers
• Neural network
• Multilayer Perceptrons
• Principal Component Analysis (PCA), Factor Analysis
• Support vector machine (SVM)
• Mixture of PCA, Mixture of factor analyzers
• Distribution Distribution-based method
• Naïve Bayes classifier
• Hidden Markov model
• Sparse network of winnows (SNoW)
• Kullback relative information
• Inductive learning: C4.5
• Adaboost
• …
Face and Non-Face Exemplars
• Positive examples:
• Get as much variation as possible
• Manually crop and normalize each face image into a standard size(e.g., 19×19
• Creating virtual examples [Poggio 94]
• Negative examples: Fuzzy idea
• Any images that do not contain faces
• A large image subspace
• Bootstraping[Sung and Poggio 94]
Exhaustive Search
• Across scales
• Across locations
What is Face Recognition?
• A set of two task:
• Face Identification: Given a face image that belongs to a person in a database,
tell whose image it is.
• Face Verification: Given a face image that might not belong to the database,
verify whether it is from the person it is claimed to be in the database.
Difference between Face Detection and
Recognition
• Detection – two-class classification
• Face vs. Non-face
• Recognition – multi-class classification
• One person vs. all the others
Applications of Face Recognition
• Access Control
• Face Databases
• Face ID
• HCI - Human Computer
Interaction
• Law Enforcement
Applications of Face Recognition
• Multimedia Management
• Security
• Smart Cards
• Surveillance
• Others
Different Approaches
• Features:
• Features from global appearance
• Principal Component Analysis(PCA)
• Independent Component Analysis(ICA)
• Features from local regions
• Local Feature Analysis(LFA)
• Gabor Wavelet
• Similarity Measure
• Euclidian Distance
• Neural Networks
• Elastic Graph Matching
• Template Matching
• …
Face Recognition
using
PCA (Eigenfaces) and LDA (Fisherfaces)
Example
1
2
1 2 3 3
3 1 2 3
1
4 5 1 33
2
4
5
1
91
Average Image and Difference Images
• The average training set is defined by
m= (1/m) ∑mi=1 xi
ri = xi – m
Covariance Matrix
• The covariance matrix is constructed as
Example
2 1 1 1
1 2 1 3 1
Eigenvectors of Covariance Matrix
• The eigenvectors vi of ATA are:
• Recognition process:
• IF Є≥Өc
then input image is not a face image;
• IF Є<Өc AND Єk≥Өc for all k
then input image contains an unknown face;
• IF Є<Өc AND Єk*=mink{ Єk} < Өc
then input image contains the face of individual k*
Limitations of Eigenfaces Approach
• Expression
- Change in feature location and shape.
Linear Discriminant Analysis
• PCA does not use class information
• PCA projections are optimal for reconstruction from a
low dimensional basis, they may not be optimal from a
discrimination standpoint.
1 k
mi x j
k j 1
• Now, the mean image m of all the classes in the database can be
calculated as:
1 c
m mi
c i 1
Scatter Matrices
c
S B N i ( m i m )( m i m ) T
i 1
Multiple Discriminant Analysis
^ |W T SBW |
W argmax J(W )
|W T SW W |
• Each face image xj Xi can be projected into this face space by the operation
pi = WT(xj – m)
Testing