Spaces:
Running
Running
fix: app.
Browse files
main.py
CHANGED
@@ -16,10 +16,15 @@ def predict(inp):
|
|
16 |
return confidences
|
17 |
|
18 |
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
)
|
|
|
24 |
|
25 |
-
demo.launch()
|
|
|
|
|
|
|
|
|
|
16 |
return confidences
|
17 |
|
18 |
|
19 |
+
def run():
|
20 |
+
demo = gr.Interface(
|
21 |
+
fn=predict,
|
22 |
+
inputs=gr.inputs.Image(type="pil"),
|
23 |
+
outputs=gr.outputs.Label(num_top_classes=3),
|
24 |
+
)
|
25 |
|
26 |
+
demo.launch(server_name="0.0.0.0", server_port=7860)
|
27 |
+
|
28 |
+
|
29 |
+
if __name__ == "__main__":
|
30 |
+
run()
|