Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
13 views

An Approach for Face Detection and Face Recognition Using OpenCV and Face Recognition Libraries in Python (1)

The document presents a study on face detection and recognition using OpenCV and Python libraries, highlighting the importance of automated systems in processing vast amounts of image and video data. It discusses various methodologies for face detection, including knowledge-based, feature invariant, template-based, and appearance-based techniques, as well as the challenges posed by varying facial expressions and image quality. The research emphasizes the effectiveness of the proposed facial recognition system, which utilizes deep learning and image processing techniques to accurately identify faces in digital images.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views

An Approach for Face Detection and Face Recognition Using OpenCV and Face Recognition Libraries in Python (1)

The document presents a study on face detection and recognition using OpenCV and Python libraries, highlighting the importance of automated systems in processing vast amounts of image and video data. It discusses various methodologies for face detection, including knowledge-based, feature invariant, template-based, and appearance-based techniques, as well as the challenges posed by varying facial expressions and image quality. The research emphasizes the effectiveness of the proposed facial recognition system, which utilizes deep learning and image processing techniques to accurately identify faces in digital images.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

2023 9th International Conference on Advanced Computing and Communication Systems (ICACCS)

An approach for Face Detection and Face


2023 9th International Conference on Advanced Computing and Communication Systems (ICACCS) | 979-8-3503-9737-6/23/$31.00 ©2023 IEEE | DOI: 10.1109/ICACCS57279.2023.10113066

Recognition using OpenCV and Face Recognition


Libraries in Python
Ainampudi Kumari Sirivarshitha Kadavakollu Sravani
Department of CSE Department of CSE
Koneru Lakshmaiah Education Foundation Koneru Lakshmaiah Education Foundation
Vaddeswaram, AP, India Vaddeswaram, AP, India
sirivarshitha115@gmail.com kadavakollusravani2001@gmail.com

Kothamasu Santhi Priya Vasantha Bhavani


Department of CSE Department of CSE
Koneru Lakshmaiah Education Foundation Koneru Lakshmaiah Education Foundation
Vaddeswaram, AP, India Vaddeswaram, AP, India
k.santhipriya2002@gmail.com vasanthabhavani@kluniversity.in

Abstract—With the extraordinary growth in images and I. INTRODUCTION


video data sets, there is a mind-boggling want for programmed
un- derstanding and evaluation of data with the assistance of Face detection has sparked a lot of attention since it is
smart frameworks, since physically it is a long way off. frequently employed in vision systems for computers for
Individuals, unlike robots, have a limited capacity to distinguish autonomous control and communication. A face-detection
unexpected expressions. As a result, the programmed face system is a technique to identify a face from a picture with
proximity frame- work is important in face identification, several faces featured in that picture. The concept of feature
appearance recognition, head-present evaluation, human-PC vectors serves as the foundation for most face recognition
cooperation, and other ap- plications. Software that uses facial
theories. Research is needed in the areas of face detection,
recognition for face detection and identification is regarded as
biometric. This study converts the mathematical aspects of a emotion identification, face tracking, and posture estimation.
person’s face into a face print, which is then stored in a database The task of identifying the face in a single photograph is
to verify an individual’s identification. A deep learning system presented. Face detection is tough since faces are not static
compares a digital image or an image taken quickly to a and change in size, shape, color, and other aspects. When the
previously stored image(whichis saved in the database). The provided image is blurry, obscured by anything else, has poor
face has a significant functionin interpersonal communication lighting, is not facing the camera, etc., face identification
for identifying oneself. Face recognition technology determines becomes a more difficult process. A feature vector is created
the size and placement of a human face in a digital picture. by converting the facial picture into a string of integers. The
Facial recognition software has a wide range of uses in the content of a feature vector for a face photograph includes
consumer market and in the security and surveillance sectors.
properties such as head level, face breadth, average face color,
The COVID pandemic has brought facial recognition into
greater focus lately than ever before. Face detection and lips width, and nose height. The face-recognition technique
recognition play a vital part in security systemsthat people evaluates the input feature vector of a face photograph with a
need to interact with without making physical contact. The large range of feature vectors in a collection of data to identify
pattern of online exam proctoring is employing face detection a person’s identification. The Python environment is mostly
and recognition. Facial recognition is used in the airline sector used to develop the facial recognition system in this study.
to enable rapid, accurate identification and verification at every Face generation is accomplished using selfies. The image is
stage of the passenger trip. In this research, we focused on image cropped to keep the face’s portion, then it is saved to the
quality because it is the major drawback in existing algorithms database. If the resemblance score is higher than the real
and used OPEN CV, Face Recognition, and designed algorithms threshold, compare the incoming facial images with those kept
using libraries in python. This study discusses a method for
in the data collection. The application will display the
facial recognition along with its implementation and
applications. identification of faces by picture. Otherwise, a bogus notice
will be shown by the system. The facial recognition system
Keywords—Face Detection, Face Recognition, Face has been completed, and the trial results show that it is
Alignment , Feature Extraction, Python, OpenCV Library, face effective. The facial image is finally captured using the laptop
Recognition Library Webcam, and the comparison outcome is likewise accurate.

979-8-3503-9737-6/23/$31.00 ©2023 IEEE

1274
Authorized licensed use limited to: HKBK College of Engineering. Downloaded on October 07,2024 at 09:51:43 UTC from IEEE Xplore. Restrictions apply.
2023 9th International Conference on Advanced Computing and Communication Systems (ICACCS)

II. LITERATURE REVIEW distribution-based models for face-nonface patterns. Each


Although face recognition is simple for humans, it is more picture is vectored in 361 dimensions after each face example
challenging for computers since the human body is not rigid, has been processed and normalized as a 19*19-pixel image.
meaning that changes will occasionally occur in it. Face Images are now grouped into six clusters for faces and six
detection is the first and most crucial issue for face clusters for non-faces using a modified K-means method..
recognition. The first step in automatic face recognition is face There are two distances between a cluster and an input picture.
detection. To address this issue, we may develop a set of Using a modified K-means approach, images are now
various facial picture locations for a person. Face images may categorized into a 6-face and a 6-non-face cluster. There are
differ due to differences in facial expressions, even when the two distances between an input image and a cluster.
expression and position are the same. Lighting may also cause Calculations, normalized Mahalanobis distance, and
variations in face images when the same expression and Euclidian coordinates distance. Finally, a multi- layer
position are used. This study focuses on the lateral face perceptron network is employed to use a twelve-pair to
identification system, which can detect faces while having a separate face- and non-face-containing window patterns. Each
low proportion of false positives. According to M. Yang and face cluster and non-face cluster in terms of distance. In [4] a
his team in[1], there are four categories of face recognition method to express static color pictures in a tensor- based
techniques: knowledge-based, template-based, feature format was proposed by Lajevardi and Wu. In a colored
invariant, and appearance-based. picture, it is utilized to identify facial emotions. It has 68.8
percent accuracy in color images of various resolutions. In
A. Knowledge based Method 1977, [5] Ekman and Friesen suggested a reliable technique
This approach looks for relationships between facial for facial activity coding. The Face Action Coding System
features relationships based on prior information. It relies on attempts to analyze facial emotion by monitoring the shifting
stored knowledge of what makes up a human face and is used behavior of the facial muscles. The average detection rate is
for localizing human faces. 7.8 percent higher with this approach. The program uses 46
Action Points (AP), which represent human facial behavior.
B. Feature Invariant Approach In [6], Divya Meena and Ravi Sharan worked on the viola
These techniques, which are also utilized for face local- Jones algorithm to detect face and principal component
ization, are used to find faces in a variety of situations, for analysis for face recognition when the image is not clear and
example, low or high light densities, poses from various occluded by any other thing and not proper lightning, not
angles, and combinations of these conditions. This approach facing the camera, etc. In [7], Mohammad Abu-Lebdeh and
is used to resolve various facial poses. his team presented a new architecture for EPC-based mobile
video surveillance applications. The design enables quick
C. Template based Method development and deployment of new applications while also
Both face localization and face detection may be providing assured and differentiated QoS, which is not
accomplished using the template-matching approach. This feasible in other networks. A proof-of-concept prototype was
approach keeps a number of common patterns of the human successfully developed; as evidenced by the performance
face, and those patterns can be used to describe the full face measurement study, the delays experienced by adopting the
or a particular facial feature. For detection, a connection must suggested architecture were reduced. Geetha and her team [8],
be determined between the previously recorded pattern and used SVM and Eigenface algorithms to improve the accuracy
the input picture. of existing face recognition systems. They used a method
similar to Eigenface is utilized to extract facial features from
D. Appearance based method facial vectors, and the datasets are trained using the Support
The model of the picture is learned using a series of Vector Machine (SVM) algorithm for face classification and
training photos provided in this manner rather than templates. detection, which guarantees that face recognition is faster and
These models are then used in the face-detection process. that it may be utilized for online exam monitoring. In [9],
Menq-Jiun Wu and his team achieved face recognition using
Yang and Huang used a face detection strategy in [2]; in
the idea of feature vectors. Jayanth Vadlapati and his team in
this technique, a set of specifications are described as a
[10], using face recognition modules from python’s huge
knowledge-based approach, and it contains rules on the face
collection of libraries, are able to train the model to recognize
of an input picture before employing face scanning to locate
people while wearing masks.
every conceivable face. At the highest level, for example, a
collection of rules is developed to characterize a human face, III. PROPOSED APPROACH
while at the lowest level, rules for facial features are offered.
For face identification from pictures, many rules and layers of A. Python
rules are devised. It is possible to generate multi-layer picture Python is presently the most widely used pro- gramming
hierarchies by averaging and sub-sampling. Sung and Piggo language. Python is straightforward but flexible, which is why
developed a face identification strategy as a distribution- programmers adore it. Python is capable of tackling
based system [3], and an object class was taught using both complicated jobs despite being simple. Python has so far been
positive and negative examples. A distribution-based system utilized for the back end. Python is still a fairly dependable
consists of two halves: a multi-layer perceptron classifier and programming language for image recognition. Image

1275
Authorized licensed use limited to: HKBK College of Engineering. Downloaded on October 07,2024 at 09:51:43 UTC from IEEE Xplore. Restrictions apply.
2023 9th International Conference on Advanced Computing and Communication Systems (ICACCS)

recognition is well supported by the Python library. Scikit- Face detection is a computer technique that recognizes
Learn Machine Learning, which is renowned for its capacity human faces in digital images and is utilized in many different
to handle facial recognition and motion detection, is one of the applications. Face detection finds many faces in an image
most potent and effective Python modules. together with the essential facial characteristics that go with
them, including emotional state, or uses the expressions on the
B. OpenCV Library faces to identify age, gender, and emotions. Many face-
Using the OpenCV library is the most well-liked and most related technologies, such as face identification or
likely the easiest approach to recognizing faces using Python. verification, typically start with face detection. Work flow
OpenCV, which was first created in C/C++, now has Python diagram is shown in Fig. 1.
bindings. To find faces in a photograph, it employs machine
learning techniques. Faces are extremely intricate, consisting Face detection algorithms can be classified into two or
of countless minute patterns and characteristics that must more of the four categories in which these approaches are
match. The facial recognition algorithms, also known as classified. These are the classifications:
classifiers, divide the identification of the face into thousands 1) Knowledge-Based: To identify faces, this method
of manageable, bite-sized jobs. A face may have 5000 relies on a set of rules and is based on human knowledge. An
classifiers or more, and each one of them must match in order example would be that the nose, eyes, and mouth of a face
for a face to be recognized. We may have to perform millions
must all be at specific angles and distances from one another.
of calculations because each block has at least 5,000 tests, if
not more. Cascades are used by OpenCV to address this. The 2) Feature-Based: Using structural elements of the face,
OpenCV data needed to detect objects is included in a the feature-based technique locates faces. It is used to
collection of XML files called cascades. The code performs distinguish between facial and non-facial regions after being
the work for us after we initialize it with the desired cascade. trained as a classifier.
Given how frequently faces are detected, OpenCV has a 3) Template Matching: The Template Matching
plethora of algorithms for recognizing everything from heads approach locates or detects faces by correlating input photos
to hands to toes. and pre- defined or parameterized face templates. Examples
C. Face Recognition Library include theeyes, face shape, nose, and lips of a human face.
Additionally, a face model can be constructed solely from
The face recognition library contains numerous methods
edges using edge detection.
(functions) for dealing with faces in pictures, one of which is
known as face positions, which will locate the location of the 4) Appearance-Based: In order to identify face models,
face inside a certain image and we will pass the image file that theappearance-based technique uses a collection of delegate
we used in the previous line of code. training face photos. The appearance-based method
outperforms other modes of performance. In order to identify
The world’s most basic face recognition library allows us the pertinent features of face photos, appearance-based
to recognize and operate with faces from Python or the
methods typically use statistical analysis and machine
command line. The model was developed using the most
powerful facial recognition technology available from dlib, learning approaches.
and it has an accuracy of 99.38% on the labeled faces in the E. Face Alignment
wild benchmark. In addition, a simple face recognition
command line application is supplied, allowing us to perform Face alignment is crucial in the majority of face analysis
face identification on a folder of images directly from the procedures. The practice of identifying the geometric com-
command line. position of faces in digital photos and attempting to create a
canonical alignment of the face based on translation, scale,
D. Face Detection and rotation is known as face alignment. It focuses on
detecting a few key locations on human faces in photos or
videos.
There are several types of facial alignment. Several
strategies try to impose a (pre-defined) 3D model and then
change the input picture so that the landmarks on the input
face match the landmarks on the 3D model. Other, simpler
systems (such as the one described in this blog article) depend
solely on facial landmarks (especially the eye regions) to
generate a normalized rotation, translation, and scale
representation of the face. Block Diagram of Face Detection
and Recognition is shown in Fig. 2.

Fig. 1. Work Flow Diagram

1276
Authorized licensed use limited to: HKBK College of Engineering. Downloaded on October 07,2024 at 09:51:43 UTC from IEEE Xplore. Restrictions apply.
2023 9th International Conference on Advanced Computing and Communication Systems (ICACCS)

technology may also be used in private locations like shops


and sporting venues; however, these locations may be subject
to various regulations. Flow of Image Recognition and
Matching is shown in Fig. 3.
IV. RESULT DISCUSSION

Fig. 2. Block Diagram of Face Detection and Recognition

F. Feature Extraction
In various pattern recognition tasks, dimension reduction
techniques have demonstrated significant benefits, and face
processing is no exception. Typically, we are able to compress
the input data, which lowers the storage requirements. Due to
less noise, which is present in the majority of natural photos,
the classification results have also improved in other
instances. One of the most used methods for dimensionality
reduction is principal component analysis. Feature extraction Fig. 3. Flow of Image Recognition and Matching
significantly reduces the amount of data while still obtaining
the optimal feature from those enormous data. Following the
face detection step, the face extraction procedure is completed
to produce accurate data that can be used to discriminate
between the faces of various people.
The technique of extracting facial feature components
from a human face photograph includes elements like the lips,
nose, and eyes. For the start of processing techniques like face
tracking, facial emotion recognition, or face recognition,
facial feature extraction is crucial. To process features like
shapes, edges, or movements in a digital picture or video, a
feature extraction procedure is used. The extraction of facial
features is a fundamental step in computerized visual
observation and human face recognition. Identifying facial
characteristics is crucial in a variety of applications, including
human-computer interaction, facial animation, and face
identification.
G. Face Recognition
Facial recognition is a method of recognizing or verifying Fig. 4. Successful Multiple Faces Recognition
an individual’s identity by utilizing their face. Face
recognition algorithms can distinguish people in photographs, Most often, the accuracy of the algorithm is used to gauge
films, and in real-time. how effective a face recognition system is. The algorithm’s
In order to identify certain, recognizable features on a capacity to identify the face input and provide the percentage
person’s face, face recognition systems employ computer of the match is how accuracy is determined. The algorithm’s
algorithms. Then, a mathematical representation of these presentation of the closest match percentage is crucial. In this
details, such as the separation between the eyes or the contour model, the algorithm takes the image of the person and detects
of the chin, is created and compared to information on other the face, and recognizes and displays the name from the
faces gathered in a face recognition database. images it has. As a result, this facial recognition technology
may be used in place of passwords to get access to computers.
The steps involved in face recognition are detection, This method has been tested on a larger database with more
alignment, feature extraction, and task recognition. Face photos and has an 80% accuracy rate. When face recognition
recognition has been implemented at border crossings, during technology becomes more widely available, public concern
Olympic Games activities, and in airports. Face recognition about unwarranted stops and searches may become less of an

1277
Authorized licensed use limited to: HKBK College of Engineering. Downloaded on October 07,2024 at 09:51:43 UTC from IEEE Xplore. Restrictions apply.
2023 9th International Conference on Advanced Computing and Communication Systems (ICACCS)

issue for police. Succesful Multiple Faces Recognition is andpattern detection.


shown in Fig. 4. [6] Divya Meena, Ravi Sharan(2016), An Approach to Face Detection and
Recognition.
V. CONCLUSION [7] Maliha Khan, Sudeshna Chakraborty, Rani Astya, Shaveta
Khepra(2019), Face Detection and Recognition Using OpenCV.
In this report, face detection and recognition using Python [8] M.Geetha, R.S.Latha, S.K.Nivetha, S.Hariprasath, S.Gowtham,
environment by using OpenCV and face recognition we have C.S.Deepak(2021), Design of face detection and recognition system to
come to the conclusion that, the OpenCV library is becoming monitor students during online examinations using Machine Learning
more and more successful and performs better when it comes algorithms.
to locating and identifying faces. It further suggests that [9] Menq-Jiun Wu, Yeong-Chin Chen, Yi-Sheng Liao, Jun-An Chen, Hao-
building recognition apps at the IOT stage with OpenCV is a Han Lin(2021), Face-recognition System Design and Manufacture.
wiser choice. An algorithm for both Face Detection and Face [10] Jayanth vadlapati, S Senthil Velan, Ewin Varghese(2021),Facial
Recog-nition using the OpenCV Libraries of Python for the Pictures of
recognition is derived, which helps to identify multiple faces Human Faces Wearing Face Masks during the COVID-19 Pandemic.
present in image. Used image resolution to get high quality
images which helps to detect the face within seconds.
Security is one of the sectors that use facial recognition
that employs facial recognition technology the most. Software
busi- nesses are utilizing facial recognition technology to
make it easier for consumers to use their technology. Facial
recognition is a very powerful technique that may assist law
enforcement in identifying criminals. This technology may be
improved to be utilized in several contexts, such as ATMs,
accessing private information, or handling other delicate
materials. Other security mechanisms like passwords and keys
can become outdated as a result of this. Face recognition
would scan your face, run it through a system, and charge the
account that you’ve already registered instead of requiring you
to visit a kiosk to purchase a ticket for a fee. This may
significantly simplify the procedure and improve traffic flow.
Further study will aim to improve the accuracy of face
detection and recognition.
VI. FUTURE SCOPE
Developing identification programs using OpenCV during
the IOT stage is a preferable choice since face recognition is a
sophisticated technology that may assist public safety in
detecting suspects. This technique might be improved to be
utilized in a variety of circumstances, including ATMs,
accessing private data, and handling other delicate materials.
Other security mechanisms, such as passwords and keys, may
become outdated as a result. Instead of requiring you to visit
a kiosk to purchase a ticket, facial recognition would scan
your face, run it through a system, and charge the already
registered account. This might considerably simplify the
procedure and improve traffic flow.
REFERENCES
[1] Lajevardi, S. M., & Wu, H. R. (2012). Facial expression recognition in
perceptual color space. IEEE Transactions on Image Processing, 21(8),
3721-3733.
[2] Yang, G., & Huang, T. S. (1994). Human face detection in a complex
background. Pattern recognition, 27(1), 53-63.
[3] Yang, M. H., Abuja, N., & Kriegman, D. (2000). Face detection
using mixtures of linear subspaces. In Automatic Face and Gesture
Recognition, 2000. Proceedings. Fourth IEEE International
Conference on (pp. 70-76). IEEE.
[4] Sung, K. K., & Poggio, T. (1998). Example-based learning for view-
based human face detection. IEEE Transactions on pattern analysis and
machine intelligence, 20(1), 39-51.
[5] Sung, K. K. (1996). Learning and example selection for object

1278
Authorized licensed use limited to: HKBK College of Engineering. Downloaded on October 07,2024 at 09:51:43 UTC from IEEE Xplore. Restrictions apply.

You might also like