zhaluza commited on
Commit
4b53691
1 Parent(s): f206673

launch gradio interface

Browse files
Files changed (1) hide show
  1. app.py +7 -0
app.py CHANGED
@@ -18,3 +18,10 @@ def classify(im):
18
  probs = probability[0].detach().numpy()
19
  confidences = {label: float(probs[i]) for i, label in enumerate(labels)}
20
  return confidences
 
 
 
 
 
 
 
 
18
  probs = probability[0].detach().numpy()
19
  confidences = {label: float(probs[i]) for i, label in enumerate(labels)}
20
  return confidences
21
+
22
+
23
+ interface = gr.Interface(
24
+ fn=classify, inputs="image", outputs="label", title="Bean leaf classification"
25
+ )
26
+
27
+ interface.launch(debug=True)