metadata
license: apache-2.0
datasets:
- food101
tags:
- openvino
- int8
Vision Transformer (ViT) quantized and exported to the OpenVINO IR.
Model Details
Model Description: This ViT model fine-tuned on Food-101 was statically quantized and exported to the OpenVINO IR using optimum.
Usage example
You can use this model with Transformers pipeline.
from transformers import pipeline, AutoFeatureExtractor
from optimum.intel.openvino import OVModelForImageClassification
model_id = "echarlaix/vit-food101-int8"
model = OVModelForImageClassification.from_pretrained(model_id)
feature_extractor = AutoFeatureExtractor.from_pretrained(model_id)
pipe = pipeline("image-classification", model=model, feature_extractor=feature_extractor)
outputs = pipe("http://farm2.staticflickr.com/1375/1394861946_171ea43524_z.jpg")