upgrade1
Browse files
app.py
CHANGED
@@ -116,7 +116,8 @@ def sepia(input_img):
|
|
116 |
pred_img = pred_img.astype(np.uint8)
|
117 |
|
118 |
fig = draw_plot(pred_img, seg)
|
119 |
-
|
|
|
120 |
|
121 |
demo = gr.Interface(fn=sepia,
|
122 |
inputs=gr.Image(shape=(400, 600)),
|
|
|
116 |
pred_img = pred_img.astype(np.uint8)
|
117 |
|
118 |
fig = draw_plot(pred_img, seg)
|
119 |
+
filename = input_image.name if hasattr(input_image, "name") else "Unknown filename"
|
120 |
+
return fig, filename
|
121 |
|
122 |
demo = gr.Interface(fn=sepia,
|
123 |
inputs=gr.Image(shape=(400, 600)),
|