SlideShare a Scribd company logo
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
82
Automated Attendance System Based on Facial Recognition using Viola-Jones Algorithm
N. Dhana Lakshmi1
, Pranavi Nagubandi2
, Muralidhar Yeleti3
& K.Vishnu Vardan4
1
Assistant Professor, Department of ECE, CBIT, Hyderabad, Telangana, India.
2-4
UG Students, Department of ECE, CBIT, Hyderabad, Telangana, India.
DOI: http://doi.org/10.38177/ajast.2022.6210
Copyright: © 2022 N.Dhana Lakshmi et al. This is an open access article distributed under the terms of the Creative Commons Attribution License, which
permits unrestricted use, distribution, and reproduction in any medium, provided the original author and source are credited.
Article Received: 22 February 2022 Article Accepted: 26 April 2022 Article Published: 30 May 2022
1. Introduction
Automated Time and Attendance marking system can help schools and higher education in many ways. There is no
doubt that an attendance management system will surely save lot of time and money by eliminating a great deal of
manual processes involved in attendance and leave entry and calculating hours attended. Since the attendance is
automated, the data is accurate and error-free. Once the attendance is marked, the captured data gets stored in the
student attendance system. This feature is especially useful while locating a particular student or while analysing
trends. A face recognition system is a computer application capable of identifying or verifying a person from a
digital image. One of the ways to do this is by comparing selected facial features from the image and a face
database. Automated Attendance System is the advancement that has taken place in the field of automation
replacing traditional attendance marking activity.
Generally an Attendance Management System which is developed using bio-metrics, but in our case we collect the
facial data base using face detecting algorithm and Classifying them using Eigen faces approach.
2. Literature Survey
Henry A. Rowley, Shumeet Baluja, and Takeo Kanade have developed neural network-based approach to detect
frontal views of faces in gray-scale photographs. The algorithm and training methods are ubiquitous, and may be
used to recognise various types of faces as well as related objects and patterns. This saves the time-consuming task
of manually selecting non-face training examples, which must be picked to cover the full non-face picture space.
They discovered that the technology can detect 90.5 percent of faces.
Henry Schneiderman and Takeo Kanade described a statistical method for 3D object detection. They used a product
of histograms to express the statistics of object and non-object appearance. The combined statistics of a selection of
ABSTRACT
Facial Recognition is the most used technology nowadays. Apart from Bio-metrics, Iris scan, fingerprint recognition methodologies, facial
recognition is emerging recognition methodology these days. One of the most effective applications of this methodology is automated attendance
using facial recognition, which is contact less, secure, and effective unlike in tradition way (manual attendance) it saves more time. Methodology
used in this project involves Viola-Jones algorithm for face detection and Eigenfaces approach for feature selection and classification. In Viola-jones
algorithm inputs are taken as captured images of individual persons and produce a dataset containing cropped images of individual and these dataset
is directed to Eigenfaces approach as input and training of data occurs through the process of calculating eigen vectors for each eigenface. At the time
of testing, Euclidean distance between eigen vectors of testing image and eigen vectors of trained eigen faces determines the matched individual.
Facial recognition can also be done with PCA, which has 79.6 percent accuracy, and LBPH, which has 90.23 percent accuracy. However, when
employing the Eigenfaces technique, the accuracy is 93.07 percent. MATLAB software with Computer Vision Toolbox and Deep Learning Toolbox
is used for this work.
Keywords: Viola-Jones algorithm, Eigenfaces, Eigen vectors, Facial recognition, Recognition accuracy.
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
83
wavelet coefficients and their position on the object are represented by each histogram. They used a variety of
histograms to demonstrate a wide range of visual qualities. They built the first algorithm that can consistently
recognise human faces with out-of-plane rotation using this model. They used a test set of 208 photos containing
441 faces, 347 of which are in profile view, and the greatest accuracy observed was around 92.7 percent.
Paul Viola and Michael Jones developed a frontal face identification system that was completely different from
earlier systems in terms of its ability to recognise faces quickly. This method employs a new picture representation
known as an integral image, which aids in the rapid evaluation of features. A method for building a classifier that
involves utilising AdaBoost to choose a small number of significant features and adding gradually more composite
classifiers in a cascade structure to rapidly boost the detector's speed. Finally, the detection rate was discovered to
be 90%.
Ajay Kumar Bansal and Pankaj Chawla demonstrated the concept of the performance of face recognition using the
Principal Component Analysis (PCA) technique. The tests were done on the Otorhinolaryngology (ORL) database,
the Indian face database, and the Georgia Tech face database, which all have different expressions, poses, and facial
characteristics. In the experimental setup, the number of training photos for all databases was altered from 80% to
40%, which means that originally 80% of total images were used in training and 20% for testing, and then the ratio
was varied as 60/40, then 40/60. The comparison clearly reveals that PCA accuracy is 92.50 percent, 74.17 percent,
and 61.25 percent.
Mrunmayee Shirodkar, Varun Sinha, Urvi Jain, and Bhushan Nemade have presented a system for students that
include features such as face detection, feature extraction, feature detection, attendance analysis, and monthly
attendance report production. For face detection, the suggested system uses image contrasts, integral images,
Ada-Boost, Haar-like features, and a cascade classifier. Faces are recognised using an improved Local Binary
Pattern (LBP) that is utilised to recognise student faces utilising a database comprising photos of students. That
technology assisted them in achieving outcomes with a higher accuracy of 88.08 percent and less time consumption
thanks to a distinct mix of algorithms.
Suman Kumar Bhattacharyya and Kumar Rahul used LDA for Facial Recognition. They've tried using the ORL
face database. By using a linear discriminant criterion, the LDA approach overcomes the limitations of the
Principle Component Analysis (PCA) method. This criterion aims to maximise the ratio of the determinant of the
projected samples' between-class scatter matrix to the determinant of the projected samples' within-class scatter
matrix. The final experimental findings show a 92.5 percent recognition rate or correctness.
3. Face Recognition System
This work has three main steps:
(1) Building database using Viola Jones Algorithm.
(2) Feature Extraction using Eigen faces and Classification using Euclidean distance.
(3) Updating Attendance.
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
84
3.1. Building database using Viola-Jones Algorithm
First step of our project is to build database i.e. obtain only face from image. In simple terms we need a face locator.
Basically a face locator needs to tell whether a photo of optional size contains a human face and give if that is valid
or not and also it should tell where the face is located in the image. For this, we are using Viola Jones algorithm
which is named after two Computer Vision Researchers Paul Viola and Michael Jones. They proposed this method
in 2001 in their paper “Rapid Object Detection using a Boosted Cascade of Simple Features”.
This algorithm works well for frontal faces rather than faces looking upwards, sideways or downwards. First the
image is converted into a grayscale because it is easier to work with gray scale images rather than colored and there
will be lesser data to process with gray-scale images. This algorithm looks at many smaller sub-regions and tries to
find a face by looking for specific features in each sub-region. It needs to check many different positions and scales
because an image can contain many faces of various sizes.
Fig.1. Detection of Haar features
As you can see in above figure Viola-Jones outlines a box and searches for a face within the box. It is essentially
searching for these Haar-like features. The box moves a step to the right after going through every tile in the picture.
As you can see if face features are detected the box turns green else it is red.. Generally we can change the box size
and step size according to our needs. If we take smaller steps, then many number of boxes detect face-like features
(Haar-like features) and the data of all those boxes when aggregated helps the algorithm to determine where the
face is located in image.
Fig.2. Block diagram for building database using Viola-Jones
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
85
Fig.3. Database for each user
Each folder has consists of c number of images for each user.
3.2. Feature Extraction using eigenfaces and Classification using Euclidean distance
Here we create a folder for each user and store the facial images of that user in that folder. We have created 10
folders and named them as s1, s2, and so on upto s10. Each folder has 150 images of that particular user. These 150
images are of different pose. For example, s1 consists of 150 facial images of person 1 and similarly s2 contains
150 images of person 2. These 150 images are later used for testing and training. These facial images are collected
using Viola Jones algorithm. Each image should be of same size. We have to take the size of image as 92 pixels
width and 112 pixels height. The output of the detection part will be like given in the below figure.
Fig.4. Block diagram for Recognition and Updation
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
86
Fig.5. Flowchart
Here we create a folder for each user and store the facial images of that user in that folder. We have created 10
folders and named them as s1, s2, and so on upto s10. Each folder has 150 images of that particular user. These 150
images are of different pose. For example, s1 consists of 150 facial images of person 1 and similarly s2 contains
150 images of person 2. These 150 images are later used for testing and training. These facial images are collected
using Viola Jones algorithm. Each image should be of same size. We have to take the size of image as 92 pixels
width and 112 pixels height. The output of the detection part will be like given in the below figure.
Fig.6. Output of Face detection
3.2.1. Extracting Eigen values
Choose an image of face I (x,y) in two dimensional N *N arrangements. Then convert the image into the dimension
of N2
*1. Treat initially a training set of N N* images and it can be converted into N2
*1 dimensions. Now a training
set of N2
*M dimensions is created. Here the number of samples is M . Let 1, 2 ,3, …..M be the face images in
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
87
the training set. Next, compute the mean for the images in the training set. At that point, average face of the set is
defined by,
ψ =
∑ 
ⁱ (1)
Here, i is the Normalized Image Coefficient introduced to improve verification chances even for lowest matching
of random image with Eigen face image and is well-defined as square root of the sum of the squares of difference
between images and average face image divided by i.
ᶲⁱ =√∑

, i=1,2,3,…..M (2)
By using the results of the above step the matrix A is computed.
i.e., A 1 2 .....M
The matrix C (co-variance matrix) is formed by multiplying A by its transpose.
C=A*A T
(3)
Therefore the “dimension of the matrix C is N2
* N2
and determining the N2
Eigen vectors and Eigen values is an
intractable task for typical image sizes”. In the event that the quantity of information focuses in the picture space is
not exactly the element of the space (M<N2
). There will be just M 1 , as opposed to N2
important Eigen vectors. In
this way, consider a matrix Q=AT
A of dimension N*N . Next compute the Eigen values and Eigen vectors of the
matrix Q . Consider Eigen values i and Eigen vectors vi of Q such that
AT
Avi= i vi
A(AT
Avi )=iAvi
C.Avi=iAvi
Therefore, the Eigen vectors of co-variance matrix C is Avi
Express the Eigen vectors vi as a linear combination of M training set face images to compute the Eigen faces ui,
Where,
ui=∑ ikk ,i=1,2,3,…M, in particular
u1=v111+v122+v133+……+v1MM
u2= v211+v222+v233+……+v2MM
. . . . .
. . . . .
uM= vM11+vM22+vM33+……+vMMM
After acquiring the Eigen faces, the photographs in the database are predicted into the Eigen faces space, and loads
of the pictures in that space are stored.
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
88
Fig.7. Original images and corresponding Eigen Faces
The weights of the image on the Eigen face space are calculated by using the formula,
Wi ui
T
() (4)
To recognize the face first calculate the Euclidean distance between the Eigen face of the image and Eigen faces
stored previously.
For an unknown image, calculate  and ^= ∑ wiui where wi =ui
T
. Finally calculate the Euclidean distance
between  and ^.
If the Euclidean distance is minimum and it is below the threshold value, then the unknown image will be
identified. Otherwise the unknown image will not be recognized.
In all of the above cases i varies from 1,2,3,…..,n. We have done deep investigation and examination of key
features, which will play primal role in framing concluding the results of image identification over the data base.
The distinct image processing formulae has been framed and tested with small sample of images. Finally we
concluded last one is the best for identification of random image, even it is having very less common features with
mean/original image. So we concentrated and continued on the last one i.e. to prove the image metrics using this
parameter . This will surly give greater Euclidean distance and Mean square error in order to match the random
image with Eigen face image. Random image is the image of particular person at any moment. So using this
formula, it is easy to trim down the error values like Euclidean distance and Mean square error.
Fig.8. Block Diagram for Calculation of Eigen Faces
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
89
3.3. Updating Attendance
After recognizing the face, the last step is to update the attendance in the excel sheet in the corresponding column
based on the class number.
4. Performance Metrics
Confusion matrix can be defined as “visualizing the performance of your prediction model in tabular form”. Each
entry in a confusion matrix implies the number of predictions made by the model whether the classification is done
correctly or incorrectly. Classification based on alone accuracy can be misleading if you have an unequal number of
observations in each class or if we have more than two classes in our dataset.
True Positive (TP):
It is concerned with the amount of times the classifier correctly predicts the positive class to be positive.
True Negative (TN):
It is concerned with the amount of times a classifier correctly predicts a negative class as negative.
False Positive (FP):
It is concerned with the number of times the classifier has predicted the negative class as positive.
False Negative (FN):
It is concerned with the amount of times the classifier incorrectly forecasts the positive class as negative.
Confusion matrix should always be used as an evaluation criterion for machine learning models. It provides a model
performance metric that is both simple and effective. Here are some of the most prevalent confusion matrix-derived
performance measures.
Accuracy: It is the percentage of total samples correctly categorised by the classifier. Use the formula
(TP+TN)/(TP+TN+FP+FN) to calculate accuracy.
Misclassification Rate: It gives the information about what fraction of predictions were incorrect. It is also known
as Classification Error. You can calculate using (FP+FN)/(TP+TN+FP+FN) or (1-Accuracy).
5. Results & Conclusion
In this approach, automated attendance system using facial recognition is described and proposed model used
Viola-Jones for face detection and to build our database which is used for further process. And using Eigen Faces,
features are extracted and using Euclidean distance as classifier, input face is recognized and finally updated the
attendance sheet accordingly. The proposed model has a database with 10 users, and for each user model has taken
150 images. These 150 images of each user are used for both training and testing. And 80% of data is used for
training and 20% for testing. So, for each user 120 images are taken for training and 30 images for testing. And the
system has considered 5 users and used their data present in database for calculating TP, TN, FP, FNs.
Face recognition: This is one of the matched results in which input image is captured instantly and the output
image is recognized from the training dataset.
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
90
Fig.9. Correctly, Incorrectly recognized result and Confusion chart
Updating Attendance: This is finally updated automated attendance excel sheet in which, we can get total number
of present days for each student and can analyse the attendance percentage for each student.
Fig.10. Excel sheet before updating
Fig.11. Excel sheet after updating
Declarations
Source of Funding
This research did not receive any grant from funding agencies in the public, commercial, or not-for-profit sectors.
Competing Interests Statement
The authors declare no competing financial, professional and personal interests.
Asian Journal of Applied Science and Technology (AJAST)
Volume 6, Issue 2, Pages 82-91, April-June 2022
ISSN: 2456-883X www.ajast.net
91
Consent for publication
Authors declare that they consented for the publication of this research work.
References
[1] Ajay Kumar Bansal, Pankaj Chawla, (2013). Performance evaluation of face recognition using PCA and
N-PCA. International Journal of Computer Applications, 76(8): 14-20.
[2] Paul Viola, Michael J. Jones, (2014). Robust real-time face detection. International Journal of Computer Vision,
57(2): 137-154.
[3] Akash Singh, Shreya Bhatt, Abhishek Gupta, (2021). Automated attendance system with face recognition.
International Journal of Engineering Applied Sciences and Technology, 5(12).
[4] V. Jalaja, G.S.G.N. Anjaneyulu, (2020). Face recognition by using eigen face method. International Journal of
Scientific & Technology Research, 9(3): 961-966.
[5] Jaspreet Kaur, Anand Sharma, (2017). Performance analysis of face detection by using viola-jones algorithm.
International Journal of Computational Intelligence research, 13(5): 707-717.
[6] Ashish Choudhary, Abhishek Tripathi, Abhishek Bajaj, Mudit Rathi and B.M Nandini, (2016). Automatic
attendance system using face recognition. International Journal of Modern Trends in Engineering and Research,
3(4): 362-365.
[7] Marijeta Slavkovic, Dubravka Jevtic, (2012). Face recognition using eigenface approach. Serbian Journal of
Electrical Engineering, 9(1): 121-130.

More Related Content

PDF
Efficient Face Features Extraction and Recognition Using Principal Component...
PDF
Face Recognition Smart Attendance System- A Survey
PDF
Technique for recognizing faces using a hybrid of moments and a local binary...
PDF
Face Recognition Smart Attendance System: (InClass System)
PDF
Paper id 24201475
PDF
IRJET- Emotionalizer : Face Emotion Detection System
PDF
IRJET - Emotionalizer : Face Emotion Detection System
PDF
Facial expression recongnition Techniques, Database and Classifiers
Efficient Face Features Extraction and Recognition Using Principal Component...
Face Recognition Smart Attendance System- A Survey
Technique for recognizing faces using a hybrid of moments and a local binary...
Face Recognition Smart Attendance System: (InClass System)
Paper id 24201475
IRJET- Emotionalizer : Face Emotion Detection System
IRJET - Emotionalizer : Face Emotion Detection System
Facial expression recongnition Techniques, Database and Classifiers

Similar to Automated Attendance System Based on Facial Recognition using Viola-Jones Algorithm (20)

PDF
FACE DETECTION USING PRINCIPAL COMPONENT ANALYSIS
PDF
IRJET-Comparision of PCA and LDA Techniques for Face Recognition Feature Base...
PDF
Attendance System using Facial Recognition
PDF
Human Face Detection and Tracking for Age Rank, Weight and Gender Estimation ...
PDF
Happiness Expression Recognition at Different Age Conditions
PDF
IRJET - Face Recognition based Attendance System: Review
PDF
Face Recognition Based Attendance System with Auto Alert to Guardian using Ca...
DOCX
Face recognition system
PDF
Paper of Final Year Project.pdf
PDF
Face Detection Using Modified Viola Jones Algorithm
PDF
IRJET- Survey of Iris Recognition Techniques
PDF
Adversarial Multi Scale Features Learning for Person Re Identification
PDF
76 s201920
PDF
Human Face Detection and Tracking for Age Rank, Weight and Gender Estimation ...
PDF
Local Descriptor based Face Recognition System
PDF
IRJET- Survey on Face Recognition using Biometrics
PDF
IRJET- Spot Me - A Smart Attendance System based on Face Recognition
PDF
Implementation of Face Recognition in Cloud Vision Using Eigen Faces
PDF
Real Time Image Based Attendance System using Python
PDF
Criminal Detection System
FACE DETECTION USING PRINCIPAL COMPONENT ANALYSIS
IRJET-Comparision of PCA and LDA Techniques for Face Recognition Feature Base...
Attendance System using Facial Recognition
Human Face Detection and Tracking for Age Rank, Weight and Gender Estimation ...
Happiness Expression Recognition at Different Age Conditions
IRJET - Face Recognition based Attendance System: Review
Face Recognition Based Attendance System with Auto Alert to Guardian using Ca...
Face recognition system
Paper of Final Year Project.pdf
Face Detection Using Modified Viola Jones Algorithm
IRJET- Survey of Iris Recognition Techniques
Adversarial Multi Scale Features Learning for Person Re Identification
76 s201920
Human Face Detection and Tracking for Age Rank, Weight and Gender Estimation ...
Local Descriptor based Face Recognition System
IRJET- Survey on Face Recognition using Biometrics
IRJET- Spot Me - A Smart Attendance System based on Face Recognition
Implementation of Face Recognition in Cloud Vision Using Eigen Faces
Real Time Image Based Attendance System using Python
Criminal Detection System
Ad

More from Associate Professor in VSB Coimbatore (20)

PDF
Usmonkhoja Polatkhoja’s Son and His Role in National Liberation Movements of ...
PDF
Flood Vulnerability Mapping using Geospatial Techniques: Case Study of Lagos ...
PDF
Improvement in Taif Roses’ Perfume Manufacturing Process by Using Work Study ...
PDF
A Systematic Review on Various Factors Influencing Employee Retention
PDF
Digital Planting Pot for Smart Irrigation
PDF
Methodologies for Resolving Data Security and Privacy Protection Issues in Cl...
PDF
Determine the Importance Level of Criteria in Creating Cultural Resources’ At...
PDF
New One-Pot Synthetic Route and Spectroscopic Characterization of Hydroxo-Bri...
PDF
A Review on the Distribution, Nutritional Status and Biological Activity of V...
PDF
Psoralen Promotes Myogenic Differentiation of Muscle Cells to Repair Fracture
PDF
Saliva: An Economic and Reliable Alternative for the Detection of SARS-CoV-2 ...
PDF
Ecological Footprint of Food Consumption in Ijebu Ode, Nigeria
PDF
PDF
Biocompatible Molybdenum Complexes Based on Terephthalic Acid and Derived fro...
PDF
Influence of Low Intensity Aerobic Exercise Training on the Vo2 Max in 11 to ...
PDF
Effects of Planting Ratio and Planting Distance on Kadaria 1 Hybrid Rice Seed...
PDF
Study of the Cassava Production System in the Department of Tivaouane, Senegal
PDF
Study of the Cassava Production System in the Department of Tivaouane, Senegal
PDF
Burnout of Nurses in Nursing Homes: To What Extent Age, Education, Length of ...
PDF
Hepatitis and its Transmission Through Needlestick Injuries
Usmonkhoja Polatkhoja’s Son and His Role in National Liberation Movements of ...
Flood Vulnerability Mapping using Geospatial Techniques: Case Study of Lagos ...
Improvement in Taif Roses’ Perfume Manufacturing Process by Using Work Study ...
A Systematic Review on Various Factors Influencing Employee Retention
Digital Planting Pot for Smart Irrigation
Methodologies for Resolving Data Security and Privacy Protection Issues in Cl...
Determine the Importance Level of Criteria in Creating Cultural Resources’ At...
New One-Pot Synthetic Route and Spectroscopic Characterization of Hydroxo-Bri...
A Review on the Distribution, Nutritional Status and Biological Activity of V...
Psoralen Promotes Myogenic Differentiation of Muscle Cells to Repair Fracture
Saliva: An Economic and Reliable Alternative for the Detection of SARS-CoV-2 ...
Ecological Footprint of Food Consumption in Ijebu Ode, Nigeria
Biocompatible Molybdenum Complexes Based on Terephthalic Acid and Derived fro...
Influence of Low Intensity Aerobic Exercise Training on the Vo2 Max in 11 to ...
Effects of Planting Ratio and Planting Distance on Kadaria 1 Hybrid Rice Seed...
Study of the Cassava Production System in the Department of Tivaouane, Senegal
Study of the Cassava Production System in the Department of Tivaouane, Senegal
Burnout of Nurses in Nursing Homes: To What Extent Age, Education, Length of ...
Hepatitis and its Transmission Through Needlestick Injuries
Ad

Recently uploaded (20)

PDF
PPT on Performance Review to get promotions
PDF
Well-logging-methods_new................
PPTX
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PDF
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
PDF
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
PPTX
MCN 401 KTU-2019-PPE KITS-MODULE 2.pptx
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PPTX
Internet of Things (IOT) - A guide to understanding
PPTX
Sustainable Sites - Green Building Construction
DOCX
573137875-Attendance-Management-System-original
PDF
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PDF
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
PPTX
UNIT 4 Total Quality Management .pptx
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
PPTX
Welding lecture in detail for understanding
PPT on Performance Review to get promotions
Well-logging-methods_new................
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
MCN 401 KTU-2019-PPE KITS-MODULE 2.pptx
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
Internet of Things (IOT) - A guide to understanding
Sustainable Sites - Green Building Construction
573137875-Attendance-Management-System-original
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
UNIT 4 Total Quality Management .pptx
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
Welding lecture in detail for understanding

Automated Attendance System Based on Facial Recognition using Viola-Jones Algorithm

  • 1. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 82 Automated Attendance System Based on Facial Recognition using Viola-Jones Algorithm N. Dhana Lakshmi1 , Pranavi Nagubandi2 , Muralidhar Yeleti3 & K.Vishnu Vardan4 1 Assistant Professor, Department of ECE, CBIT, Hyderabad, Telangana, India. 2-4 UG Students, Department of ECE, CBIT, Hyderabad, Telangana, India. DOI: http://doi.org/10.38177/ajast.2022.6210 Copyright: © 2022 N.Dhana Lakshmi et al. This is an open access article distributed under the terms of the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original author and source are credited. Article Received: 22 February 2022 Article Accepted: 26 April 2022 Article Published: 30 May 2022 1. Introduction Automated Time and Attendance marking system can help schools and higher education in many ways. There is no doubt that an attendance management system will surely save lot of time and money by eliminating a great deal of manual processes involved in attendance and leave entry and calculating hours attended. Since the attendance is automated, the data is accurate and error-free. Once the attendance is marked, the captured data gets stored in the student attendance system. This feature is especially useful while locating a particular student or while analysing trends. A face recognition system is a computer application capable of identifying or verifying a person from a digital image. One of the ways to do this is by comparing selected facial features from the image and a face database. Automated Attendance System is the advancement that has taken place in the field of automation replacing traditional attendance marking activity. Generally an Attendance Management System which is developed using bio-metrics, but in our case we collect the facial data base using face detecting algorithm and Classifying them using Eigen faces approach. 2. Literature Survey Henry A. Rowley, Shumeet Baluja, and Takeo Kanade have developed neural network-based approach to detect frontal views of faces in gray-scale photographs. The algorithm and training methods are ubiquitous, and may be used to recognise various types of faces as well as related objects and patterns. This saves the time-consuming task of manually selecting non-face training examples, which must be picked to cover the full non-face picture space. They discovered that the technology can detect 90.5 percent of faces. Henry Schneiderman and Takeo Kanade described a statistical method for 3D object detection. They used a product of histograms to express the statistics of object and non-object appearance. The combined statistics of a selection of ABSTRACT Facial Recognition is the most used technology nowadays. Apart from Bio-metrics, Iris scan, fingerprint recognition methodologies, facial recognition is emerging recognition methodology these days. One of the most effective applications of this methodology is automated attendance using facial recognition, which is contact less, secure, and effective unlike in tradition way (manual attendance) it saves more time. Methodology used in this project involves Viola-Jones algorithm for face detection and Eigenfaces approach for feature selection and classification. In Viola-jones algorithm inputs are taken as captured images of individual persons and produce a dataset containing cropped images of individual and these dataset is directed to Eigenfaces approach as input and training of data occurs through the process of calculating eigen vectors for each eigenface. At the time of testing, Euclidean distance between eigen vectors of testing image and eigen vectors of trained eigen faces determines the matched individual. Facial recognition can also be done with PCA, which has 79.6 percent accuracy, and LBPH, which has 90.23 percent accuracy. However, when employing the Eigenfaces technique, the accuracy is 93.07 percent. MATLAB software with Computer Vision Toolbox and Deep Learning Toolbox is used for this work. Keywords: Viola-Jones algorithm, Eigenfaces, Eigen vectors, Facial recognition, Recognition accuracy.
  • 2. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 83 wavelet coefficients and their position on the object are represented by each histogram. They used a variety of histograms to demonstrate a wide range of visual qualities. They built the first algorithm that can consistently recognise human faces with out-of-plane rotation using this model. They used a test set of 208 photos containing 441 faces, 347 of which are in profile view, and the greatest accuracy observed was around 92.7 percent. Paul Viola and Michael Jones developed a frontal face identification system that was completely different from earlier systems in terms of its ability to recognise faces quickly. This method employs a new picture representation known as an integral image, which aids in the rapid evaluation of features. A method for building a classifier that involves utilising AdaBoost to choose a small number of significant features and adding gradually more composite classifiers in a cascade structure to rapidly boost the detector's speed. Finally, the detection rate was discovered to be 90%. Ajay Kumar Bansal and Pankaj Chawla demonstrated the concept of the performance of face recognition using the Principal Component Analysis (PCA) technique. The tests were done on the Otorhinolaryngology (ORL) database, the Indian face database, and the Georgia Tech face database, which all have different expressions, poses, and facial characteristics. In the experimental setup, the number of training photos for all databases was altered from 80% to 40%, which means that originally 80% of total images were used in training and 20% for testing, and then the ratio was varied as 60/40, then 40/60. The comparison clearly reveals that PCA accuracy is 92.50 percent, 74.17 percent, and 61.25 percent. Mrunmayee Shirodkar, Varun Sinha, Urvi Jain, and Bhushan Nemade have presented a system for students that include features such as face detection, feature extraction, feature detection, attendance analysis, and monthly attendance report production. For face detection, the suggested system uses image contrasts, integral images, Ada-Boost, Haar-like features, and a cascade classifier. Faces are recognised using an improved Local Binary Pattern (LBP) that is utilised to recognise student faces utilising a database comprising photos of students. That technology assisted them in achieving outcomes with a higher accuracy of 88.08 percent and less time consumption thanks to a distinct mix of algorithms. Suman Kumar Bhattacharyya and Kumar Rahul used LDA for Facial Recognition. They've tried using the ORL face database. By using a linear discriminant criterion, the LDA approach overcomes the limitations of the Principle Component Analysis (PCA) method. This criterion aims to maximise the ratio of the determinant of the projected samples' between-class scatter matrix to the determinant of the projected samples' within-class scatter matrix. The final experimental findings show a 92.5 percent recognition rate or correctness. 3. Face Recognition System This work has three main steps: (1) Building database using Viola Jones Algorithm. (2) Feature Extraction using Eigen faces and Classification using Euclidean distance. (3) Updating Attendance.
  • 3. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 84 3.1. Building database using Viola-Jones Algorithm First step of our project is to build database i.e. obtain only face from image. In simple terms we need a face locator. Basically a face locator needs to tell whether a photo of optional size contains a human face and give if that is valid or not and also it should tell where the face is located in the image. For this, we are using Viola Jones algorithm which is named after two Computer Vision Researchers Paul Viola and Michael Jones. They proposed this method in 2001 in their paper “Rapid Object Detection using a Boosted Cascade of Simple Features”. This algorithm works well for frontal faces rather than faces looking upwards, sideways or downwards. First the image is converted into a grayscale because it is easier to work with gray scale images rather than colored and there will be lesser data to process with gray-scale images. This algorithm looks at many smaller sub-regions and tries to find a face by looking for specific features in each sub-region. It needs to check many different positions and scales because an image can contain many faces of various sizes. Fig.1. Detection of Haar features As you can see in above figure Viola-Jones outlines a box and searches for a face within the box. It is essentially searching for these Haar-like features. The box moves a step to the right after going through every tile in the picture. As you can see if face features are detected the box turns green else it is red.. Generally we can change the box size and step size according to our needs. If we take smaller steps, then many number of boxes detect face-like features (Haar-like features) and the data of all those boxes when aggregated helps the algorithm to determine where the face is located in image. Fig.2. Block diagram for building database using Viola-Jones
  • 4. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 85 Fig.3. Database for each user Each folder has consists of c number of images for each user. 3.2. Feature Extraction using eigenfaces and Classification using Euclidean distance Here we create a folder for each user and store the facial images of that user in that folder. We have created 10 folders and named them as s1, s2, and so on upto s10. Each folder has 150 images of that particular user. These 150 images are of different pose. For example, s1 consists of 150 facial images of person 1 and similarly s2 contains 150 images of person 2. These 150 images are later used for testing and training. These facial images are collected using Viola Jones algorithm. Each image should be of same size. We have to take the size of image as 92 pixels width and 112 pixels height. The output of the detection part will be like given in the below figure. Fig.4. Block diagram for Recognition and Updation
  • 5. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 86 Fig.5. Flowchart Here we create a folder for each user and store the facial images of that user in that folder. We have created 10 folders and named them as s1, s2, and so on upto s10. Each folder has 150 images of that particular user. These 150 images are of different pose. For example, s1 consists of 150 facial images of person 1 and similarly s2 contains 150 images of person 2. These 150 images are later used for testing and training. These facial images are collected using Viola Jones algorithm. Each image should be of same size. We have to take the size of image as 92 pixels width and 112 pixels height. The output of the detection part will be like given in the below figure. Fig.6. Output of Face detection 3.2.1. Extracting Eigen values Choose an image of face I (x,y) in two dimensional N *N arrangements. Then convert the image into the dimension of N2 *1. Treat initially a training set of N N* images and it can be converted into N2 *1 dimensions. Now a training set of N2 *M dimensions is created. Here the number of samples is M . Let 1, 2 ,3, …..M be the face images in
  • 6. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 87 the training set. Next, compute the mean for the images in the training set. At that point, average face of the set is defined by, ψ = ∑  ⁱ (1) Here, i is the Normalized Image Coefficient introduced to improve verification chances even for lowest matching of random image with Eigen face image and is well-defined as square root of the sum of the squares of difference between images and average face image divided by i. ᶲⁱ =√∑  , i=1,2,3,…..M (2) By using the results of the above step the matrix A is computed. i.e., A 1 2 .....M The matrix C (co-variance matrix) is formed by multiplying A by its transpose. C=A*A T (3) Therefore the “dimension of the matrix C is N2 * N2 and determining the N2 Eigen vectors and Eigen values is an intractable task for typical image sizes”. In the event that the quantity of information focuses in the picture space is not exactly the element of the space (M<N2 ). There will be just M 1 , as opposed to N2 important Eigen vectors. In this way, consider a matrix Q=AT A of dimension N*N . Next compute the Eigen values and Eigen vectors of the matrix Q . Consider Eigen values i and Eigen vectors vi of Q such that AT Avi= i vi A(AT Avi )=iAvi C.Avi=iAvi Therefore, the Eigen vectors of co-variance matrix C is Avi Express the Eigen vectors vi as a linear combination of M training set face images to compute the Eigen faces ui, Where, ui=∑ ikk ,i=1,2,3,…M, in particular u1=v111+v122+v133+……+v1MM u2= v211+v222+v233+……+v2MM . . . . . . . . . . uM= vM11+vM22+vM33+……+vMMM After acquiring the Eigen faces, the photographs in the database are predicted into the Eigen faces space, and loads of the pictures in that space are stored.
  • 7. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 88 Fig.7. Original images and corresponding Eigen Faces The weights of the image on the Eigen face space are calculated by using the formula, Wi ui T () (4) To recognize the face first calculate the Euclidean distance between the Eigen face of the image and Eigen faces stored previously. For an unknown image, calculate  and ^= ∑ wiui where wi =ui T . Finally calculate the Euclidean distance between  and ^. If the Euclidean distance is minimum and it is below the threshold value, then the unknown image will be identified. Otherwise the unknown image will not be recognized. In all of the above cases i varies from 1,2,3,…..,n. We have done deep investigation and examination of key features, which will play primal role in framing concluding the results of image identification over the data base. The distinct image processing formulae has been framed and tested with small sample of images. Finally we concluded last one is the best for identification of random image, even it is having very less common features with mean/original image. So we concentrated and continued on the last one i.e. to prove the image metrics using this parameter . This will surly give greater Euclidean distance and Mean square error in order to match the random image with Eigen face image. Random image is the image of particular person at any moment. So using this formula, it is easy to trim down the error values like Euclidean distance and Mean square error. Fig.8. Block Diagram for Calculation of Eigen Faces
  • 8. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 89 3.3. Updating Attendance After recognizing the face, the last step is to update the attendance in the excel sheet in the corresponding column based on the class number. 4. Performance Metrics Confusion matrix can be defined as “visualizing the performance of your prediction model in tabular form”. Each entry in a confusion matrix implies the number of predictions made by the model whether the classification is done correctly or incorrectly. Classification based on alone accuracy can be misleading if you have an unequal number of observations in each class or if we have more than two classes in our dataset. True Positive (TP): It is concerned with the amount of times the classifier correctly predicts the positive class to be positive. True Negative (TN): It is concerned with the amount of times a classifier correctly predicts a negative class as negative. False Positive (FP): It is concerned with the number of times the classifier has predicted the negative class as positive. False Negative (FN): It is concerned with the amount of times the classifier incorrectly forecasts the positive class as negative. Confusion matrix should always be used as an evaluation criterion for machine learning models. It provides a model performance metric that is both simple and effective. Here are some of the most prevalent confusion matrix-derived performance measures. Accuracy: It is the percentage of total samples correctly categorised by the classifier. Use the formula (TP+TN)/(TP+TN+FP+FN) to calculate accuracy. Misclassification Rate: It gives the information about what fraction of predictions were incorrect. It is also known as Classification Error. You can calculate using (FP+FN)/(TP+TN+FP+FN) or (1-Accuracy). 5. Results & Conclusion In this approach, automated attendance system using facial recognition is described and proposed model used Viola-Jones for face detection and to build our database which is used for further process. And using Eigen Faces, features are extracted and using Euclidean distance as classifier, input face is recognized and finally updated the attendance sheet accordingly. The proposed model has a database with 10 users, and for each user model has taken 150 images. These 150 images of each user are used for both training and testing. And 80% of data is used for training and 20% for testing. So, for each user 120 images are taken for training and 30 images for testing. And the system has considered 5 users and used their data present in database for calculating TP, TN, FP, FNs. Face recognition: This is one of the matched results in which input image is captured instantly and the output image is recognized from the training dataset.
  • 9. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 90 Fig.9. Correctly, Incorrectly recognized result and Confusion chart Updating Attendance: This is finally updated automated attendance excel sheet in which, we can get total number of present days for each student and can analyse the attendance percentage for each student. Fig.10. Excel sheet before updating Fig.11. Excel sheet after updating Declarations Source of Funding This research did not receive any grant from funding agencies in the public, commercial, or not-for-profit sectors. Competing Interests Statement The authors declare no competing financial, professional and personal interests.
  • 10. Asian Journal of Applied Science and Technology (AJAST) Volume 6, Issue 2, Pages 82-91, April-June 2022 ISSN: 2456-883X www.ajast.net 91 Consent for publication Authors declare that they consented for the publication of this research work. References [1] Ajay Kumar Bansal, Pankaj Chawla, (2013). Performance evaluation of face recognition using PCA and N-PCA. International Journal of Computer Applications, 76(8): 14-20. [2] Paul Viola, Michael J. Jones, (2014). Robust real-time face detection. International Journal of Computer Vision, 57(2): 137-154. [3] Akash Singh, Shreya Bhatt, Abhishek Gupta, (2021). Automated attendance system with face recognition. International Journal of Engineering Applied Sciences and Technology, 5(12). [4] V. Jalaja, G.S.G.N. Anjaneyulu, (2020). Face recognition by using eigen face method. International Journal of Scientific & Technology Research, 9(3): 961-966. [5] Jaspreet Kaur, Anand Sharma, (2017). Performance analysis of face detection by using viola-jones algorithm. International Journal of Computational Intelligence research, 13(5): 707-717. [6] Ashish Choudhary, Abhishek Tripathi, Abhishek Bajaj, Mudit Rathi and B.M Nandini, (2016). Automatic attendance system using face recognition. International Journal of Modern Trends in Engineering and Research, 3(4): 362-365. [7] Marijeta Slavkovic, Dubravka Jevtic, (2012). Face recognition using eigenface approach. Serbian Journal of Electrical Engineering, 9(1): 121-130.