Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Emotion detection using openCV

License

NotificationsYou must be signed in to change notification settings

saranshbht/Emotion-detection

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

This project aims to classify the emotion on a person's face into one ofseven categories, using deep convolutional neural networks. This repository is an implementation ofthis research paper. The model is trained on theFER-2013 dataset which was published on International Conference on Machine Learning (ICML). This dataset consists of 35887 grayscale, 48x48 sized face images withseven emotions - angry, disgusted, fearful, happy, neutral, sad and surprised.

Dependencies

  • Python 3,OpenCV,Tensorflow
  • To install the required packages, runpip install -r requirements.txt.

Usage

The repository is currently compatible withtensorflow-2.0 and makes use of the Keras API using thetensorflow.keras library.

  • Clone the repository
git clone https://github.com/saranshbht/Emotion-detection.git
  • This implementation by default detects emotions on all faces in the webcam feed. With a simple 4-layer CNN, the test accuracy reached 63.2% in 50 epochs.

Accuracy plot

Algorithm

  • First, thehaar cascade method is used to detect faces in each frame of the webcam feed.

  • The region of image containing the face is resized to48x48 and is passed as input to the CNN.

  • The network outputs a list ofsoftmax scores for the seven classes of emotions.

  • The emotion with maximum score is displayed on the screen.

References

  • "Challenges in Representation Learning: A report on three machine learning contests." I Goodfellow, D Erhan, PL Carrier, A Courville, M Mirza, BHamner, W Cukierski, Y Tang, DH Lee, Y Zhou, C Ramaiah, F Feng, R Li,
    X Wang, D Athanasakis, J Shawe-Taylor, M Milakov, J Park, R Ionescu,M Popescu, C Grozea, J Bergstra, J Xie, L Romaszko, B Xu, Z Chuang, andY. Bengio. arXiv 2013.

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp