Face Identification Based on Contrast Limited Adaptive

Transcription

Face Identification Based on Contrast Limited Adaptive
Face Identification Based on Contrast Limited Adaptive Histogram
Equalization (CLAHE).
Gibran Benitez-Garcia, Jesus Olivares-Mercado, Gualberto Aguilar-Torres,
Gabriel Sanchez-Perez and Hector Perez-Meana
Mechanical and Electrical Engineering School of National Polytechnic
Institute of Mexico. Mexico, Mexico D.F.
Abstract— This paper proposes a face identification method
based on Contrast Limited Adaptive Histogram Equalization (CLAHE) robust to facial expressions, occlusion and
specially to illumination changes. Based on Eigenphases
algorithm for feature extraction, the Principal Components
Analysis (PCA) and the Phase Spectrum was used as feature
extraction stage, and Support Vector Machine (SVM) as a
classifier. The results were obtained using a database that
includes face images of 120 subjects (60 males and 60
females) with illumination changes, facial expressions and
partial occlusion. The proposed method provides results with
a correct recognition up to 97%.
Keywords: Face Identification, CLAHE, Eigenphases and SVM.
1. Introduction
In business and personal life today, security protection
systems are critical for many application domains: transaction protection, access control, computer and network
security, and most important, personal and public safety.
Since the tragic terrorist attacks of September 11, 2001,
there has been a greater awareness of security threats and
increased acceptance of more intrusive security systems [1].
Biometrics systems are a solution for this problem, because are automated methods of verifying or identifying the
identity of a person on the basis of some physiological or
behavior characteristic [1].
It is important to consider the difference among identification and verification. Identification is when the system
output determines the identity of the person with the highest
approximation among a set of known persons (saved in the
database) and verification is when the system determines if
the person is whom he/she claims to be.
The biometric identification and verification methods can
be divided in two categories: behavioral methods such as
signatures, keyboard typing, and voice print; and physiological methods such as fingerprint, iris pattern, palm geometry,
DNA, and facial features [2].
The general structure of biometric system basically consists of a capture stage, when the pattern (either physiological or behavioral) is captured, a feature extraction stage,
when the pattern will be converted in a vector feature,
and the classification stage when generate templates based
on vectors features, and the system compares and decides
whether the extracted features vector agrees or disagrees
with the estimated template, Fig. 1 shows this structure.
Fig. 1: General structure of biometric system.
In particular the face recognition has been a topic of active
research because the face is the most direct way to recognize
people [3]. Additionally, the data acquisition of this method
consists in taking a picture, this doing the face recognition
one of the biometric methods with larger acceptance among
the users.
Over the past two decades, the problem of face recognition
has attracted substantial attention from various disciplines
and has witnessed an impressive growth in basic and applied research, product development, and applications. Face
recognition systems have already been deployed at ports of
entry at international airports such as Australia and Portugal
[4].
In recent years, there have been proposed different face
recognition methods to improve the identification accuracy
[1], [3], [4]. However, the variations in face images used in
systems decreases the accuracy drastically. These variations
arise mainly from changes in facial expressions, as well as
illumination conditions in which they are, and in some cases
partial occlusion.
M. Savvides et al proposed the Eigenphases algorithm
[5], which focused on feature extraction stage, reduces the
illumination problems that affect the recognition of faces, as
it uses the phase extracted from the Fast Fourier Transform
together with Principal Components Analysis (PCA) to
obtain the main features of that stage. A variation of this
method is to include a pre-processing stage in which the
face images is adapted, to insert an "enhanced image" in
the stage of feature extraction, histogram equalization [6]
and the normalization of an image [7] are some methods to
adjust the images on the pre-processing stage.
This paper proposes a face identification algorithm using Contrast Limited Adaptive Histogram Equalization
(CLAHE) in the pre-processing stage to enhance the illumination of the face images, the PCA and the Phase Spectrum
are used in the features extraction stage, and the Support
Vector Machine (SVM) as classifier. The results obtained
with the proposed method are compared with Eigenphases
[5] and Eigenphases using Histogram Equalization [6].
The proposed and conventional methods are evaluated
under the same conditions, using a face database created in
the National Polytechnic Institute of Mexico which includes
24 face images of 120 subjects with different illumination,
facial expressions variations and partial occlusion.
2. Proposed System
The proposed algorithm for face identification is shown in
Fig. 2, the system output provides the identity of one person
among all, that are in the database.
nk
k = 0, 1, 2, . . . , L − 1
(2)
MN
Loosely speaking pr (rk ) is an estimated of the probability
of occurrence of intensity level rk in an image. The sum of
all components of normalized histogram is equal to 1.
The histogram equalization is a method in image processing of contrast adjustment using the image’s histogram.
This method usually increases the global contrast of many
images, through transforming the original image histogram
to a uniform histogram, that is, trying to make uniform
the distribution intensity pixels of the image. The histogram
equalization is obtained by next equation:
pr (rk ) =
sk = (L − 1)
k
X
pr (rj )
k = 0, 1, 2, . . . , L − 1
(3)
j=0
Fig. 2: Proposed face identification algorithm.
The method is divided in two phases (training and identification) and both consist of four modules: CLAHE: this
module belongs to the pre-processing stage, this is where the
image is enhanced; Obtain Phase Spectrum: in this module
obtains phase extracted from the Fast Fourier Transform;
PCA: this and the previous module are in the stage of feature
extraction; and SVM: this module gets the templates for the
training phase and making the decision in the identification
phase.
2.1 A. Contrast Limited Adaptive Histogram
Equalization
Firstly the histogram of a digital image with intensity
levels in the range [0, L − 1] is a discrete function:
h(rk ) = nk
(1)
Where rk is the kth intensity value and nk is the number
of pixel in the image with intensity rk [8]. A normalized
histogram is given by:
where sk is the new distribution of the histogram.
This procedure is based on the assumption that the image
quality is uniform over all areas and one unique grayscale
mapping provides similar enhancement for all regions of the
image. However, when distributions of grayscales change
from one region to another, this assumption is not valid. In
this case, an adaptive histogram equalization technique can
significantly outperform the standard approach. In this case,
the image is divided into a limited number of regions and the
same histogram equalization technique is applied to pixels
in each region [9].
Even in some cases this method can not resolve the
problem, when grayscale distribution is highly localized, it
might not be desirable to transform very low-contrast images
by full histogram equalization. In these cases, the mapping
curve may include segments with high slopes, meaning that
two very close grayscales might be mapped to significantly
different grayscales. This issue is resolved by limiting the
contrast that is allowed through histogram equalization.
The combination of this limited contrast approach with the
aforementioned adaptive histogram equalization results in
what is referred to as Contrast Limited Adaptive Histogram
Equalization (CLAHE) proposed in [10]. The CLAHE procedure consists in:
First the image has to be divided into several nonoverlapping regions of almost equal sizes. Secondly the
histogram of each region is calculated. Then, based on a
desired limit for contrast expansion, a clip limit for clipping
histograms is obtained. Next, each histogram is redistributed
in such a way that its height does not go beyond the clip
limit. The clip limit β is obtained by:
´
α
MN ³
1+
(smax − 1)
(4)
β=
L
100
where α is a clip factor, if clip factor is equal to zero the
clip limit becomes exactly equal to ( MLN ), moreover if clip
limit is equal to 100 the maximum allowable slope is smax .
Finally, cumulative distribution functions (CDF) of the
resultant contrast limited histograms are determined for
grayscale mapping. The pixels are mapped by linearly combining the results from the mappings of the four nearest
regions; this process is explained in [11].
The Fig. 3 shows the differences among histograms
of same image, applying both methods before mentioned
CLAHE and Histogram Equalization.
·
θ(u) = arctan
I(u)
R(u)
¸
(7)
This is also demonstrated by Oppenheimt’s experiment
shown in Fig. 4, in this experiment the Fourier Transform
was applied to these two images and obtain the magnitude
and phase. If combine the phase of the image 1 with the
magnitude of the image 2 and the phase of the image 2 with
the magnitude of the image 1, is prove that the component
that provides more information about the image is the phase.
Fig. 4: Oppenheimt’s experiment.
2.3 Principal Components Analysis
Fig. 3: Comparison of CLAHE and Histogram Equalization.
a) Original image and its histogram. b) CLAHE image
dividing (a) in four regions of equal size and its histogram.
c) Histogram equalization image and its histogram.
2.2 Phase Spectrum
Oppenheim et al. [12] show that phase information retains
the most part of the intelligibility of an image, because the
phase spectrum contains most of the image information. This
can be computed trough of a Fourier Transform which is
given by:
F (u) = |F (u) expjθ(u) |
(5)
Fig. 5: Feature extraction system by PCA.
where the magnitude is:
1
|F (u)| = [R2 (u) + I 2 (u)] 2
and the phase is:
The PCA is a way of identifying patterns in data, and
expressing the data in such a way as to highlight their
similarities and differences. Since patterns in data can be
hard to find in data of high dimension, where the luxury of
graphical representation is not available, PCA is a powerful
tool for analyzing data [13].
The other main advantage of PCA is that once these
patterns are found in the data, and the data is compress,
the number of dimensions are reduce, without much loss of
information.
(6)
Fig. 5 shows the procedure for PCA application which
is used in both phases training and recognition. The next
procedure was used in training phase:
Firstly the training images are converted in column vectors, and then these vectors make a matrix (Principal Matrix). Next the principal components were extracted of the
Principal Matrix to obtain a matrix of dominant features
(D.F). Finally the vector of each person is multiplied by
D.F to generate a feature vector, subsequently these vectors
conform a matrix of feature vectors. This step is only used
in the identification phase..
in conjunction with the obtain phase spectrum, the result is
convert in vector for initialize the step of PCA.
The first modification (CLAHE (2,2)) consists in apply
the CLAHE dividing the original image in 2 parts in y axis
and 2 in x axis generating four blocks, for later apply the
Fast Fourier Transform (FFT) to obtain the phase spectrum
of full image, this process shown in Fig. 7.
2.4 Support Vector Machine
A support vector machine is basically a binary pattern
classification method, whose objective is to assign each
pattern to a class [14].
The SVM is used differently in each one of the phases
using the vectors features obtained by PCA method. On
training phase the SVM generates templates of each person,
and in recognition phase decides whether feature vector
agree or disagree with all templates.
Fig. 7: First variant of system called CLAHE (2,2).
This variation is compare in the evaluation results with one
method proposed in [6] which used histogram Equalization
in full image for after extract the phase spectrum also of full
image (Full HE). Moreover is compared with the original
Eigenphases method. The Fig. 8 shows the process of these
two methods.
Fig. 6: Decision step by SVM in identification phase.
The decision step is shows in Fig. 6. The feature vector
of the person to recognize is applied to all one vs. all
SVMs. The class given the Maximum Likelihood is used as
the person’s identity; the equation to obtain the Maximum
Likelihood is as follows:
Sb = arg max P (λk |x)
1≤k≤S
(8)
where Sb is the winner and thus revealing the person’s
identity to whom this image was assigned, x is the column
vector of the image to analyze and λk is the SVM model of
the person k [15].
2.5 Algorithm Variations
As mentioned earlier the proposed system was compared
with the original method of Eigenphases [5] and the based in
Histogram Equalization [6], for this comparison there were
performed three variations in the proposed algorithm. It is
noteworthy that variations are on the pre-processing stage
Fig. 8: Differences among CLAHE (2, 2) and Full HE (white
lines are not part of the image, only used to illustrate the
number of divisions used by CLAHE).
The second variation (CLAHE (8,6)) is based on applying
the CLAHE and dividing the original image in 8, 6 parts (y,
x axes) generating 48 blocks each one of 6x6 pixels, next
the Fast Fourier Transform is applied to extract the phase
spectrum of full image, the Fig. 9 shows this process.
Fig. 9: Second variant of system called CLAHE (8,6).
This method which compares the face image is firstly
segmented in blocks of size 6x6. Next the histogram equalization is applied to each block, which concatenated to
reconstruct the face image under analysis. Finally the Fourier
Transform is applied to the whole image to estimate the
phase spectrum (Local HE), as shown in Fig. 10.
Fig. 12: Differences among Fourier CLAHE and Fourier
HE (white lines are not part of the image, only used to
illustrate the concatenation of the blocks by phase spectrum
extracted).
Fig. 10: Differences among CLAHE (8,6) and Local HE
(white lines are not part of the image, only used to illustrate
the 48 blocks used by CLAHE).
The Fig. 11 shows the finally variation of the system,
which consists on applying the CLAHE to form 48 blocks
of 6x6 pixels as in the previous structure, next the Fast
Fourier Transform is applied to each block, to estimate the
phase spectrum of the face image, finally these blocks are
concatenated to reconstruct the phase spectrum of the face
image, which is obtained using the estimated phase of each
block (Fourier CLAHE).
conditions, using a face data base created in to the National
Polytechnic Institute of Mexico which contains 2880
face images. This data base includes 24 face images of
120 subjects, 60 males and 60 females, under controlled
conditions such as different illumination, facial expressions
variations and partial occlusion using sunglasses, the size
of the images is 480 x 360 pixels. As shown in Fig. 13.
Fig. 11: Final variant of system called Fourier CLAHE.
The final method is compared with its similar with HE
this is shown in the Fig. 12, that is the same procedure as
Local HE but the Fast Fourier Transform is applied to each
block, to estimate the phase spectrum of the face image, and
with these blocks which are concatenated to reconstruct the
phase spectrum of the face image, which is obtained using
the estimated phase of each block called Fourier HE.
3. EVALUATION RESULTS
To evaluate the results of proposed and conventional
methods, there have realized the tests under the same
Fig. 13: Example of the face images in the database.
Six images were used for the training phase to generate a
template for each person, all images are resized to 48 x 36
pixels, to calculate the PCA. The number of training images
was calculated trying to get the best results with the least
number of images possible. The results for obtaining the
number of training images are shown in the graph on Fig.
14.
Table 1: RESULTS WITH HE VARIATIONS AND EIGENPHASE METHOD
Eigenphases
Full HE
Local HE
Fourier HE
Result %
91.22
91.01
94.48
97.19
The Table 2 shows the results of CLAHE method and its
variations. All these results are better than the obtained using
the original method, Fourier CLAHE was the best of these
results.
Table 2: RESULTS WITH CLAHE VARIATIONS
CLAHE (2,2)
CLAHE (8,6)
Fourier CLAHE
Fig. 14: Graph of results to determine the number of training
images.
The graph shown the result for the recognition using 2,
3, 5 and 6 images in training phase applying "Full HE"
variation of the system, this test was performed with all
database using the 24 face images of 120 people. Therefore
in the following results there were used 6 images for training,
these images shown in Fig. 15.
Result %
91.53
91.35
97.36
The Fig. 16 shows the comparison among the results of
Eigenphases with the best result of HE variation (Fourier
HE) and the best of CLAHE variation (Fourier CLAHE).
Fourier CLAHE is the best result of this comparison, providing accuracy identification from 97.36%.
Fig. 16: Comparison among “Fourier HE ”and “Fourier
CLAHE”with the conventional method “Eigenphases”, using
the same conditions.
4. Conclusion
Fig. 15: Training images example.
In the variations using HE and the original algorithm
Eigenphases the results is shown in Table 1, in which it
is noted that the best result is obtained by Fourier HE enhancement about 6 percentage points to the original method.
The best identification result obtained in this paper is the
"Fourier CLAHEŤ, surpassing 6% to conventional method
Eigenphases [5] and a little " Fourier HE ", as seen in Figure
16. "Fourier HE" in turn is the best result obtained using
Histogram Equalization variations proposed in [6].
It is important to mention that the 3 proposed variations
using CLAHE improve the conventional method Eigenphases, in contrast to the 3 variations using HE as it "Full
HE" presents a lower assertiveness than Eigenphases.
Moreover, the proposed system shown to be robust to
changes in the database used, which are illumination changes
and partial occlusion by using sunglasses, where the results
obtained are greater than 90% and in the best cases obtained
a 97.36% which is acceptable for a face recognition system.
Acknowledgment
Thanks to everyone who helped make this project, especially those who gave their time voluntarily for the realization of the database.
References
[1] S. Y. Kung, M. W. Mak and S. H. Lin, Biometric Authentication: A
Machine Learning Approach, New York: Prentice Hall, 2005, vol. 3.
[2] H. M. El-Bakry and N. Mastorakis, "Personal identification through
biometric technology," 9th WSEAS International Conference on Applied Informatics and Communications (AIC ’09), Moscow, Russia, pp.
325-340, 2009.
[3] Stan Z. Li and Anil K. Jain, Handbook of Face Recognition, Ed.
Berlin, Germany: Springer-Verlag, 2005.
[4] R. Chellapa, P. Sinha, P. J. Phillips, "Face recognition by computers
and humans," Computer Magazine, Vol. 43, pp. 46-55, Feb. 2010.
[5] M. Savvides, B. V. K. Vijaya Kumar, and P. K. Khosla, "Eigenphases
vs. Eigenfaces," Proc. 17th International Conference on Pattern Recognition, ICPR, vol. 3, pp. 810-813, Aug. 2004.
[6] K. Ramirez-Gutierrez, D. Cruz-Perez, J. Olivares-Mercado, M. NakanoMiyatake, and H. Perez-Meana, "A Face Recognition Algorithm using
Eigenphases and Histogram Equalization," International Journal of
Computers Issue 1, Volume 5, pp. 34-41, January, 2011.
[7] J. Olivares-Mercado, K. Hotta, H. Takahashi, M. Nakano-Miyatake, K.
Toscano-Medina, H. Perez-Meana, "Improving the eigenphase method
for face recognition", IEICE Electronic Express, vol. 6, pp. 1112-1117,
June, 2009.
[8] Rafael C. Gonzalez and Richard E. Woods, Digital Image Processing,
3th ed., Ed. Pearson Prentice Hall, 2008.
[9] Ali M. Reza. "Realization of the Contrast Limited Adaptive Histogram
Equalization (CLAHE) for Real-Time Image Enhancement." Jurnal of
VLSI Signal Processing, vol. 38, pp 35-44, 2004.
[10] S.M. Pizer, E.P. Amburn, J.D. Austin, R. Cromartie, A. Geselowitz,
T. Greer, B.M. ter Haar Romeny, J.B. Zimmerman, and K. Zuiderveld,
"Adaptive Histogram Equalization and its Variations," Computer Vision, Graphics and Image Processing, vol. 39, 1987, pp. 355-368.
[11] K. Zuiderveld, Contrast Limited Adaptive Histogram Equalization,
Heckbert., Ed. Cambridge, MA, Academic Press, 1994.
[12] A. V. Oppenheim and J. S. Lim, "The importance of phase in signals,"
Proc. IEEE, vol 69, pp. 529-541, May 1981.
[13] Lindsay I Smith. "A tutorial on Principal Components Analysis."
February 26, 2002.
[14] W. M. Campbell, J. P. Campbell, D. A. Reynolds, E. Singer, y
P. A. Torres-Carrasquillo. "Support vector machines for speaker and
language recognition," Computer Speech and Language, Vol. 20, N.
2-3, pp. 210-229, 2006b.
[15] T. Glasmachers and C. Igel, "Maximum Likelihood Model Selection
for 1-Norm Soft Margin SVMs with Multiple Parameters," IEEE
Transactions On Pattern Analysis And Machine Intelligence, Vol. 32,
No. 8, pp. 1522-1528, August 2010.