Coder Social home page Coder Social logo

weblineindia / aiml-human-attributes-detection-with-facial-feature-extraction Goto Github PK

View Code? Open in Web Editor NEW
106.0 4.0 23.0 224.55 MB

This is a Human Attributes Detection program with facial features extraction. It detects facial coordinates using FaceNet model and uses MXNet facial attribute extraction model for extracting 40 types of facial attributes. This solution also detects Emotion, Age and Gender along with facial attributes.

Home Page: https://www.weblineindia.com/software-development-resources.html

License: MIT License

Python 97.26% Shell 2.74%
mxnet mxnet-imageclassification facial-recognition facial-expression-recognition face-recognition age-recognition gender-classification gender-recognition emotion-detection emotion-recognition

aiml-human-attributes-detection-with-facial-feature-extraction's Introduction

AI ML - Human Attributes Detection with Facial Feature Extraction

Age, Emotion, Gender recognition with Facial feature extraction

This facial attribute extraction program detects facial coordinates using FaceNet model and uses MXNet facial attribute extraction model for extracting 40 types of facial attributes. This solution detects Emotion, Age and Gender along with facial attributes.

Deep Learning Models used for the library are,

  • FaceNet model used for facial landmark recognition.
  • A trained lightened moon Mxnet model used for facial attribute extraction.
  • AgeNet pre-trained caffe model used for Age detection.
  • GenderNet caffe model used for Gender detection.

Table of contents

Getting started

Prerequisites for running the code are:

  • Python == 3.6
  • python-opencv == 4.2.0
  • numpy == 1.18.5
  • pandas == 0.24.2
  • Keras == 2.2.4
  • mxnet == 1.6.0
  • python-dotenv == 0.14.0
  • imageio == 2.4.1

We have tested our program in above version, however you can use it in other versions as well.

Update path in .env file

Replace "your/path/to/folder/" in .env file with path of your system.

My username is abc, replace that with your system username.

Eg: FACEDETECTOR = "/home/abc/AIML-Human-Attributes-Detection-with-Facial-Feature-Extraction/model/facenet/opencv_face_detector.pbtxt"

Features

  • Face detection using FaceNet model
  • Detects facial attribute of a face in an image.
  • Detects Emotions on the face.
  • Predicts Gender of the detected face.
  • Predicts Age of the detected face.

Facial Attribute Classes

["5_o_Clock_Shadow","Arched_Eyebrows","Attractive","Bags_Under_Eyes","Bald", "Bangs","Big_Lips","Big_Nose",
"Black_Hair","Blond_Hair","Blurry","Brown_Hair","Bushy_Eyebrows","Chubby","Double_Chin","Eyeglasses","Goatee",
"Gray_Hair", "Heavy_Makeup","High_Cheekbones","Male","Mouth_Slightly_Open","Mustache","Narrow_Eyes","No_Beard",
"Oval_Face","Pale_Skin","Pointy_Nose","Receding_Hairline","Rosy_Cheeks","Sideburns","Smiling","Straight_Hair",
"Wavy_Hair","Wearing_Earrings","Wearing_Hat","Wearing_Lipstick","Wearing_Necklace","Wearing_Necktie","Young"] 

Emotion Detection Classes

  • Happy
  • Neutral
  • Surprise
  • Angry
  • Fear
  • Sad
  • Disgust

Gender Detection Classes

  • Male
  • Female

Age Detection Classes

['(0-2)', '(4-6)', '(8-12)', '(15-20)', '(25-32)', '(38-43)', '(48-53)', '(60-100)']

Usage

Inside the project's directory run:

python predict.py

You can find sample images in the Dataset folder and results can be seen on the terminal. Results directory contains images with detected faces.

Results

Original Image

Detection Results

Want to Contribute?

  • Created something awesome, made this code better, added some functionality, or whatever (this is the hardest part).
  • Fork it.
  • Create new branch to contribute your changes.
  • Commit all your changes to your branch.
  • Submit a pull request.

Need Help?

We also provide a free, basic support for all users who want to use image processing techniques for their projects. In case you want to customize this image enhancement technique for your development needs, then feel free to contact our AI/ML developers.


Collection of Components

We have built many other components and free resources for software development in various programming languages. Kindly click here to view our Free Resources for Software Development.


Changelog

Detailed changes for each release are documented in CHANGELOG.md.

Credits

  • Refered mxnet-face for attribute extraction. mxnet-face.
  • Refered fer2013/IMDB for emotional classification. fer2013/IMDB.
  • Refered AgeGender recognition. AgeGender.

License

MIT

Keywords

Mxnet_face, facial_attribute_extraction, Age_recognition, gender_recognition, emotion_recognition, caffemodel, fer2013

aiml-human-attributes-detection-with-facial-feature-extraction's People

Contributors

partners-wli avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

aiml-human-attributes-detection-with-facial-feature-extraction's Issues

Update readme

Readme currently doesn't say that imageio is needed, and which version

"Attractive" should not be an attribute

Hello,

I just wanted to flag that while having high cheekbones or stubble could be seen as objective facial attributes, this is definitely not the case for being attractive or not.

This is a subjective attribute which shouldn't really be included as an attribute characteristic.

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.