Mini Project

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

21CSS101J – PROGRAMMING FOR PROBLEM SOLVING

Mini Project Report


On face detection

Submitted by

AADHITH S [RA2211003011933]
B.Tech. CSE - CORE

ABISHEK P [RA2211003012013]
B.Tech. CSE - CORE

SCHOOL OF COMPUTING
COLLEGE OF ENGINEERING AND TECHNOLOGY
SRM INSTITUTE OF SCIENCE AND TECHNOLOGY
(Under Section 3 of UGC Act, 1956)
S.R.M. NAGAR, KATTANKULATHUR – 603 203
KANCHEEPURAM DISTRICT
December 2022

1
TABLE OF CONTENTS

ChapterNo.
Title Page No.

1 Problem Definition 3

2 Methodology / Procedure
3

3 Coding (Python) 5

4 Results 7

5 Conclusion 9

2
PROBLEM DEFINITION

The project consists of a face recognition system in which an input image is

given in which the number of faces is more than one and using the

algorithm and classifier we use to detect the faces and accordingly it crops it

into a certain ratio in two dimension that is length and breath. After all this it

saves the separate images in jpeg form which tells the no of count of faces

which was the required target of our project.

METHODOLOGY / PROCEDURE

We are taking the raw image as an input in which the number of faces is

more than one and then we save the real image and its path too and after

that we are importing cv2 classifier and defining the four dimensional

variables for length breath height and width then after we are detecting the

faces using cascade class and cropping that image in the scale ratio of 1:3

and saving it separately into jpeg format. Hence, we can use this for an

extended machine learning application also in future.

3
ALGORITHM IMPLEMENTATION

 By importing cv2 library in the beginning of the code.

 Then by creating a constructor named self in second step

 We will go to the main function where we will create a class called

crop which will be called later.

 Then by saving the original image and its location path

 We will define the four types of variables for the various dimensions

of the given input image

 Then by calling the classifier we will crop the image in the ratio of 1:3 in length
and height.

 After that we will save them separately in jpeg format.











4


codi
ng

5
6
SCREENSHOTS

Original image

7
NUMBER OF FACES : 3

8
PROS AND CONS:

The best part of this idea is it can be implemented in many potential

machine learning concepts which is very useful in our future There

are lots of applications of face recognition. Face recognition is

already being used to unlock phones and specific applications. Face

recognition is also used for biometric surveillance. Banks, retail

stores, stadiums, airports and other facilities use facial recognition to

reduce crime and prevent violence.

And the cons part is, this isn’t that much accurate and efficient as

per our future complex requirements.

CONCLUSION:
The best part of this project is that the code is really simple and

understandable which is written in python language. As we have not

usede any complex classifiers this is the simplest way for face

detection which we could extend it to the concept of machine

learning in future.

You might also like