Fer
Facial Expression Recognition
Install / Use
/learn @mayurmadnani/FerREADME
FER - Facial Expression Recognition
This work is to demonstrate the below problem: https://www.kaggle.com/c/challenges-in-representation-learning-facial-expression-recognition-challenge
A real time face detector and emotion classifier is built using Convolution Neural Network and OpenCV. The CNN model is tuned for fine performance even on a low end device.
Instructions
Follow the guided tutorial for neural network training.
Files Structure:
- FER_CNN.ipynb - Tutorial to train the CNN
- FER.py - Uses the pre-trained model to give inferences
- model.json - Neural network architecture
- weights.h5 - Trained model weights
Installation
Using Python virtual environment will be advisable.
-
For model prediction
pip install -r requirements.txtOR
pip install opencv-pythonpip install tensorflow(Note here we are installing tensorflow-cpu)pip install keras -
For model training,
pandasnumpytensorflowkerasmatplotlibscikit-learnseaborn -
Running the inference engine
Use the webcam
python FER.py webcam <fps>
Use a video file
python FER.py <video_file_name> <fps>
Contributing
- Report issues on issue tracker
- Fork this repo
- Make awesome changes
- Raise a pull request
Copyright & License
Copyright (C) 2018 Mayur Madnani
Licensed under MIT License
See the LICENSE.
Related Skills
node-connect
347.0kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
claude-opus-4-5-migration
107.8kMigrate prompts and code from Claude Sonnet 4.0, Sonnet 4.5, or Opus 4.1 to Opus 4.5
frontend-design
107.8kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
model-usage
347.0kUse CodexBar CLI local cost usage to summarize per-model usage for Codex or Claude, including the current (most recent) model or a full model breakdown. Trigger when asked for model-level usage/cost data from codexbar, or when you need a scriptable per-model summary from codexbar cost JSON.
