Spaces:
Running
Running
A newer version of the Gradio SDK is available:
6.0.0
metadata
title: 2D β 3D Reconstruction (GLPN + Open3D)
emoji: π
colorFrom: indigo
colorTo: purple
sdk: gradio
sdk_version: 4.29.0
app_file: app.py
pinned: false
license: mit
tags:
- depth-estimation
- monocular
- 3d-reconstruction
- open3d
- point-cloud
- mesh
- gradio
- huggingface
2D β 3D Reconstruction (GLPN + Open3D)
This Space estimates monocular depth from a single RGB image using GLPN, builds an RGB-D point cloud, and reconstructs a 3D mesh with Poisson surface reconstruction via Open3D.
π How it works
- Upload an image.
- GLPN (NYU pretrained) β predict relative depth.
- Open3D β convert RGB + depth β point cloud.
- Poisson reconstruction β mesh (downloadable
.objand.ply). - Preview depth map, mesh snapshot, and explore the mesh interactively.
π¦ Outputs
- Depth map (colorized preview)
- Point cloud (.ply)
- Mesh (.obj) (with Gradio 3D viewer)
- Mesh preview PNG (best-effort offscreen render, if available)
β οΈ Notes
- Monocular depth has no absolute scale β geometry is up-to-scale only.
- For metric accuracy, swap in stereo, multi-view SfM, or metric depth models (ZoeDepth, Depth Anything v2).
- Works on CPU or GPU Spaces. GPU recommended for faster inference.
π οΈ Local Development
git clone <this-space>
cd <this-space>
pip install -r requirements.txt
python app.py