Update app.py
Browse files
app.py
CHANGED
|
@@ -80,14 +80,14 @@ def get_system_stats():
|
|
| 80 |
with gr.Blocks(title="去背服務測試") as app:
|
| 81 |
gr.Markdown("## ✂️ 去背服務測試")
|
| 82 |
|
| 83 |
-
|
| 84 |
# Tab 1: Image Processing
|
| 85 |
with gr.Tab("✂️ Remove Background"):
|
| 86 |
with gr.Row():
|
| 87 |
img_in = gr.Image(type="pil", label="Input Image")
|
| 88 |
img_out = gr.Image(type="pil", label="Result (PNG)", format="png")
|
| 89 |
-
|
| 90 |
-
|
| 91 |
|
| 92 |
# Tab 2: System Monitor (UI for Space Page)
|
| 93 |
with gr.Tab("📊 System Monitor"):
|
|
|
|
| 80 |
with gr.Blocks(title="去背服務測試") as app:
|
| 81 |
gr.Markdown("## ✂️ 去背服務測試")
|
| 82 |
|
| 83 |
+
with gr.Tabs():
|
| 84 |
# Tab 1: Image Processing
|
| 85 |
with gr.Tab("✂️ Remove Background"):
|
| 86 |
with gr.Row():
|
| 87 |
img_in = gr.Image(type="pil", label="Input Image")
|
| 88 |
img_out = gr.Image(type="pil", label="Result (PNG)", format="png")
|
| 89 |
+
btn = gr.Button("Remove Background", variant="primary")
|
| 90 |
+
btn.click(process, inputs=img_in, outputs=img_out)
|
| 91 |
|
| 92 |
# Tab 2: System Monitor (UI for Space Page)
|
| 93 |
with gr.Tab("📊 System Monitor"):
|