All Projects → donydchen → FMPN-FER

donydchen / FMPN-FER

Licence: MIT License
Official PyTorch Implementation of 'Facial Motion Prior Networks for Facial Expression Recognition', VCIP 2019, Oral

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to FMPN-FER

facial-expression-recognition
The main purpose of the project - recognition of emotions based on facial expressions. Cohn-Kanade data set (http://www.pitt.edu/~emotion/ck-spread.htm) is used for explorations and training
Stars: ✭ 60 (-21.05%)
Mutual labels:  facial-expression-recognition
ToolGood.Algorithm
Support four arithmetic operations, Excel formulas, and support custom parameters. 支持四则运算、Excel公式语法,并支持自定义参数。
Stars: ✭ 77 (+1.32%)
Mutual labels:  expression
eval-estree-expression
Safely evaluate JavaScript (estree) expressions, sync and async.
Stars: ✭ 22 (-71.05%)
Mutual labels:  expression
evaluator
No description or website provided.
Stars: ✭ 35 (-53.95%)
Mutual labels:  expression
color-math
Expressions to manipulate colors.
Stars: ✭ 18 (-76.32%)
Mutual labels:  expression
AIML-Human-Attributes-Detection-with-Facial-Feature-Extraction
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.
Stars: ✭ 48 (-36.84%)
Mutual labels:  facial-expression-recognition
Action-Units-Heatmaps
Code for BMVC paper "Joint Action Unit localisation and intensity estimation through heatmap regression"
Stars: ✭ 80 (+5.26%)
Mutual labels:  facial-expression-recognition
CoNekT
CoNekT (short for Co-expression Network Toolkit) is a platform to browse co-expression data and enable cross-species comparisons.
Stars: ✭ 17 (-77.63%)
Mutual labels:  expression
texpr
Boolean evaluation and digital calculation expression engine for GO
Stars: ✭ 18 (-76.32%)
Mutual labels:  expression
SqlBatis
A high performance Micro-ORM supporting SQL Server, MySQL, Sqlite etc..
Stars: ✭ 34 (-55.26%)
Mutual labels:  expression
fer
Facial Expression Recognition
Stars: ✭ 32 (-57.89%)
Mutual labels:  facial-expression-recognition
Emotion-Investigator
An Exciting Deep Learning-based Flask web app that predicts the Facial Expressions of users and also does Graphical Visualization of the Expressions.
Stars: ✭ 44 (-42.11%)
Mutual labels:  facial-expression-recognition
mpsl
Shader-Like Mathematical Expression JIT Engine for C++ Language
Stars: ✭ 52 (-31.58%)
Mutual labels:  expression
url-regex-safe
Regular expression matching for URL's. Maintained, safe, and browser-friendly version of url-regex. Resolves CVE-2020-7661 for Node.js servers.
Stars: ✭ 59 (-22.37%)
Mutual labels:  expression
quickExp
a script for controlling expressions quickly in After Effects
Stars: ✭ 24 (-68.42%)
Mutual labels:  expression
MA-Net
“Learning Deep Global Multi-scale and Local Attention Features for Facial Expression Recognition in the Wild”, IEEE T-IP, 2021.
Stars: ✭ 53 (-30.26%)
Mutual labels:  facial-expression-recognition
SQLBuilder.Core
.NET Standard 2.1、.NET 5、.NET 6 版本SQLBuilder,Expression表达式转换为SQL语句,支持SqlServer、MySql、Oracle、Sqlite、PostgreSql;基于Dapper实现了不同数据库对应的数据仓储Repository;
Stars: ✭ 85 (+11.84%)
Mutual labels:  expression
formulize
🌘 formula ui generator
Stars: ✭ 82 (+7.89%)
Mutual labels:  expression
karnaugh-map-simplifier
Karnaugh map simplification software, used to visually simplify boolean expressions
Stars: ✭ 33 (-56.58%)
Mutual labels:  expression
rclc
Mathematical expression calculator with big integers, floats, common fractions, and complex numbers support
Stars: ✭ 24 (-68.42%)
Mutual labels:  expression

FMPN-FER

Status Platform PyTorch License

PWC

PWC

Official PyTorch Implementation of Facial Motion Prior Networks for Facial Expression Recognition by Yuedong Chen, Jianfeng Wang, Shikai Chen, Zhongchao Shi, and Jianfei Cai.
VCIP 2019, Oral, [arXiv]

FMPN Model Structure

Setup

Prerequisites

  • python >= 3.6
  • pytorch >= 0.4.1
  • visdom == 0.1.8.9

Training

The training phase mainly contains two stages, including training the generator for generating facial motion mask, and jointly training the whole recognition network. Running scripts examples are given as below.

Pretrain the Facial-Motion Mask Generator (FMG)

python main.py --mode train --data_root datasets/CKPlus --train_csv train_ids_0.csv \
    --print_losses_freq 4 --use_data_augment --visdom_env res_baseline_ckp_0 \
    --niter 150 --niter_decay 150 --gpu_ids 0 \
    --model res_baseline --solver resface --img_nc 1 \
    /

Jointly Train the Facial-Motion Prior Network

Load the saved weight for the FMG pertained in the previous stage, and ImageNet pretrained weight for the Classifer Net.

python main.py --mode train --data_root datasets/CKPlus --train_csv train_ids_0.csv \
    --print_losses_freq 4 --use_data_augment --visdom_env res_cls_ckp_0 --niter 100 \
    --niter_decay 100 --gpu_ids 0 --model res_cls --solver res_cls --lambda_resface 0.1 \
    --batch_size 16 --backend_pretrain \
    --load_model_dir ckpts/CKPlus/res_baseline/fold_0/190117_165651 --load_epoch 300 \
    /

Testing

python main.py --mode test --data_root datasets/CKPlus --test_csv test_ids_0.csv \
    --gpu_ids 0 --model res_cls --solver res_cls --batch_size 4 \
    --load_model_dir ckpts/CKPlus/res_cls/fold_0/190118_170050 --load_epoch 200 \
    /

Datasets

  • The pseudo ground truth facial motion masks for dataset CK+, MMI and AffectNet are presented in /datasets.
  • Training and Testing datasets splits are located in /datasets, 10-fold cross validation is used in the project as a general approach.

Results Detail

10 folds accuracy for CK+, MMI and AffectNet.

Fold ID 0 1 2 3 4 5 6 7 8 9 Avg
CK+ 0.885 1.000 0.921 1.000 1.000 1.000 1.000 1.000 1.000 1.000 0.98
MMI 0.778 0.731 0.667 0.744 0.857 0.855 0.958 0.889 1.000 0.795 0.83
AffectNet - - - - - - - - - - 0.62

Citation

If you use this code for your research, please cite our paper Facial Motion Prior Networks for Facial Expression Recognition:

@article{chen2019facial,
  title={Facial Motion Prior Networks for Facial Expression Recognition},
  author={Chen, Yuedong, Jianfeng Wang, Shikai Chen, Zhongchao Shi, and Jianfei Cai},
  journal={IEEE Visual Communications and Image Processing (VCIP)},
  year={2019},
  organization={IEEE}
}

Acknowledgments

This work is mainly conducted when Yuedong is a research intern in Lenovo AI Lab, Beijing. For any questions regarding this project, feel free to create an issue or reach Yuedong by Email.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].