Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -51,4 +51,14 @@ def detect_objects(image):
|
|
| 51 |
# --- Gradio Interface ---
|
| 52 |
demo = gr.Interface(
|
| 53 |
fn=detect_objects,
|
| 54 |
-
inputs=
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 51 |
# --- Gradio Interface ---
|
| 52 |
demo = gr.Interface(
|
| 53 |
fn=detect_objects,
|
| 54 |
+
inputs=gr.Image(type="numpy", label="Upload Image"),
|
| 55 |
+
outputs=[
|
| 56 |
+
gr.Image(type="numpy", label="Detected Objects"),
|
| 57 |
+
gr.Textbox(label="Objects Detected")
|
| 58 |
+
],
|
| 59 |
+
title="🧠 Object Detection App",
|
| 60 |
+
description="Upload an image — YOLOv8s detects all objects and lists their names!"
|
| 61 |
+
)
|
| 62 |
+
|
| 63 |
+
if __name__ == "__main__":
|
| 64 |
+
demo.launch(server_name="0.0.0.0", server_port=7860)
|