sprinala commited on
Commit
b7eec1b
·
verified ·
1 Parent(s): 5467749

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -4
app.py CHANGED
@@ -18,9 +18,14 @@ def classify_image(image):
18
  confidence = np.max(predictions[0])
19
  return predicted_class, confidence
20
 
21
- image_input = gr.inputs.Image(shape=(160, 160))
22
- label = gr.outputs.Label(num_top_classes=3)
23
 
24
- gr.Interface(fn=classify_image, inputs=image_input, outputs=label,
25
- title='Pokémon Classifier',
 
 
 
26
  description='Upload an image of Jolteon, Kakuna, Mr. Mime and the classifier will tell you which one it is and the confidence level of the prediction.').launch()
 
 
 
18
  confidence = np.max(predictions[0])
19
  return predicted_class, confidence
20
 
21
+ image_input = gr.Image(shape=(160, 160))
22
+ label = gr.Label(num_top_classes=3)
23
 
24
+ iface = gr.Interface(
25
+ fn=classify_image,
26
+ inputs=image_input,
27
+ outputs=label,
28
+ title='Pokémon Classifier',
29
  description='Upload an image of Jolteon, Kakuna, Mr. Mime and the classifier will tell you which one it is and the confidence level of the prediction.').launch()
30
+
31
+ iface.launch()