Smart Attendance Face Recognision Using Machine Learning 2
Smart Attendance Face Recognision Using Machine Learning 2
Smart Attendance Face Recognision Using Machine Learning 2
SUBMITTED BY
PRANAV GHASGHASE
MURTAZA BURHANI
ROHAN POPHALE
HARISH YADAV
GUIDED BY
UNIVERSITY OF MUMBAI
2021-22
CERTIFICATE
Date: ____________
This is to certify that, the project work embodied in this report entitled, “FACIAL
RECOGNITION BASED ATTENDANCE SYSTEM” submitted by Pranav Ghasghase Roll
No. 415, Murtaza Burhani Roll No. 439, Rohan Pophale Roll No. 451, Harish Yadav Roll No.
477, for the award of Second year of Engineering (B.E.) degree in the subject of Information
Technology, is a work carried out by them under my guidance and supervision within the
institute. The work described in this project report is carried out by the concerned students and
has not been submitted for the award of any other degree of the University of Mumbai.
Further, it is certified that the students were regular during the academic year 2021-2022 and have
worked under the guidance of concerned faculty until the submission of this project work at Rajiv
Gandhi Institute of Technology, Mumbai.
2
CERTIFICATE OF APPROVAL
SEAL OF
INSTITUTE
________________ ________________
Date:
Place:
3
DECLARATION
I declare that this written submission represents my ideas in my own words and where others'
ideas or words have been included, I have adequately cited and referenced the original sources. I
also declare that I have adhered to all principles of academic honesty and integrity and have not
misrepresented or fabricated or falsified any idea/data/fact/source in my submission. I understand
that any violation of the above will be cause for disciplinary action by the Institute and can also
evoke penal action from the sources which have thus not been properly cited or from whom
proper permission has not been taken when needed.
Date:
Place:
4
ACKNOWLEDGEMENT
With all reverence, we take the opportunity to express our deep sense of gratitude and
wholehearted indebtedness to our respected guide, Prof. Abhay E. Patil Department of
Information Technology, Rajiv Gandhi Institute of Technology, Mumbai. From the day of
conception of this project his active involvement and motivating guidance on day-to-day basis has
made it possible for us to complete this challenging work in time.
We would like to express a deep sense of gratitude to our respected Head of the Department,
Dr. Sunil B. Wankhade who went all the way out to help us in all genuine cases during the
course of doing this project. We wish to express our sincere thanks to Dr. Sanjay U. Bokade,
Principal,
Rajiv Gandhi Institute of Technology, Mumbai and would to like to acknowledge specifically for
giving guidance, encouragement and inspiration throughout the academics.
We would like to thank all the staff of Information Technology Department who continuously
supported and motivated during our work. Also, we would like to thank our colleagues for their
continuous support and motivation during the project work. Finally, we would like to express our
gratitude to our family for their eternal belief in us. We would not be where we are today without
their support and encouragement.
Pranav Ghasghase
Murtaza Burhani
Rohan Pophale
Harish Yadav
Date:
Place:
5
INDEX
Chapters Title of the Chapter/s Pages
Chapter 6 References
6
CHAPTER - 1
INTRODUCTION
Faces are the most decorated pictures in the visual system within the life time of a human being. it
is not surprising that humans have the ability to recognize faces. With regards to face recognition
by humans, it is thought that the brain remembers important details such as the shapes and colors
of crucial features corresponding to the eyes, nose, forehead, cheeks and the mouth. Thus, this
work is aimed at developing a face recognition system that will be able to detect an imperfect
human face and tell whose face it is.
Face recognition has been a very trending and developing area of research. There is continuous
research in the domain of face recognition and it has reached a point where a computer recognises
human face better than humans ourselves. As such it has become a very reliable technique to use
in security applications like Theft monitoring systems, criminal database etc. Face recognition can
also be used in educational institutes for taking attendance. Manually taking attendance by calling
out individual student’s name one by name is a time-consuming process, hence inefficient. Face
recognition based attendance system is by far the best solution to address this problem.
With the computational power of Machine learning, it is possible to build an efficient face
recognition model. In the proposed work, Python implementation of Facenet algorithm is used
and is tested on the standard AT&T orl face dataset. This dataset contains photographs of 40
individuals with 10 photographs each with varied poses. It was found in the proposed work that
Facenet produces 100% accuracy on this dataset. In the proposed model, the versatility of Google
Drive helps to indirectly connect a smartphone to a laptop/desktop so that an image clicked on the
smartphone can be accessed automatically by the Laptop to fetch and process it. This is the
novelty of the proposed work which doesn’t cost extra electronic hardware than what the faculty
of most educational institutes already have.
Due to increased demand of security day by day verifying identities, internet connections, online
communications led the researchers to find ways for these problems. Along with this facial
recognition systems are main part in finding solutions to these problems. Identity of any person is
incomplete without facial recognition. Just like any other form of biometric identification, face
recognition requires samples to be collected, identified, extracted with
necessary (features) information, and stored for recognition.
7
This Facial Recognition Based Attendance System is a project for Educational Institutions.
In this chapter, the problem and motivation, research objectives, project scope, project
contributions and the background information of the project will be discussed in detail.
According to the previous attendance management system, the accuracy of the data collected is
the biggest issue. This is because the attendance might not be recorded personally by the original
person, in another word, the attendance of a particular person can be taken by a third party
without the realization of the institution which violates the accuracy of the data. For example,
student A is lazy to attend a particular class, so student B helped him/her to sign for the
attendance which in fact student A didn’t attend the class, but the system overlooked this matter
due to no enforcement practiced. Supposing the institution establish an enforcement, it
might need to waste a lot of human resource and time which in turn will not be practical at all.
Thus, all the recorded attendance in the previous system is not reliable for analysis usage. The
second problem of the previous system is where it is too time consuming. Assuming the time
taken for a student to sign his/her attendance on a 3-4 paged name list is approximately 1 minute.
In 1 hour, only approximately 60 students can sign their attendance which is obviously inefficient
and time consuming. The third issue is with the accessibility of those information by the
legitimate concerned party. For an example, most of the parents are very concerned to track their
child’s actual whereabouts to ensure their kid really attend the classes in college/school. However
in the previous system, there are no ways for the parents to access such information. Therefore,
evolution is needed to be done to the previous system to improve efficiency, data accuracy and
provides accessibility to the information for those legitimate party.
In order to solve the drawbacks of the previous system stated in 1.1, the existing system will need
to evolve. The proposed system will reduce the paperwork where attendance will no longer
involve any manual recording. The new system will also reduce the total time needed to do
attendance recording. The new system will acquire individual attendance by means of
facial recognition to secure data accuracy of the attendance.
8
To ensure the speed of the attendance recording process is faster than the previous system
which can go as fast as approximately 3 second for each student.
Have enough memory space to store the database.
Able to recognize the face of an individual accurately based on the face database.
Allow parents to track their child’s attendance.
Develop a database for the attendance management system.
Provide a user-friendly interface for admins to access the attendance database and for non-
admins (parents) to check their child’s attendance by mailing the attendance.
Allow new students or staff to store their faces in the database by using a GUI.
Able to show an indication to the user whether the face- recognition process is successful or
not.
The main intention of this project is to solve the issues encountered in the old attendance
system while reproducing a brand new innovative smart system that can provide
convenience to the institution. In this project, an application will be developed which is
capable of recognising the identity of each individuals and eventually record down the data
into a database system. Apart from that, an excel sheet is created which shows the students
attendance and is directly mailed to the respected faculty.
9
1.5 Impact, Significance and Contributions
Many attendance management systems that exist nowadays are lack of efficiency and information
sharing. Therefore, in this project, those limitations will be overcome and also further improved
and are as follows :
Students will be more punctual on attending classes. This is due to the attendance of a
student can only be taken personally where any absentees will be noticed by the system.
This can not only train the student to be punctual as well as avoids any immoral ethics
such as signing the attendance for their friends.
The institution can save a lot of resources as enforcement are now done by means often
technology rather than human supervision which will waste a lot of human resource for an
insignificant process.
The application can operate on any device at any location as long as there is Wi-Fi coverage
or Ethernet connection which makes the attendance system to be portable to be placed at
any intended location. For example, the device can be placed at the entrance of the
classroom to take the attendance.
It saves a lot of cost in the sense that it had eliminated the paperwork completely.
The system is also time effective because all calculations are all automated. In short, the
project is developed to solve the existing issues in the old attendance system.
10
CHAPTER - 2
LITERATURE SURVEY
2.1Smart Attendance System based on Machine Learning
Authors: Harish M, Chethan P, Prajna N Holla K, Syed Abdul Azeem, M.G. Veena
JSS Science and Technology University (SJCE), Mysuru, Karnataka, India.
There have been many attempts to automate the attendance marking system. Some of the major
works are briefed here:
A Fingerprint based attendance system was proposed by Sanjay Badhe et al. which uses a
Fingerprint module to take the fingerprint of the student. The fingerprint data is stored in a
computer wherein the Fingerprint is recognised based on the data obtained from the
Microcontroller. Although this model automates the process a little bit, students still have to wait
for their turn to register their fingerprint to mark their attendance, which is time consuming.
A Speech Biometric based attendance system proposed by Subhadeep Dey et al., uses speech
characteristics of a human being to distinguish between humans and recognise them. The user
accesses the system by making a call from few pre-decided mobile phones. An interactive voice
response (IVR) system guides a new user to enrol for the database while an enrolled member is
guided through the verification process.
The proposed model in this paper is an attempt to overcome all the shortcomings of the previous
related works in the domain of smart attendance system. Machine learning based Facenet model
has high accuracy to distinguish and recognise wide spectrum of faces with varied poses and
lighting conditions. Histogram of Gradients (HOG) method is used in the Facenet to detect the
faces from the surrounding environment. If there are multiple faces in a single picture, which is
the case in classrooms, this method segments the entire image and fetches individual faces
separately and later it is sent through the Facenet model to get individual predictions.
Images of the classroom is taken by the lecturer’s smartphone. The number of images depends on
the size of the classroom and the field of view of the smartphone camera so as to capture the
entire length and breadth of the classroom and not miss out any student’s face.
The program to fetch this image from the database, which will be stored in the lecturer’s laptop.
Upon detecting images, the program automatically downloads them, runs it through the Facenet
model, gets the predictions of all the students and the attendance status is sent to the concerned
lecturer/faculty through email. The attendance status file will be a comma separated values (csv)
file which contains the present or absent status of all students including their total attendance
percentage.
11
2.2
12
2.3 Automatic Students Attendance Marking System Using Image
Processing And Machine Learning
Authors: Vidya Patil, Anushka Narayan, Vaishnavi Ausekar, Anahita Dinesh
MIT,Pune
While studying related work in the field, there is so many recent works done by many researchers
in the area of ‘Automatic attendance marking systems’. Sawhney et al. proposed a model for
marking an automated attendance of the students in a class by using a face recognition method
with Eigenvalues and Convolutional Neural Network (CNN). Face detection and recognition
algorithms are proposed to be applied to both the cameras outside as well as inside the classroom.
Viola-Jones algorithm is proposed for face detection and Principal Component Analysis (PCA)
technique is proposed for feature selection while creating face image training dataset. Actual
implementation results are not given in the paper. Sovitkar and Kawathekar used the Viola Jones
algorithm for detection of the faces. For feature selection, they used algorithms such as LDA,
PCA and hybrid approach using both of these with SVM as a classifier.
They created dataset using different facial expressions, poses and lighting conditions. They
achieved maximum success rates as 90.1% for PCA, 92.3% for LDA and 95.6% with Hybrid
approach. Average rate of recognition with the combination of all algorithms showed is 95%.
There is decrease in the recognition rate as persons to be identified increases. Matilda and Shahin
implemented a system for student face detection and recognition using a video stream.
Implementation is done using Viola-Jones Algorithm along with Haar cascade filters for face
detection and recognition. Upon matching of the captured face image features with the student’s
recorded features, attendance is marked in an Excel sheet.
Dmello et al. proposed an attendance management system based on detection and recognition of s
tudent’s faces present in a class and mark recognized students’ attendance automatically. They
used IOT cameras to capture the students’ faces. CNN, along with SVM classifier is used for
face recognition. The system gives an accuracy of 94%. Rekha and Ramprasad proposed a system
which automates marking of the attendance by face recognition method using Eigenface database
along with the PCA technique. The database contains the images of 15 different persons with 10
images per person. A similarity score is calculated between the new face detected and images
present in the database. If the similarity score is greater than 0.3 face is recognized and the Excel
sheet gets updated.
13
METHODLOGY / PERPOSED SYSTEM
The present system of attendance marking i.e., manually calling out the roll call by the
faculty have quite satisfactorily served the purpose. With the change in the educational
system with the introduction of new technologies in classroom such as virtual classroom,
the traditional way of taking attendance may not be viable anymore. Even with rising
number of course of study offered by universities, processing of attendance manually could
be time consuming. Hence, in our project we aim at creating a system to take attendance
using facial recognition technology in classrooms and creating an efficient database to
record them.
Image Acquisition:
Our proposed system uses a camera mounted at a proper place for acquiring students’ face
images in a controlled environment.
Image Pre-processing:
For image pre-processing, histogram equalization is used to enhance input image quality.
Face Detection:
Face is detected from the image using Viola-Jones and HAAR Cascade algorithm.
Feature Extraction:
The features are extracted and the feature vectors dimensionality is reduced using the LDA
algorithm.
Face Recognition:
With the help of LDA, SVM and KNN are used to classify images for face recognition
purpose.
Mark Attendance:
If a match is found in the database, then it will automatically mark the student’s attendance
in the Excel Sheet, as per lecture name and time. Else, it will display an error and
attendance will not be marked.
14
IMPLEMENTATION
SOFTWARE
4 IDE : PYCHARM
15
is a widely used general-purpose, high level programming language. It was
created by Guido van Rossum in 1991 and further developed by the Python Software
Foundation. It was designed with an emphasis on code readability, and its syntax allows
programmers to express their concepts in fewer lines of code.
Python is a programming language that lets you work quickly and integrate systems more
efficiently.
There are two major Python versions:
Python 2 and Python 3. Both are quite different.
1)Advantages :
Presence of third-party modules
Extensive support libraries(NumPy for numerical calculations, Pandas for
data analytics etc)
Open source and community development
Versatile, Easy to read, learn and write
User-friendly data structures
High-level language
Dynamically typed language(No need to mention data type based on the
value assigned, it takes data type)
Object-oriented language
Portable and Interactive
Ideal for prototypes – provide more functionality with less coding
Highly Efficient(Python’s clean object-oriented design provides enhanced
process control, and the language is equipped with excellent text processing
and integration capabilities, as well as its own unit testing framework, which
makes it more efficient.)
(IoT)Internet of Things Opportunities
Interpreted Language
Portable across Operating systems
2)Applications :
GUI based desktop applications
Graphic design, image processing applications, Games, and Scientific/
computational Applications
Web frameworks and applications
Enterprise and Business applications
Operating Systems
16
Education
Database Access
Language Development
Prototyping
Software Development
PYTHON LIBRARIES :
1) FACE RECOGNITION LIBRARY:
Recognize and manipulate faces from Python or from the command line with
the world’s simplest face recognition library.
Built using dlib’s state-of-the-art face recognition
built with deep learning. The model has an accuracy of 99.38% on the
Labeled Faces in the Wild benchmark.
This also provides a simple face_recognition command line tool that lets
you do face recognition on a folder of images from the command line!
FEATURES
a) FIND IN FACE IN PICTURE
Find all the faces that appear in a picture:
INPUT OUTPUT
17
b) Find and manipulate facial features in pictures
Get the locations and outlines of each person’s eyes, nose, mouth and
chin.
INPUT OUTPUT
2) OPENCV LIBRARY :
OpenCV is a popular Computer Vision library mostly used for real-time
applications. In this blog, we go through the 9 most frequently used OpenCV
functions to use the library efficiently along with code examples.
FEATURES
1) Color to GrayScale :
We convert the BGR images to grayscale images so that we can observe the
intensity of the pixels in the image rather than the color configurations in
the image.
18
3) Edge Cascade :
to detect edges in an image for better model learning.We using the Canny
Edge detector which is very popular
3) NUMPY LIBRARY :
19
widely used array-processing library in Python.
What is NumPy?
NumPy is a general-purpose array-processing package. It provides a high
performance multidimensional array object, and tools for working with these
arrays. It is the fundamental package for scientific computing with Python.
It contains various features including these important ones:
A powerful N-dimensional array object
Sophisticated (broadcasting) functions
Tools for integrating C/C++ and Fortran code
Useful linear algebra, Fourier transform, and random number capabilities
Besides its obvious scientific uses, NumPy can also be used as an efficient multi-
dimensional container of generic data. Arbitrary data-types can be defined using
Numpy which allows NumPy to seamlessly and speedily integrate with a wide
variety of databases.
INPUT
OUTPUT
20
FLOWCHART
21
START WINDOW
SINGLE FACE
DETECTION
MULTIPAL FACE
DETECTION
22
23
24
25
26
27