File size: 382 Bytes
d836bbd
 
 
 
02b9180
d836bbd
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import gradio as gr
from transformers import pipeline

# Initialize hotdog-not-hotdog pipeline
pipeline = pipeline(task="image-classification", model="julien-c/hotdog-not-hotdog")

def predict(image):
  return pipeline(image)

gr.Interface(
    predict,
    inputs=gradio.inputs.Image(label="Upload hot dog candidate"),
    outputs="image",
    title="Hot Dog? Or Not?",
).launch()