fix examples signature
Browse files
app.py
CHANGED
@@ -36,9 +36,9 @@ def find_first_png(directory):
|
|
36 |
return None
|
37 |
|
38 |
|
39 |
-
def marigold_process(path_input,
|
40 |
-
if
|
41 |
-
return
|
42 |
|
43 |
path_input_dir = path_input + ".input"
|
44 |
path_output_dir = path_input + ".output"
|
@@ -54,12 +54,12 @@ def marigold_process(path_input, path_out_png=None, path_out_obj=None, path_out_
|
|
54 |
f"--denoise_steps 10 "
|
55 |
)
|
56 |
|
57 |
-
|
58 |
-
assert
|
59 |
-
|
60 |
-
assert
|
61 |
|
62 |
-
return
|
63 |
|
64 |
|
65 |
iface = gr.Interface(
|
|
|
36 |
return None
|
37 |
|
38 |
|
39 |
+
def marigold_process(path_input, path_out_vis=None, path_out_pred=None):
|
40 |
+
if path_out_vis is not None and path_out_pred is not None:
|
41 |
+
return path_out_vis, path_out_pred
|
42 |
|
43 |
path_input_dir = path_input + ".input"
|
44 |
path_output_dir = path_input + ".output"
|
|
|
54 |
f"--denoise_steps 10 "
|
55 |
)
|
56 |
|
57 |
+
path_out_vis = find_first_png(path_output_dir + "/depth_colored")
|
58 |
+
assert path_out_vis is not None, "Processing failed"
|
59 |
+
path_out_pred = find_first_png(path_output_dir + "/depth_bw")
|
60 |
+
assert path_out_pred is not None, "Processing failed"
|
61 |
|
62 |
+
return path_out_vis, path_out_pred
|
63 |
|
64 |
|
65 |
iface = gr.Interface(
|