Update app.py
Browse files
app.py
CHANGED
@@ -100,17 +100,17 @@ def create_3d_obj(rgb_image, depth_image, image_path, depth=10):
|
|
100 |
return gltf_path
|
101 |
|
102 |
|
103 |
-
title = "
|
104 |
-
description = "
|
105 |
-
examples = [["
|
106 |
|
107 |
iface = gr.Interface(fn=process_image,
|
108 |
inputs=[gr.Image(
|
109 |
-
type="filepath", label="
|
110 |
-
outputs=[gr.Image(label="
|
111 |
-
gr.Model3D(label="
|
112 |
1.0, 1.0, 1.0, 1.0]),
|
113 |
-
gr.File(label="
|
114 |
title=title,
|
115 |
description=description,
|
116 |
examples=examples,
|
|
|
100 |
return gltf_path
|
101 |
|
102 |
|
103 |
+
title = "2D to 3D Web App che sfrutta un modello DPT<a href='https://huggingface.co/Intel/dpt-large' target='_blank'>(MiDaS 3.0)</a>"
|
104 |
+
description = "Questa demo utilizza un modello DPT per il calcolo della profondità di un'immagine, può calcolare poi una point cloud che usa per generare una mesh texturizzata."
|
105 |
+
examples = [["esempi/" + img] for img in os.listdir("esempi/")]
|
106 |
|
107 |
iface = gr.Interface(fn=process_image,
|
108 |
inputs=[gr.Image(
|
109 |
+
type="filepath", label="Immagine di partenza")],
|
110 |
+
outputs=[gr.Image(label="Depth Map", type="pil"),
|
111 |
+
gr.Model3D(label="Ricostruzione 3D della Mesh", clear_color=[
|
112 |
1.0, 1.0, 1.0, 1.0]),
|
113 |
+
gr.File(label="File gLTF")],
|
114 |
title=title,
|
115 |
description=description,
|
116 |
examples=examples,
|