Spaces:
Running
on
Zero
Running
on
Zero
Update app_2.py
Browse files
app_2.py
CHANGED
@@ -1155,7 +1155,7 @@ with block:
|
|
1155 |
with gr.Row():
|
1156 |
run_button = gr.Button("Generate alternative angles")
|
1157 |
|
1158 |
-
|
1159 |
label="Result",
|
1160 |
show_label=False,
|
1161 |
columns=[3],
|
@@ -1165,9 +1165,9 @@ with block:
|
|
1165 |
allow_preview=False,
|
1166 |
)
|
1167 |
|
1168 |
-
if
|
1169 |
selected = gr.Number(visible=True)
|
1170 |
-
|
1171 |
|
1172 |
# output_bg = gr.Image(type="numpy", label="Preprocessed Foreground", height=480)
|
1173 |
with gr.Group():
|
@@ -1233,7 +1233,7 @@ with block:
|
|
1233 |
"high quality",
|
1234 |
extracted_fg,
|
1235 |
],
|
1236 |
-
outputs=[
|
1237 |
)
|
1238 |
|
1239 |
find_objects_button.click(
|
|
|
1155 |
with gr.Row():
|
1156 |
run_button = gr.Button("Generate alternative angles")
|
1157 |
|
1158 |
+
orientation_result = gr.Gallery(
|
1159 |
label="Result",
|
1160 |
show_label=False,
|
1161 |
columns=[3],
|
|
|
1165 |
allow_preview=False,
|
1166 |
)
|
1167 |
|
1168 |
+
if orientation_result:
|
1169 |
selected = gr.Number(visible=True)
|
1170 |
+
orientation_result.select(use_orientation, inputs=None, outputs=extracted_fg)
|
1171 |
|
1172 |
# output_bg = gr.Image(type="numpy", label="Preprocessed Foreground", height=480)
|
1173 |
with gr.Group():
|
|
|
1233 |
"high quality",
|
1234 |
extracted_fg,
|
1235 |
],
|
1236 |
+
outputs=[orientation_result],
|
1237 |
)
|
1238 |
|
1239 |
find_objects_button.click(
|