Instructions to use dima806/face_emotions_image_detection with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use dima806/face_emotions_image_detection with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="dima806/face_emotions_image_detection") pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")# Load model directly from transformers import AutoImageProcessor, AutoModelForImageClassification processor = AutoImageProcessor.from_pretrained("dima806/face_emotions_image_detection") model = AutoModelForImageClassification.from_pretrained("dima806/face_emotions_image_detection") - Notebooks
- Google Colab
- Kaggle
Predicts face emotion based on facial image.
See https://www.kaggle.com/code/dima806/face-emotions-image-detection-vit for more details.
Classification report:
precision recall f1-score support
Ahegao 0.9738 0.9919 0.9828 1611
Angry 0.8439 0.6580 0.7394 1611
Happy 0.8939 0.9261 0.9098 1611
Neutral 0.6056 0.7635 0.6755 1611
Sad 0.6661 0.5140 0.5802 1611
Surprise 0.7704 0.8733 0.8186 1610
accuracy 0.7878 9665
macro avg 0.7923 0.7878 0.7844 9665
weighted avg 0.7923 0.7878 0.7844 9665
- Downloads last month
- 83
Model tree for dima806/face_emotions_image_detection
Base model
google/vit-base-patch16-224-in21k