Instructions to use dima806/closed_eyes_image_detection with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use dima806/closed_eyes_image_detection with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="dima806/closed_eyes_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/closed_eyes_image_detection") model = AutoModelForImageClassification.from_pretrained("dima806/closed_eyes_image_detection") - Notebooks
- Google Colab
- Kaggle
Returns whether there is an open or a closed eye given an image from surrounding area with about 99% accuracy.
See https://www.kaggle.com/code/dima806/closed-eye-image-detection-vit for more details.
Classification report:
precision recall f1-score support
closeEye 0.9921 0.9888 0.9904 4296
openEye 0.9889 0.9921 0.9905 4295
accuracy 0.9905 8591
macro avg 0.9905 0.9905 0.9905 8591
weighted avg 0.9905 0.9905 0.9905 8591
- Downloads last month
- 561
Model tree for dima806/closed_eyes_image_detection
Base model
google/vit-base-patch16-224-in21k