Giter Club home page Giter Club logo

face-detection-recognition's Introduction

Face-Detection-Recognition

File 1 : faceDetection.py - face detection on loaded image

How to run : open file and run on IDE that supports python

How to quit : press 'q' on pop-up frame to close window and exit program

How it works :

  1. Loads specified image into the program
  2. Converts image to grayscale
  3. Uses haar cascades algorithm to detect faces
  4. Window will open with frame around the face detected

The script uses openCV and the haarcascade algorithm

Issues you might encounter :

  • Make sure the image file is in the same directory as the faceDetection.py script
  • If the image file is corrupted or not in the correct format, the program will be unable to read it
  • Even if the file extension is valid, the image itself might not be. You might need to convert it again (try : image.online-convert.com)

image 1

File 2 : faceRecognition.py - real time face recognition

How to run : open file and run on IDE that supports python

How to quit : press 'q' on live webcam window to close window and exit program

How it works :

  1. Loads images from a specified directory
  2. Encodes images from step 1
  3. Opens webcam and encodes the current live feed
  4. Checks if there is a match between the encoded images and the live frames encoded

The script uses openCV and the face_recognition api

Issues you might encounter :

  • Make sure the images loaded to train the program are in the correct folder specified by the script. In this script, the image path is set to a folder named 'faces', in the same directory where the 'faceRecognition.py' script resides
  • Do not remove code lines that remove '.DS_Store' from image path. See the following post on stackoverflow for reference

image 1

face-detection-recognition's People

Contributors

cristopher-cruz avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.