How to use from the
Use from the
Transformers library
# Use a pipeline as a high-level helper
# Warning: Pipeline type "image-to-text" is no longer supported in transformers v5.
# You must load the model directly (see below) or downgrade to v4.x with:
# 'pip install "transformers<5.0.0'
from transformers import pipeline

pipe = pipeline("image-to-text", model="tarekziade/deit-tiny-distilgpt2")
# Load model directly
from transformers import AutoTokenizer, AutoModelForMultimodalLM

tokenizer = AutoTokenizer.from_pretrained("tarekziade/deit-tiny-distilgpt2")
model = AutoModelForMultimodalLM.from_pretrained("tarekziade/deit-tiny-distilgpt2", device_map="auto")
Quick Links

Variation of https://huggingface.co/tarekziade/distilvit

Trained on 270k images from Flickr10k and COCO. Training source code: https://github.com/tarekziade/distilvit

Results:

  • eval_loss: 0.2305169701576233
  • eval_rouge1: 39.511
  • eval_rouge2: 14.7798
  • eval_rougeL: 35.9476
  • eval_rougeLsum: 35.9497
  • eval_gen_len: 11.695219762592236
Downloads last month
8
Safetensors
Model size
0.1B params
Tensor type
F32
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for tarekziade/deit-tiny-distilgpt2

Quantized
(24)
this model