Lucas Lima commited on
Commit
b37836e
·
1 Parent(s): 1fb0bc7

fix gradio components

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -9,8 +9,8 @@ def classify_image(img):
9
  pred,idx,probs = learn.predict(img)
10
  return dict(zip(categories, map(float, probs)))
11
 
12
- image = gr.components.Image(shape=(192,192))
13
- label = gr.components.Label()
14
 
15
  iface = gr.Interface(fn=classify_image, inputs=image, outputs=label)
16
  iface.launch(inline=False)
 
9
  pred,idx,probs = learn.predict(img)
10
  return dict(zip(categories, map(float, probs)))
11
 
12
+ image = gr.Image() # No need for the shape argument
13
+ label = gr.Label()
14
 
15
  iface = gr.Interface(fn=classify_image, inputs=image, outputs=label)
16
  iface.launch(inline=False)