tonyassi's picture
Update app.py
4273fa3
raw
history blame
276 Bytes
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()