Update app.py
Browse files
app.py
CHANGED
@@ -255,10 +255,17 @@ if __name__ == "__main__":
|
|
255 |
|
256 |
with gr.Column(elem_id="col-container"):
|
257 |
|
258 |
-
gr.
|
259 |
-
"""
|
260 |
-
|
261 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
262 |
)
|
263 |
|
264 |
with gr.Row():
|
@@ -287,7 +294,40 @@ if __name__ == "__main__":
|
|
287 |
pan_speed=0.5,
|
288 |
camera_position=[20, 20, 20],
|
289 |
)
|
290 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
291 |
with gr.Row():
|
292 |
with gr.Row():
|
293 |
rgb_video = gr.Video(
|
@@ -298,43 +338,7 @@ if __name__ == "__main__":
|
|
298 |
interactive=False,
|
299 |
autoplay=True,
|
300 |
)
|
301 |
-
|
302 |
-
|
303 |
-
# ---------------------- Examples section ----------------------
|
304 |
-
|
305 |
-
examples = [
|
306 |
-
["examples/video/re10k_1eca36ec55b88fe4.mp4"],
|
307 |
-
["examples/video/bungeenerf_colosseum.mp4"],
|
308 |
-
["examples/video/fox.mp4"],
|
309 |
-
["examples/video/matrixcity_street.mp4"],
|
310 |
-
# [None, "examples/video/vrnerf_apartment.mp4", "vrnerf", "apartment", "32", "Real", "True",],
|
311 |
-
# [None, "examples/video/vrnerf_kitchen.mp4", "vrnerf", "kitchen", "17", "Real", "True",],
|
312 |
-
# [None, "examples/video/vrnerf_riverview.mp4", "vrnerf", "riverview", "12", "Real", "True",],
|
313 |
-
# [None, "examples/video/vrnerf_workshop.mp4", "vrnerf", "workshop", "32", "Real", "True",],
|
314 |
-
# [None, "examples/video/fillerbuster_ramen.mp4", "fillerbuster", "ramen", "32", "Real", "True",],
|
315 |
-
# [None, "examples/video/meganerf_rubble.mp4", "meganerf", "rubble", "10", "Real", "True",],
|
316 |
-
# [None, "examples/video/llff_horns.mp4", "llff", "horns", "12", "Real", "True",],
|
317 |
-
# [None, "examples/video/llff_fortress.mp4", "llff", "fortress", "7", "Real", "True",],
|
318 |
-
# [None, "examples/video/dtu_scan_106.mp4", "dtu", "scan_106", "20", "Real", "True",],
|
319 |
-
# [None, "examples/video/horizongs_hillside_summer.mp4", "horizongs", "hillside_summer", "55", "Synthetic", "True",],
|
320 |
-
# [None, "examples/video/kitti360.mp4", "kitti360", "kitti360", "64", "Real", "True",],
|
321 |
-
]
|
322 |
-
|
323 |
-
gr.Examples(
|
324 |
-
examples=examples,
|
325 |
-
inputs=[
|
326 |
-
input_video
|
327 |
-
],
|
328 |
-
outputs=[
|
329 |
-
reconstruction_output,
|
330 |
-
rgb_video,
|
331 |
-
depth_video,
|
332 |
-
image_gallery
|
333 |
-
],
|
334 |
-
fn=generate_splat_from_video,
|
335 |
-
cache_examples=True,
|
336 |
-
)
|
337 |
-
|
338 |
submit_btn.click(
|
339 |
fn=generate_splat_from_images,
|
340 |
inputs=[target_dir_output, session_state],
|
|
|
255 |
|
256 |
with gr.Column(elem_id="col-container"):
|
257 |
|
258 |
+
gr.HTML(
|
259 |
+
"""
|
260 |
+
<div style="text-align: center;">
|
261 |
+
<p style="font-size:16px; display: inline; margin: 0;">
|
262 |
+
<strong>AnySplat</strong> – Feed-forward 3D Gaussian Splatting from Unconstrained Views
|
263 |
+
</p>
|
264 |
+
<a href="https://github.com/OpenRobotLab/AnySplat" style="display: inline-block; vertical-align: middle; margin-left: 0.5em;">
|
265 |
+
<img src="https://img.shields.io/badge/GitHub-Repo-blue" alt="GitHub Repo">
|
266 |
+
</a>
|
267 |
+
</div>
|
268 |
+
"""
|
269 |
)
|
270 |
|
271 |
with gr.Row():
|
|
|
294 |
pan_speed=0.5,
|
295 |
camera_position=[20, 20, 20],
|
296 |
)
|
297 |
+
|
298 |
+
examples = [
|
299 |
+
["examples/video/re10k_1eca36ec55b88fe4.mp4"],
|
300 |
+
["examples/video/bungeenerf_colosseum.mp4"],
|
301 |
+
["examples/video/fox.mp4"],
|
302 |
+
["examples/video/matrixcity_street.mp4"],
|
303 |
+
["examples/video/vrnerf_apartment.mp4"],
|
304 |
+
# [None, "examples/video/vrnerf_kitchen.mp4", "vrnerf", "kitchen", "17", "Real", "True",],
|
305 |
+
# [None, "examples/video/vrnerf_riverview.mp4", "vrnerf", "riverview", "12", "Real", "True",],
|
306 |
+
# [None, "examples/video/vrnerf_workshop.mp4", "vrnerf", "workshop", "32", "Real", "True",],
|
307 |
+
# [None, "examples/video/fillerbuster_ramen.mp4", "fillerbuster", "ramen", "32", "Real", "True",],
|
308 |
+
# [None, "examples/video/meganerf_rubble.mp4", "meganerf", "rubble", "10", "Real", "True",],
|
309 |
+
# [None, "examples/video/llff_horns.mp4", "llff", "horns", "12", "Real", "True",],
|
310 |
+
# [None, "examples/video/llff_fortress.mp4", "llff", "fortress", "7", "Real", "True",],
|
311 |
+
# [None, "examples/video/dtu_scan_106.mp4", "dtu", "scan_106", "20", "Real", "True",],
|
312 |
+
# [None, "examples/video/horizongs_hillside_summer.mp4", "horizongs", "hillside_summer", "55", "Synthetic", "True",],
|
313 |
+
# [None, "examples/video/kitti360.mp4", "kitti360", "kitti360", "64", "Real", "True",],
|
314 |
+
]
|
315 |
+
|
316 |
+
gr.Examples(
|
317 |
+
examples=examples,
|
318 |
+
inputs=[
|
319 |
+
input_video
|
320 |
+
],
|
321 |
+
outputs=[
|
322 |
+
reconstruction_output,
|
323 |
+
rgb_video,
|
324 |
+
depth_video,
|
325 |
+
image_gallery
|
326 |
+
],
|
327 |
+
fn=generate_splat_from_video,
|
328 |
+
cache_examples=True,
|
329 |
+
)
|
330 |
+
|
331 |
with gr.Row():
|
332 |
with gr.Row():
|
333 |
rgb_video = gr.Video(
|
|
|
338 |
interactive=False,
|
339 |
autoplay=True,
|
340 |
)
|
341 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
342 |
submit_btn.click(
|
343 |
fn=generate_splat_from_images,
|
344 |
inputs=[target_dir_output, session_state],
|