An Efficient Face Recognition Method Based On CNN

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

2023 IEEE 3rd International Conference on Power, Electronics and Computer Applications (ICPECA)

An Efficient Face Recognition Method Based on


CNN
2023 IEEE 3rd International Conference on Power, Electronics and Computer Applications (ICPECA) | 978-1-6654-7278-4/23/$31.00 ©2023 IEEE | DOI: 10.1109/ICPECA56706.2023.10076242

Xiu He*, Feng Ding


Guangzhou Xinhua University, Guangzhou, China
*Corresponding author: hexiushow@163.com

Abstract—As a prevailing research in artificial intelligence, II. RELATED WORK


the application of computer vision is widely used in many fields
which are closely related to people's livelihood, such as Generally, we can divide face recognition methods into
industrial automation, new retail industry, smart two categories, there are respectively traditional methods
transportation and security monitoring. And the proposed face and deep neural networks methods. Traditional methods
recognition method is a branch in the field of computer vision, mainly include some global algorithms, such as EigenFace
it integrates neural networks, biology, image signal processing, algorithm and FisherFace algorithm, and also inculde some
machine learning and other fields, which promote research and local descriptors algorithms, such as LBP histogram
cross-development among different disciplines. Hence, this algorithm and Scale Invariant Feature Transform algorithm.
paper focuses on face recognition method by using In 1991, Matthew Turk proposed a famous EigenFace[5]
convolutional neural network(CNN), and CNN has the method, which first introduced Principal Component
property of "weight sharing", which has been widely Analysis (PCA) and statistical feature techniques into face
popularized in image recognition, it can greatly simplify the recognition tasks, and achieved well in practical
work of large-scale network training. The experiments applications. As a continuation of this idea, Belhumer[6]
demonstrate that the proposed face recognition method is introduced FisherFace method based on Linear
successful, and the accuracy of the proposed method can be as
Discrimination Analysis (LDA) and employed Fisher's
high as 98%.
discriminant criterion to face recognition once again. Then,
Keywords—Face recognition, convolutional neural network, sparse representation is proposed for face recognition[7].
artificial intelligence, computer vision Later, the Gabor operator has also been widely recognized
in practice and been successfully applied to face recognition
I. INTRODUCTION algorithms[8].
In recent decades, our life has changed a lot with the With the development of deep learning technology, it
rapid development of computer and network technology. was also successfully applied in face recognition. Several
The traditional identification methods such as IC cards and teams at home and abroad have successively proposed
ID cards cannot avoid damage, loss, forgery, etc., which several CNN-based face recognition methods. The
have certain limitations and drawbacks, and they have DeepFace[9] model is the first algorithm to use CNN.
slowly faded from contemporary society. As one of the DeepFace used 6 convolutional layers and 2 fully connected
biometric identification methods, face recognition is to layers, wherein the first 3 convolutional layers are
obtain faces from static images or video streams, and convolutional operations with shared weights, which are
extracts facial feature information to achieve the purposes of used to extract features from the entire image. The last three
identity verification and identification. This technology has convolutional layers use local connections to extract
some good characteristics of non-intrusiveness, different features on different parts of face images.
non-perceptual recognition and convenient data collection, DeepFace has achieved well on the LFW dataset in face
and which has been widely used in many important fields recognition, which can approach the recognition level of
such as industrial automation, new retail industry, smart humans approximately. Then Professor Tang’s team
transportation, security monitoring, and so on. proposed a novel DeepID[10] method, which is to use deep
learning to extract deep-level face features. DeepID adopted
On the other hand, the breakthrough achievements in
a similar network structure and the same loss function as
artificial intelligence promote the development of face
DeepFace, but it introduced some novel ideas of data
recognition technology. After the great success of CNN on
enhancement and ensemble learning, and experiments
the ImageNet image challenge, some classical CNN
indicated that this method improved the accuracy of
architectures are proposed , which can be used to extract
recognition. Based on DeepID, the team further proposed
deep features. Among them, AlexNet[1], VGGNet [2],
GoogleNet [3] and Residual Network [4] are the most DeepIDv2 model. The improvement of DeepIDv2 focused
widely used, and which have become backbone networks on the calculation of loss function, it not only retained the
for feature extraction in various fields. In addition, CNN has original classification loss, but also introduced intra-class
a natural advantage in processing nonlinear data. When face loss and inter-class loss. Ultimately, DeepV2 model
images are input to the cascaded convolutional layers, achieved an accurate recognition rate of 99.15%, and deep
pooling layers and fully connected layers for feature neural networks outperform human recognition on this data
set for the first time.
extraction, CNN can not only achieve the purpose of data
dimensionality reduction, but also retain effective feature After 2016, the focus of face recognition research had
information. Therefore, the face recognition method based gradually shifted to the design of loss functions, and the
on CNN is valuable. discussion space of research problems had also gradually

978-1-6654-7278-4/23/$31.00 ©2023 IEEE 1788 January 29-31, 2023 Shenyang, China


Authorized licensed use limited to: Zhejiang University. Downloaded on February 22,2024 at 03:18:27 UTC from IEEE Xplore. Restrictions apply.
transitioned from the euclidean space to the angle space. had experienced from the design of local feature descriptors
The main representative works during this period included to the research of global feature extraction methods, and
some algorithms such as CenterLoss, SphereFace, CosFace, also experienced from statistical learning methods to deep
Sface and ArcFace[11-15]. Among them, the ArcFace learning methods. Now, the current face recognition
algorithm was the most convincing work, they improved the research is also undergoing improvements from the design
SphereFace algorithm by adding normalization operations to of CNN structure to improve loss function.
eigenvectors and additive angle intervals, so the ArcFace
algorithm not only improved the separability of different III. METHODOLOGY
classes, but also strengthened the compactness in intra-class This section introduces a face image recognition method
and the dissimilarity in inter-class. After some years of based on CNN in detail. As we can see in Fig.1, it
research, the development of face recognition technology demonstrates the processes of the proposed method.

Fig.1 Workflow diagram of face recognition method

(1) Data preprocessing to be input into the face detection module, and when a face
is detected, the coordinate position of the corresponding
Face recognition method proposed in the work uses a face frame will be output. Note that, the position on upper
deep learning algorithm CNN to recognize the contour left corner is coordinate origin, and the height and width of
features of faces, and has low requirements for color. the image are respectively the i-axis and j-axis in the plane
Therefore, for color images, we convert them into grayscale rectangular coordinate .
images, and there are
(3) CNN model
V (i, j ) = 0.299 Ri, j + 0.587Gi , j + 0.114 Bi , j . In this paper, CNN is widely applied in the field of
image recognition. The feature of "weight sharing" in the
wherein Ri,j, Gi,j, and Bi,j are the pixel value of three CNN makes the structure of the network very simple. A
color channels at positions i and j, respectively. deep CNN usually contains some layers, such as input,
convolutional, nonlinear mapping and pooling layers.
(2) Face detection Finally, two-dimensional feature is connected into a vector
In this stage, we employ the deep learning MTCNN and input to the final classifier through the fully connected
method to face detection. In this algorithm, the images need layer.

Fig.2 Working model of CNN

As shown in Fig. 2. First, input face image 32*32 is IV. RESULTS AND DISCUSSION
convolved with six trainable convolution kernels and bias
terms, and six feature maps are generated in the H1 Face recognition is essentially a classification problem,
convolution layer ; Then, every four pixels in the feature and we evaluate the performance of the proposed method by
map are pooled, weighted value, and bias operation, and the precision. The higher the precision is , the better the
feature maps of H2 layers are obtained through an activation performance is .
function. Further, these feature maps are filtered to obtain
the H3 layer, and this hierarchical structure is the same as TP
Precision =
that of H2 to produce H4. Finally, H4 is converted to a vector TP + FP
and output to fully connected layer. Then classification
results can be obtained. wherein TP and FP are respectively the true positives
and false positives.

1789
Authorized licensed use limited to: Zhejiang University. Downloaded on February 22,2024 at 03:18:27 UTC from IEEE Xplore. Restrictions apply.
The data set in the experiment is a real-time face image kernels are used to reconvolve the obtained feature map in
captured by a computer camera. This data set takes photos its previous convolutional layer, where 32 refers to 32
of 10 people, and each person takes 400 face images.In convolution kernels in the first convolutional layer, so the
addition, we divide the obtained dataset into training set generated feature map is also 32-dimensional.
30% and test data set 70%. The purpose of training set is to
train the parameters of CNN, and we verify the accuracy of (3)Third convolutional layer: This layer further uses 64
face recognition by using the remaining test set. Note that convolution kernels to convolve the feature maps which
input face images detected by MTCNN must be first were generated by previous convolution layer, wherein the
converted into a grayscale image, and then scaled to a size size of each convolution kernel is 3*3*64.
of 64 *64, so the size of an input image is 64*64*1. When (4)Fully connected layer: This layer needs to connect
the CNN accept N images, the input layer dimension is features learned by convolutional layer with final output
N*64*64*1. layer. Fully connected layer will pass probability value of
In our study, the proposed CNN contains 3 output sample belonging to each category through the
convolutional layers and 1 fully connected layer. The main softmax function, then final classification result is one
framework is as follows: category which has a largest probability value. Loss
function is defined as the cross-entropy function, and the
(1)First convolutional layer: The convolutional layer error is propagated by gradient descent.
uses 32 3*3*1 convolution kernels to convolve the input
layer (32*32*1), and the last number 1 indicates that the As depicted in Fig.3, at the beginning of training, the
input image is single-channel, so the convolution kernel has train loss and test loss continue to decline, while the training
a moving stride of 1. Then, ReLU function is employed to set accuracy and test set accuracy also increase, these
enhance the fitting ability of the network model, and each indicate that the network is learning. As the network
2*2 area needs to be max pooled . continues to learn, it slowly became stable, and the training
result maintain in a stable and high recognition rate.
(2)Second convolutional layer: 64 3*3*32 convolution

Fig.3 Training experiment results

V. CONCLUSION and so on.


We propose an efficient face recognition based on CNN ACKNOWLEDGEMENTS
in this paper. This method is a technology which extracts This work was supported in part in by Guangzhou
human facial feature information for recognition. In this Science and Technology Project under Grant
scheme, for the color information of color images, we need No.202102080656 and No.202002030273, and in part by
to convert color images to gray face image for further Key Discipline Project, Guangzhou Xinhua University with
processing, and some color information will be loss. No.2020XZD02, and in part by the 2021 the ordinary
However, the experiments indicate that the proposed university key research platform and projects of Guangdong
method is feasible and has a satisfactory precision is our (No:2021ZDZX1047).
data set.
Additionally, the color information of color image are REFERENCES
very important in some fields, such as traffic safe area. The [1] A. Krizhevsky, I. Sutskever and G. Hinton, "ImageNet classification
successful application of this technology lays a foundation with deep convolutional neural networks"[J], Proc. Neural Inf.
Process. Syst. Conf. (NIPS), 2012,84-90.
of research for the face recognition of color images. In the
[2] P. Görgel and A. Simsek,"Face recognition via deep stacked
next work, we will further consider to improve the precision denoising sparse autoencoders (DSDSA)"[J]. Appl. Math. Comput.,
of color images recognition in some special applications 2019(355):325-342.
which have a higher requirements for the color, brightness [3] F. Yuesheng et al. "Circular Fruit and Vegetable Classification Based

1790
Authorized licensed use limited to: Zhejiang University. Downloaded on February 22,2024 at 03:18:27 UTC from IEEE Xplore. Restrictions apply.
on Optimized GoogLeNet," [J]. IEEE Access, 2021,vol. survey,Neurocomputing[J].2021(429): 215-244.
9:113599-113611. [10] Ou Yang, W. et al.DeepID-Net: Deformable Deep Convolutional
[4] K. Zhang, M. Sun, T. X. Han, X. Yuan, L. Guo and T. Liu."Residual Neural Networks for Object Detection. [J].IEEE transactions on
Networks of Residual Networks: Multilevel Residual Networks." [J]. pattern analysis and machine intelligence.2017, 39(7):1320-1334.
IEEE Transactions on Circuits and Systems for Video Technology, [11] Y. Zhong, W. Deng, J. Hu, D. Zhao, X. Li and D. Wen.“Sface:
2018, 28(6): 1303-1314. sigmoid-constrained hypersphere loss for robust face recognition,”[J].
[5] Turk M. Eigenface for recognition[J].Journal of Cognitive IEEE Transactions on Image Processing, 2021(30):2587–2598.
Neuroscience,1991(3):71-86. [12] Wen Y , Zhang K , Li Z , et al. A Discriminative Feature Learning
[6] Belhumeur, Peter, N, et al. Eigenface vs. fisherfaces: Recognition Approach for Deep Face Recognition[M]// Computer Vision -ECCV
using class specific linear projection.[J].IEEE Transactions on Pattern 2016. Springer International Publishing, 2016.
Analysis & Machine Intelligence, 1997,19(7) :711-720. [13] Liu W , Wen Y , Yu Z , et al. SphereFace: Deep Hypersphere
[7] T. Shu, B. Zhang and Y. Y. Tang "Sparse Supervised Embedding for Face Recognition[C]// 2017 IEEE Conference on
Representation-Based Classifier for Uncontrolled and Imbalanced Computer Vision and Pattern Recognition (CVPR). IEEE, 2017.
Classification,"[J]. IEEE Transactions on Neural Networks and [14] H. Wang et al. CosFace: Large Margin Cosine Loss for Deep Face
Learning Systems, 2020,31( 8) :2847-2856. Recognition[C]// 2018 IEEE/CVFConference on Computer Vision
[8] C. Low, A. B. Teoh and C. Ng."Multi-Fold Gabor, PCA, and ICA and Pattern Recognition, Salt Lake City, UT, 2018, pp. 5265-5274.
Filter Convolution Descriptor for Face Recognition" [J]. IEEE [15] Deng J, Guo J, Xue N, et al. ArcFace: Additive Angular Margin Loss
Transactions on Circuits and Systems for Video Technology, 2019, for Deep Face Recognition[C]// 2019 IEEE/CVF Conference on
29(1):115-129. Computer Vision and Pattern Recognition (CVPR). IEEE, 2019.
[9] Mei Wang, Weihong Deng. Deep face recognition: A

1791
Authorized licensed use limited to: Zhejiang University. Downloaded on February 22,2024 at 03:18:27 UTC from IEEE Xplore. Restrictions apply.

You might also like