Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -10,7 +10,7 @@ import gradio as gr
|
|
| 10 |
def analyze_image(img):
|
| 11 |
# creating an image object and passing to the analyzer by using dataflows
|
| 12 |
image = Image(file_name="input.png", location="")
|
| 13 |
-
image.image = img
|
| 14 |
|
| 15 |
df = DataFromList(lst=[image])
|
| 16 |
|
|
@@ -23,7 +23,7 @@ def analyze_image(img):
|
|
| 23 |
|
| 24 |
return dp.viz(show_cells=False)
|
| 25 |
|
| 26 |
-
inputs = gr.inputs.Image(type='numpy',
|
| 27 |
outputs = gr.outputs.Image(type="numpy", label="Output Image")
|
| 28 |
|
| 29 |
title = "Deepdoctection"
|
|
|
|
| 10 |
def analyze_image(img):
|
| 11 |
# creating an image object and passing to the analyzer by using dataflows
|
| 12 |
image = Image(file_name="input.png", location="")
|
| 13 |
+
image.image = img[:,:,::-1]
|
| 14 |
|
| 15 |
df = DataFromList(lst=[image])
|
| 16 |
|
|
|
|
| 23 |
|
| 24 |
return dp.viz(show_cells=False)
|
| 25 |
|
| 26 |
+
inputs = gr.inputs.Image(type='numpy', label="Original Image")
|
| 27 |
outputs = gr.outputs.Image(type="numpy", label="Output Image")
|
| 28 |
|
| 29 |
title = "Deepdoctection"
|