Spaces:
Sleeping
Sleeping
File size: 276 Bytes
183ba69 4273fa3 183ba69 4273fa3 183ba69 4a35a20 183ba69 |
1 2 3 4 5 6 7 8 9 10 |
import gradio as gr
from transformers import pipeline
caption = pipeline("image-to-text", model="Salesforce/blip-image-captioning-large")
def greet(img):
return caption(img)
iface = gr.Interface(fn=greet, inputs=gr.Image(type='filepath'), outputs="text")
iface.launch() |