Spaces:
Paused
Paused
File size: 595 Bytes
e283fdf |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
import gradio as gr
import os
def load_mesh(mesh_file_name):
return mesh_file_name
demo = gr.Interface(
fn=load_mesh,
inputs=gr.Model3D(),
outputs=gr.Model3D(
clear_color=(255.0, 0.0, 0.0, 0.0), label="3D Model", display_mode="wireframe"),
examples=[
[os.path.join(os.path.dirname(__file__), "examples/bunny/mesh.obj")],
[os.path.join(os.path.dirname(__file__), "examples/monkey/mesh.obj")],
[os.path.join(os.path.dirname(__file__), "examples/Bunny.obj")],
],
cache_examples=True
)
if __name__ == "__main__":
demo.launch()
|