Skip to content

Latest commit

 

History

History
81 lines (53 loc) · 4.8 KB

File metadata and controls

81 lines (53 loc) · 4.8 KB

Real To Sim

Consider a LeRobot dataset created via teleoperation.

Visualize Dataset HuggingFace space is an interactive tool to visualize episodes from the dataset.

real sim
episode_000001.mp4
VisualizeEpisode2.mp4

Following script replays the select tele-operated episodes.

It replays each frame of the episode dataset into a dedicated simulation environment, using the same FPS as the camera.

It sends control command using the follower robot state qpos as input.

The simulator executes all the environments steps in parallel.

Local run

python scripts/sim/replay_episodes.py --dataset-repo-id alexis779/so100_ball_cup2 --episode-id 0,1,2,3,4,5,6,7,8

Remote run

Replay the full tele-operated dataset on modal, with all the episodes replaying at the same time, on the GPU / Cuda backend.

modal run scripts/sim/calibrate_params.py::replay_episodes --dataset-repo-id alexis779/so100_ball_cup2

The logs indicate the breakdown of the execution into substeps, for a total of 4 minutes.

  1. Initialization (~ 20 sec)
  2. 3D model convex decomposition of the robotic arm parts and objects of the scene (~ 1 min)
  3. Scene building (~ 10 sec)
  4. Simulation Kernel compilation (~ 1 min 20 sec)
  5. Execution of the simuation (~ 1 min 40 sec)
[Genesis] [23:49:58] [INFO] ╭───────────────────────────────────────────────╮
[Genesis] [23:49:58] [INFO] │┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈ Genesis ┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈│
[Genesis] [23:49:58] [INFO] ╰───────────────────────────────────────────────╯
[Genesis] [23:49:58] [INFO] Running on [NVIDIA A10] with backend gs.cuda. Device memory: 22.07 GB.
[Genesis] [23:49:58] [INFO] 🚀 Genesis initialized. 🔖 version: 0.2.1, 🌱 seed: None, 📏 precision: '32', 🐛 debug: False, 🎨 theme: 'dark'.

[Genesis] [23:50:08] [INFO] Running convex decomposition.

[Genesis] [23:50:55] [INFO] Building scene <776204b>...

[Genesis] [23:51:08] [INFO] Compiling simulation kernels...

[Genesis] [23:52:25] [INFO] Building visualizer...

[Genesis] [23:54:02] [INFO] 💤 Exiting Genesis and caching compiled kernels...
2025-06-30 23:54:03,146 - INFO - Dataset alexis779/so100_ball_cup2 score = 0.6730769276618958
Stopping app - local entrypoint completed.

Modal GPU container metrics

4 9
EpisodeReplay4.mp4
EpisodeReplay9.mp4

Generate LeRobot dataset

Generate the equivalent LeRobot SIM dataset from the LeRobot REAL dataset.

See SIM Example generated from Real Example

python scripts/sim/generate_sim_lerobot_dataset.py --dataset-repo-id alexis779/so100_ball_cup2 --sim-dataset-repo-id alexis779/so100_ball_cup2_sim

Pick & Place frames

real sim
Camera Simulation