File size: 369 Bytes
c9b3fda
 
842b256
c9b3fda
842b256
c9b3fda
1
2
3
4
5
6
import gradio as gr
from transformers import pipeline

pipe = pipeline(task="image-classification", model="microsoft/beit-base-patch16-224-pt22k-ft22k")

gr.Interface.from_pipeline(pipe, title="22k Image Classification", description="Object Recognition using Microsoft BEIT", examples = ['wonder_cat.jpg', 'aki_dog.jpg',], allow_flagging="never").launch(inbrowser=True)