import gradio as gr | |
from transformers import pipeline | |
pipe = pipeline(task="image-classification", | |
# model that can do 22k-category classification | |
model="huggingface/google/vit-base-patch16-224-in21k") | |
gr.Interface.load(pipe, | |
theme="default", | |
examples=[["alligator.jpg"], ["laptop.jpg"]], | |
css=".footer{display:none !important}", | |
title=None).launch() |