You are on page 1of 10

SYNOPSIS

ON
FACE-LOCK ALGORITHM

Submitted By:
ASHA
(20010041009)

In partial fulfilment for the award of the degree


Of

BACHELOR OF COMPUTER APPLICATIONS


In
COMPUTER SCIENCE AND ENGINEERING

GATEWAY INSTITUTE OF ENGINEERING & TECHNOLOGY,


SECTOR-11, SONEPAT (Affiliated to DCRUST, MURTHAL)

June, 2023
Introduction
The objective of the project is to provide user an algorithm which will detects the face
of the user and unlock the applications or website’s according to that.
It will first take the training data as an input from the camera of the device and then
will train the model from the input and will detect the face according to that training
of the model.
To work on the project, we will use Facial Recognition Technique in the project.

In order to understand how Face Recognition works, let us first get an idea of the
concept of a feature vector.

Every Machine Learning algorithm takes a dataset as input and learns from this data.
The algorithm goes through the data and identifies patterns in the data.

For instance, suppose we wish to identify whose face is present in a given image, there
are multiple things we can look at as a pattern:

1. Height/width of the face.


2. Height and width may not be reliable since the image could be rescaled to a
smaller face.
3. However, even after rescaling, what remains unchanged are the ratios – the ratio
of height of the face to the width of the face won’t change.
4. Colour of the face.

Width of other parts of the face like lips, nose, etc. Clearly, there is a pattern here – different
faces have different dimensions like the ones above. Similar faces have similar dimensions.
The challenging part is to convert a particular face into numbers – Machine Learning
algorithms only understand numbers. This numerical representation of a “face” (or an
element in the training set) is termed as a feature vector. A feature vector comprises of
various numbers in a specific order.

As a simple example, we can map a “face” into a feature vector which can comprise various
features like:

1. Height of face (cm)


2. Width of face (cm)
3. Average color of face (R, G, B)
4. Width of lips (cm)
5. Height of nose (cm)

Page 2 of 10
Essentially, given an image, we can map out various features and convert it into a
feature vector like:

Height of face Width of face Average color of Width of lips Height of nose
(cm) (cm) face (RGB) (cm) (cm)
23.1 15.8 (255, 224, 189) 5.2 4.4

So, our image is now a vector that could be represented as (23.1, 15.8, 255, 224,
189, 5.2, 4.4). Ofcourse there could be countless other features that could be
derived from the image (for instance, hair color, facial hair, spectacles, etc).
However, for the example, let us consider just these 5 simple features.

Now, once we have encoded each image into a feature vector, the problem
becomes much simpler. Clearly, when we have 2 faces (images) that represent the
same person, the feature vectors derived will be quite similar. Put it the other way,
the “distance” between the 2 feature vectors will be quite small.

Machine Learning can help us here with 2 things:

1. Deriving the feature vector: it is difficult to manually list down all of the
features because there are just so many. A Machine Learning algorithm can
intelligently label out many of such features. For instance, a complex features
could be: ratio of height of nose and width of forehead. Now it will be quite
difficult for a human to list down all such “second order” features.
2. Matching algorithms: Once the feature vectors have been obtained, a
Machine Learning algorithm needs to match a new image with the set
of feature vectors present in the corpus.

We will use OPENCV library in this project to detect the face of the person and
to scan it. The name OpenCV has become synonymous with computer vision, but
what is OpenCV?
OpenCV is a collection of software algorithms put together in a library to be used by
industry and academia for computer vision applications and research. OpenCV
started at Intel in the mid 1990s as a method to demonstrate how to accelerate certain
algorithms in hardware.

In 2000, Intel released OpenCV to the open source community as a beta version,
followed by v1.0 in 2006. In 2008, Willow Garage took over support for OpenCV
and immediately released v1.1.

Page 3 of 10
Willow Garage dates from 2006. The company has been in the news a lot lately,
subsequent to the unveiling of its PR2 robot . Gary Bradski began working on
OpenCV when he was at Intel; as a senior scientist at Willow Garage he
aggressively continues his work on the library.

OpenCV v2.0, released in 2009, contained many improvements and upgrades.


Initially, OpenCV was primarily a C library. The majority of algorithms were written
in C, and the primary method of using the library was via a C API. OpenCV v2.0
migrated towards C++ and a C++ API. Subsequent versions of OpenCV added Python
support, along with Windows, Linux, iOS and Android OS support, transforming
OpenCV (currently at v2.3) into a cross-platform tool.
OpenCV v2.3 contains more than 2500 algorithms; the original OpenCV only had
500. And to assure quality, many of the algorithms provide their own unit tests.

Page 4 of 10
Objective:
- The objective of the project is to provide user an algorithm which will detect the face
of the user and unlock the applications or websites according to that.
- To develop an algorithm which provides access when face is scanned and matched.
- It will first take the training data as an input from the camera of the device and then
will train the model from the input and will detect the face according to that training
of the model.
- To learn about working of face lock/unlock systems.
- To learn that how face algo works in devices for security.

Page 5 of 10
Applications:
- Face Recognition Door Lock System
- Unlock Smart Phones
- Finding Missing Person
- Protect School from Threats
- Tracking Attendance in School
- Validate Identities at ATMs
- Control Access to Sensitive Areas
- Unlocking Laptops
- Completing Transactions

Industries which uses face unlock algos:


1. Law Enforcement

As the government adds a layer of artificial intelligence to its surveillance, startups are
playing a key role in providing it with the underlying facial recognition technology. Chinese
unicorns like SenseTime, Face++, and CloudWalk, for example, are already working with the
Chinese government here.

2. Healthcare

In its most straightforward application, facial recognition has the potential to make it easier
for patients to sign in at the doctor or hospital without waiting in line or juggling forms. But
there are a number of other ways that the technology can be used to improve services.

Algorithms can track color changes in two areas of the face, like regions near the eyes and
cheek, using that data to calculate heart rate detection. Tracking these changes could better
position hospital staff to more effectively monitor and treat patients.

3. Retail

Linking facial recognition to personalization for shoppers presents a big opportunity in retail.

Facial recognition, for example, could capture what a shopper is looking at, and enable
retailers to later serve up related promotions to the shopper via email or online ads. In another
example, Walmart has a patent on tech that would capture and analyze facial expressions of
people waiting in lines to gauge their satisfaction.

Page 6 of 10
In China, users scan a QR code while entering JD stores. A camera runs facial recognition
algorithms to identify the shopper during entry. Every item in JD’s physical store carries an
RFID tag. While exiting, customers stand at a “stand here” sign marked on the floor, where
all the RFID tags are scanned at once, and cameras run facial recognition algorithms again to
charge your account.

4. Hospitality
Facial recognition is linked to better customer service in the hospitality industry. Tying the
technology to a guest’s account allows employees to offer them a better, more personalized
experience.

Starting with a photo on one’s account, for example, this technology could allow a guest to
simply walk into a hotel to activate her check-in. The person could use her image to enter her
room as well.

This could potentially free up the concierge staff to better serve their guests with suggestions,
perks, and services tailored to them.

5. Banking

Banks are beginning to use facial recognition as secure login tools for customers using their
online banking sites and apps. HSBC and Singapore’s OCBC have both added facial
biometrics as options for logging into mobile banking accounts. The technology is said to
offer “less than a one-in-a-million chance of mistaken identity,” potentially making online
banking more secure.

The tech isn’t limited to protecting online data but also to provide bank customers with an
extra layer of security. Face scanning helps to prevent fraud by eliminating the need for a PIN
or even a card swipe, both of which are susceptible to being stolen.

As the technology develops and becomes more accessible, it could also make brick-and-
mortar banking more secure and personalized. Tellers would know customers’ names and
account information, offering a better and less clunky customer experience.

6. Events

Stadiums, arenas, concert halls, and other venues to be equipped with facial recognition
cameras or kiosks, and would still require some crowd control, including ways to remove
those who aren’t authorized to be there.

Page 7 of 10
7. Social Media/Entertainment

Fighting boredom is yet another use case for facial recognition. Apps like CelebsLike.Me,
which uses a person’s photo to find celebrities that look like them, and Google’s Art Selfie,
which analyzes a selfie to find art pieces that match facial structures, are making the rounds
on social networks.

Snapchat was a pioneer of facial recognition as a personal entertainment tool. Filters and


Lenses take a scan of the subject’s face, then apply things like makeup or rabbit ears. These
tools also know when the user’s mouth opens, for example, and can animate dog tongues or
rainbows.

Snapchat also gave rise to Bitmoji (which doesn’t yet use facial recognition, but could in the
future), which inspired Apple’s Animoji and Memoji. Within iMessage, users can create 3D
emojis or animations of themselves that mirror their facial expressions, thanks to the iPhone’s
Face ID technology.

8. Air Travel

Similar to the advances possible in hotel hospitality and entertainment, travel could see big
changes by implementing facial recognition technology. TSA lines could be expedited for
everyone and VIP passengers could have an even more tailored experience.

JetBlue is testing facial recognition instead of boarding passes to streamline the process.
Kiosks use passport or ID photos from the US customs database to verify passengers and let
them aboard. Last year, Delta also tested face-scanning kiosks to help passengers check their
own luggage.

Biometric technology in airports is also a win for security. Last fall, facial recognition
stopped a man trying to use a fake passport to enter the US. Customs officials say that these
cameras have a 99% accuracy rate, as they compare photos of people’s faces on file from
official government documents.

9. Automobiles

While self-driving cars are the focus of the facial recognition research in the auto industry
currently, there is still potential for other use cases. Face scanning could unlock the car when
the owner approaches or function as the key to starting and stopping the car (much like
button-start cars function now).

Cars that are have programmable settings for different drivers could make these even simpler
with face recognition. Seat distance, car temperature, preferred radio stations could switch
instantly when one driver’s face is scanned versus another.

Page 8 of 10
SOFTWARE USED

Python :-
We have used python latest version “ 3.11.2” in the project.

OpenCV :-
OpenCV (OPEN SOUCE COMPUTER VISION) is an open-source BSD-licensed
library that includes several hundreds of computer vision algorithms. We will use
many methods of opencv in this project.

Anaconda :-
Anaconda Enterprise is an enterprise-ready, secure, and scalable data science platform
that empowers teams to govern data science assets, collaborate, and deploy data
science projects.

HARDWARE USED
- A windows system with webcam in it.

Page 9 of 10
The minimum software requirements for a “Face-Algo Project” are described below:

1 Operating System Windows 10 or higher/Linux/Mac

2 Software Anaconda Navigator

3 Software Version 1.7.x or above

4 Environment Spyder

5 Environment Version 4.9.x or above

6 Language Python

7 Module OpenCV

8 Front-end Anaconda

9 Back-end OpenCV

Table: Software Requirements

Page 10 of 10

You might also like