Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -81,8 +81,7 @@ class PaperEdge(object):
|
|
81 |
return save_path
|
82 |
|
83 |
|
84 |
-
def inference(
|
85 |
-
img_path = img.name
|
86 |
save_img_path = paper_edge(img_path)
|
87 |
return save_img_path
|
88 |
|
@@ -103,9 +102,9 @@ css = ".output_image, .input_image {height: 40rem !important; width: 100% !impor
|
|
103 |
|
104 |
gr.Interface(
|
105 |
inference,
|
106 |
-
inputs=gr.inputs.Image(type='
|
107 |
outputs=[
|
108 |
-
gr.outputs.Image(type='
|
109 |
],
|
110 |
title=title,
|
111 |
description=description,
|
|
|
81 |
return save_path
|
82 |
|
83 |
|
84 |
+
def inference(img_path):
|
|
|
85 |
save_img_path = paper_edge(img_path)
|
86 |
return save_img_path
|
87 |
|
|
|
102 |
|
103 |
gr.Interface(
|
104 |
inference,
|
105 |
+
inputs=gr.inputs.Image(type='filepath', label='Input'),
|
106 |
outputs=[
|
107 |
+
gr.outputs.Image(type='filepath', label='Output_image'),
|
108 |
],
|
109 |
title=title,
|
110 |
description=description,
|