TSDF fusion β mesh
Fuses multi-view depth into a truncated SDF volume and extracts a mesh with marching cubes.
Trained from scratch in Ropedia Academy β an interactive, bilingual course on embodied & spatial AI. Educational model: small and quick to train; the value is the method and a reproducible pipeline, not a leaderboard score. Try it live in the Ropedia demos Space.
At a glance
Dataset
- Name: Synthetic depth views
- Type: synthetic β procedural
- Size / stats: 1 scene (two spheres); 6 orthographic depth maps fused into a 64Β³ TSDF grid
- Split: single scene
- Source: procedural
Training config
No training β TSDF integration of 6 depth views into a 64Β³ grid; marching cubes for the mesh.
Evaluation results
| metric | value | meaning |
|---|---|---|
verts |
27362 | |
faces |
56058 |
Inference example
import torch
state = torch.load("mesh.pt", map_location="cpu") # this repo's checkpoint
# Rebuild the exact module from the lab notebook (see "Reproduce"), then:
# model.load_state_dict(state); model.eval()
Limitations
Educational scale. Trained quickly on CPU on small or synthetic data, so absolute numbers are not competitive with production systems β the value is the method and a reproducible pipeline. No large-scale data, no hyperparameter sweep, and no multi-seed variance is reported. Not for production use.
Failure cases
Sparse views leave holes; a bad truncation distance breaks or over-smooths the surface (marching-cubes arrays need .copy()).
Reproduce / train your own
One click: open the notebook in Colab β Runtime β GPU β Run all, then run its Publish to the Hugging Face Hub cell.
From a shell:
git clone https://github.com/ChaoYue0307/ropedia-academy.git && cd ropedia-academy
pip install torch numpy matplotlib scikit-learn scikit-image gymnasium
jupyter nbconvert --to notebook --execute notebooks/training/D_tsdf_fusion.ipynb --output run.ipynb
# optional: override training length, e.g. STEPS=2000 (or EPISODES=600) before running
Files
figure.pngmesh.ptmetrics.json
License
Code & weights: MIT (this repository) β educational use encouraged.
Data: generated procedurally in the notebook β no external dataset.
Citation
If you use this model or the course materials, please cite:
@misc{ropedia_academy,
title = {Ropedia Academy: an interactive course on embodied & spatial AI},
author = {Ropedia Academy},
year = {2026},
howpublished = {\url{https://chaoyue0307.github.io/ropedia-academy/}}
}
Method / original work: Curless & Levoy, A Volumetric Method (TSDF), SIGGRAPH 1996; Lorensen & Cline, Marching Cubes, 1987.
Related assets
- π Live demos: https://huggingface.co/spaces/cy0307/ropedia-demos
- π€ All trained models + collection: https://huggingface.co/cy0307
- π Course & all labs: https://chaoyue0307.github.io/ropedia-academy/ Β· Labs tab
- π» Source / notebooks: github.com/ChaoYue0307/ropedia-academy
Part of the Ropedia Academy trained-model collection. Contributions & issues welcome on GitHub.
