cy0307 commited on
Commit
f4f568d
Β·
verified Β·
1 Parent(s): de42f19

Upload from Ropedia Academy

Browse files
Files changed (1) hide show
  1. README.md +70 -14
README.md CHANGED
@@ -4,19 +4,25 @@ library_name: pytorch
4
  tags:
5
  - ropedia-academy
6
  - educational
 
 
 
7
  - mapping
8
  ---
9
 
10
  # Bayesian semantic mapping
11
 
12
- Fuses noisy observations into an occupancy (log-odds) + semantic-label map that converges to ground truth.
13
 
14
- Trained from scratch in **[Ropedia Academy](https://chaoyue0307.github.io/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.
 
 
15
 
16
  | | |
17
  |---|---|
 
18
  | **Task** | occupancy + semantic mapping |
19
- | **Data** | 2D grid world |
20
  | **Track** | D Β· Scene & world models |
21
  | **Notebook** | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/ChaoYue0307/ropedia-academy/blob/main/notebooks/training/D_semantic_mapping.ipynb) |
22
 
@@ -28,22 +34,48 @@ Trained from scratch in **[Ropedia Academy](https://chaoyue0307.github.io/ropedi
28
  - **Split:** single map
29
  - **Source:** procedural
30
 
31
- ## Results
32
 
33
- | metric | value |
34
- |---|---|
35
- | history (final) | 1.0 |
 
 
 
 
36
 
37
 
38
  ![figure](figure.png)
39
 
40
- ## How to use
41
 
42
  ```python
43
  import torch
44
- state = torch.load("model.pt", map_location="cpu") # some labs save pose.pt / gaussians.pt / transform.pt
45
- # Rebuild the model class from the Ropedia Academy notebook (linked above), then:
46
- # model.load_state_dict(state)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
47
  ```
48
 
49
  ## Files
@@ -54,10 +86,34 @@ state = torch.load("model.pt", map_location="cpu") # some labs save pose.pt /
54
  - `occ.npy`
55
 
56
 
57
- ## Reproduce / train your own
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
58
 
59
- Open the [lab notebook in Colab](https://colab.research.google.com/github/ChaoYue0307/ropedia-academy/blob/main/notebooks/training/D_semantic_mapping.ipynb) β†’ **Runtime β†’ GPU β†’ Run all**, then its *Publish to the Hugging Face Hub* cell. Browse every lab in the [Ropedia Academy Labs tab](https://chaoyue0307.github.io/ropedia-academy/labs).
 
 
 
60
 
61
 
62
  ---
63
- *Part of the [Ropedia Academy](https://chaoyue0307.github.io/ropedia-academy/) trained-model collection.*
 
4
  tags:
5
  - ropedia-academy
6
  - educational
7
+ - embodied-ai
8
+ - from-scratch
9
+ - reproducible
10
  - mapping
11
  ---
12
 
13
  # Bayesian semantic mapping
14
 
15
+ > Fuses noisy observations into an occupancy (log-odds) + semantic-label map that converges to ground truth.
16
 
17
+ Trained from scratch in **[Ropedia Academy](https://chaoyue0307.github.io/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](https://huggingface.co/spaces/cy0307/ropedia-demos)**.
18
+
19
+ ## At a glance
20
 
21
  | | |
22
  |---|---|
23
+ | **Base model** | Trained **from scratch** (random initialization) β€” no pretrained base model. |
24
  | **Task** | occupancy + semantic mapping |
25
+ | **Training objective** | **Bayesian** log-odds occupancy + per-cell semantic-label counting (no gradient training). |
26
  | **Track** | D Β· Scene & world models |
27
  | **Notebook** | [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/ChaoYue0307/ropedia-academy/blob/main/notebooks/training/D_semantic_mapping.ipynb) |
28
 
 
34
  - **Split:** single map
35
  - **Source:** procedural
36
 
37
+ ## Training config
38
 
39
+ No gradient training β€” Bayesian log-odds occupancy + label counting over ~300 observation rounds.
40
+
41
+ ## Evaluation results
42
+
43
+ | metric | value | meaning |
44
+ |---|---|---|
45
+ | `history (final)` | 1.0 | |
46
 
47
 
48
  ![figure](figure.png)
49
 
50
+ ## Inference example
51
 
52
  ```python
53
  import torch
54
+ state = torch.load("labels.npy", map_location="cpu") # this repo's checkpoint
55
+ # Rebuild the exact module from the lab notebook (see "Reproduce"), then:
56
+ # model.load_state_dict(state); model.eval()
57
+ ```
58
+
59
+ ## Limitations
60
+
61
+ **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.**
62
+
63
+ ## Failure cases
64
+
65
+ Mis-set sensor probabilities make the map over/under-confident; dynamic objects smear across cells.
66
+
67
+ ## Reproduce / train your own
68
+
69
+ **One click:** open the notebook in Colab β†’ **Runtime β†’ GPU β†’ Run all**, then run its *Publish to the Hugging Face Hub* cell.
70
+
71
+ [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/ChaoYue0307/ropedia-academy/blob/main/notebooks/training/D_semantic_mapping.ipynb)
72
+
73
+ **From a shell:**
74
+ ```bash
75
+ git clone https://github.com/ChaoYue0307/ropedia-academy.git && cd ropedia-academy
76
+ pip install torch numpy matplotlib scikit-learn scikit-image gymnasium
77
+ jupyter nbconvert --to notebook --execute notebooks/training/D_semantic_mapping.ipynb --output run.ipynb
78
+ # optional: override training length, e.g. STEPS=2000 (or EPISODES=600) before running
79
  ```
80
 
81
  ## Files
 
86
  - `occ.npy`
87
 
88
 
89
+ ## License
90
+
91
+ Code & weights: **MIT** (this repository) β€” educational use encouraged.
92
+ Data: generated procedurally in the notebook β€” no external dataset.
93
+
94
+ ## Citation
95
+
96
+ If you use this model or the course materials, please cite:
97
+
98
+ ```bibtex
99
+ @misc{ropedia_academy,
100
+ title = {Ropedia Academy: an interactive course on embodied & spatial AI},
101
+ author = {Ropedia Academy},
102
+ year = {2026},
103
+ howpublished = {\url{https://chaoyue0307.github.io/ropedia-academy/}}
104
+ }
105
+ ```
106
+
107
+
108
+ **Method / original work:** Moravec & Elfes, *High-Resolution Maps from Wide-Angle Sonar (occupancy grids)*, 1985; McCormac et al., *SemanticFusion*, ICRA 2017.
109
+
110
+ ## Related assets
111
 
112
+ - πŸš€ **Live demos:** [https://huggingface.co/spaces/cy0307/ropedia-demos](https://huggingface.co/spaces/cy0307/ropedia-demos)
113
+ - πŸ€— **All trained models + collection:** [https://huggingface.co/cy0307](https://huggingface.co/cy0307)
114
+ - πŸ“š **Course & all labs:** [https://chaoyue0307.github.io/ropedia-academy/](https://chaoyue0307.github.io/ropedia-academy/) Β· [Labs tab](https://chaoyue0307.github.io/ropedia-academy/labs)
115
+ - πŸ’» **Source / notebooks:** [github.com/ChaoYue0307/ropedia-academy](https://github.com/ChaoYue0307/ropedia-academy)
116
 
117
 
118
  ---
119
+ *Part of the [Ropedia Academy](https://chaoyue0307.github.io/ropedia-academy/) trained-model collection. Contributions & issues welcome on [GitHub](https://github.com/ChaoYue0307/ropedia-academy).*