ooferdoodles commited on
Commit
2558bf4
1 Parent(s): 381510a
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -10,8 +10,7 @@ import gradio as gr
10
 
11
  learn = load_learner(Path("model.pkl"))
12
 
13
- categories = {'Pizza', 'Pasta'}
14
-
15
 
16
  def classify_image(img):
17
  pred, idx, probs = learn.predict(img)
@@ -22,8 +21,8 @@ image = gr.Image(shape=(192, 192))
22
  label = gr.Label()
23
  examples = ['pizza.jpg', 'pasta.jpg', 'dunno.jpg']
24
 
25
- app = gr.Interface(fn=classify_image,
26
  inputs=image,
27
- outputs=label,
28
  examples=examples)
29
  app.launch()
 
10
 
11
  learn = load_learner(Path("model.pkl"))
12
 
13
+ categories = {'Pasta', 'Pizza'}
 
14
 
15
  def classify_image(img):
16
  pred, idx, probs = learn.predict(img)
 
21
  label = gr.Label()
22
  examples = ['pizza.jpg', 'pasta.jpg', 'dunno.jpg']
23
 
24
+ app = gr.Interface(fn=classify_image,
25
  inputs=image,
26
+ outputs=label,
27
  examples=examples)
28
  app.launch()