You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/source/overview/imitation-learning/skillgen.rst
+45-56Lines changed: 45 additions & 56 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,9 +1,9 @@
1
1
.. _skillgen:
2
2
3
-
SkillGen
4
-
========
3
+
SkillGen for Automated Demonstration Generation
4
+
===============================================
5
5
6
-
SkillGen is an advanced demonstration generation system that enhances Isaac Lab Mimic by integrating cuRobo motion planning. It generates high-quality, adaptive, collision-free robot demonstrations by combining human-provided subtask segments with automated motion planning.
6
+
SkillGen is an advanced demonstration generation system that enhances Isaac Lab Mimic by integrating motion planning. It generates high-quality, adaptive, collision-free robot demonstrations by combining human-provided subtask segments with automated motion planning.
7
7
8
8
What is SkillGen?
9
9
~~~~~~~~~~~~~~~~~
@@ -134,35 +134,37 @@ Download and Setup
134
134
135
135
A major advantage of SkillGen is that the same annotated dataset can be reused across multiple related tasks (e.g., basic stacking and adaptive bin stacking). This avoids collecting and annotating new data per variant.
136
136
137
-
.. note::
137
+
.. admonition:: {Optional for the tasks in this tutorial} Collect a fresh dataset (source + annotated)
138
138
139
-
**SkillGen-specific data collection and annotation**
139
+
If you want to collect a fresh source dataset and then create an annotated dataset for SkillGen, follow these commands. The user is expected to have knowledge of the Isaac Lab Mimic workflow.
140
140
141
-
* Using the provided annotated dataset is the fastest path to get started with SkillGen
142
-
* If you create your own dataset, SkillGen requires manual annotation of both subtask start and termination boundaries (no auto-annotation)
143
-
* Start boundary signals are mandatory for SkillGen; use ``--annotate_subtask_start_signals`` during annotation or data generation will fail
144
-
* Keep your subtask definitions (``object_ref``, ``subtask_term_signal``) consistent with the SkillGen environment config
141
+
**Important pointers before you begin**
145
142
146
-
Record demonstrations (any teleop device is supported; replace ``spacemouse`` if needed):
143
+
* Using the provided annotated dataset is the fastest path to get started with SkillGen tasks in this tutorial.
144
+
* If you create your own dataset, SkillGen requires manual annotation of both subtask start and termination boundaries (no auto-annotation).
145
+
* Start boundary signals are mandatory for SkillGen; use ``--annotate_subtask_start_signals`` during annotation or data generation will fail.
146
+
* Keep your subtask definitions (``object_ref``, ``subtask_term_signal``) consistent with the SkillGen environment config.
147
147
148
-
.. code:: bash
148
+
**Record demonstrations** (any teleop device is supported; replace ``spacemouse`` if needed):
* ``subtask_term_signal``: the binary termination signal name (transitions 0 to 1 when the subtask completes)
179
181
* ``subtask_start_signal``: the binary start signal name (transitions 0 to 1 when the subtask begins; required for SkillGen)
180
182
181
-
The localization process performs:
183
+
The subtask localization process performs:
182
184
183
185
* detection of signal transition points (0 to 1) to identify subtask boundaries ``[t_start, t_end]``;
184
186
* extraction of the subtask segment between boundaries;
185
187
* computation of end-effector trajectories and key poses in an object- or task-relative frame (using ``object_ref`` if provided);
186
-
* optional time-normalization of progress and extraction of gripper/contact mode signals.
187
188
188
189
This converts absolute, scene-specific motions into object-relative skill segments that can be adapted to new object placements and scene configurations during data generation.
189
190
190
191
Manual Annotation Workflow
191
192
^^^^^^^^^^^^^^^^^^^^^^^^^^
192
193
Contrary to the Isaac Lab Mimic workflow, SkillGen requires manual annotation of subtask start and termination boundaries. For example, for grasping a cube, the start signal is right before the gripper closes and the termination signal is right after the object is grasped. You can adjust the start and termination signals to fit your subtask definition.
@@ -214,7 +206,7 @@ Contrary to the Isaac Lab Mimic workflow, SkillGen requires manual annotation of
214
206
Data Generation with SkillGen
215
207
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
216
208
217
-
SkillGen transforms annotated demonstrations into diverse, high-quality datasets using advanced motion planning.
209
+
SkillGen transforms annotated demonstrations into diverse, high-quality datasets using motion planning.
218
210
219
211
How SkillGen Works
220
212
^^^^^^^^^^^^^^^^^^
@@ -238,8 +230,6 @@ Key parameters for SkillGen data generation:
238
230
* ``--device``: Computation device (cpu/cuda). Use cpu for stable physics
239
231
* ``--headless``: Disable visualization for faster generation
240
232
241
-
Note: cuRobo planner interface and configurations are described in :ref:`cuRobo-interface-features`.
242
-
243
233
Task 1: Basic Cube Stacking
244
234
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
245
235
@@ -286,10 +276,10 @@ Once satisfied with small-scale results, generate a full training dataset:
286
276
287
277
.. note::
288
278
289
-
* Use ``--device cuda`` for faster generation if you have a compatible GPU
290
-
* Use ``--headless`` to disable visualization for faster generation.
291
-
* Adjust ``--num_envs`` based on your GPU memory (start with 5, increase gradually). The performance gain is not very significant when num_envs is greater than 1.
292
-
* Generation time: ~30-60 minutes for 1000 demonstrations on modern GPUs
279
+
* Use ``--headless`` to disable visualization for faster generation. Rerun visualization can be enabled by setting ``visualize_plan = True`` in the cuRobo planner configuration with ``--headless`` enabled as well for debugging.
280
+
* Adjust ``--num_envs`` based on your GPU memory (start with 1, increase gradually). The performance gain is not very significant when num_envs is greater than 1. A value of 5 seems to be a sweet spot for most GPUs to balance performance and memory usage between cuRobo instances and simulation environments.
281
+
* Generation time: ~90 to 120 minutes for one environment for 1000 demonstrations on modern GPUs. Time depends on the GPU, the number of environments, and the success rate of the demonstrations (which depends on quality of the annotated dataset).
282
+
* cuRobo planner interface and configurations are described in :ref:`cuRobo-interface-features`.
293
283
294
284
Task 2: Adaptive Cube Stacking in a Bin
295
285
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -330,7 +320,7 @@ Generate the complete adaptive stacking dataset:
330
320
331
321
.. warning::
332
322
333
-
Adaptive tasks typically have lower success rates due to increased complexity. The time taken to generate the dataset is also longer due to lower success rates than vanilla cube stacking and difficult planning problems.
323
+
Adaptive tasks typically have lower success rates and higher data generation time due to increased complexity. The time taken to generate the dataset is also longer due to lower success rates than vanilla cube stacking and difficult planning problems.
When ``--use_skillgen`` is enabled in ``generate_dataset.py``, the following pipeline is executed:
445
435
446
-
1. Randomize subtask boundaries
447
-
Randomize per-demo start and termination indices for each subtask using task-configured offset ranges.
436
+
1. **Randomize subtask boundaries**: Randomize per-demo start and termination indices for each subtask using task-configured offset ranges.
448
437
449
-
2. Build per-subtask trajectories
438
+
2. **Build per-subtask trajectories**:
450
439
For each end-effector and subtask:
440
+
451
441
- Select a source demonstration segment (strategy-driven; respects coordination/sequential constraints)
452
442
- Transform the segment to the current scene (object-relative or coordination delta; optional first-pose interpolation)
453
443
- Wrap the transformed segment into a waypoint trajectory
454
444
455
-
3. Transition between subtasks
456
-
- If ``use_skillgen``: before executing the next subtask, plan a collision-aware transition with cuRobo to the subtask’s first waypoint (world sync, optional attach/detach), execute the planned waypoints, then resume the subtask trajectory
457
-
- Otherwise: interpolate and merge directly into the subtask trajectory
445
+
3. **Transition between subtasks**:
446
+
- Plan a collision-aware transition with cuRobo to the subtask's first waypoint (world sync, optional attach/detach), execute the planned waypoints, then resume the subtask trajectory
458
447
459
-
4. Execute with constraints
460
-
Execute waypoints step-by-step across end-effectors while enforcing subtask constraints (sequential, coordination with synchronous steps); optionally update planner visualization if enabled
448
+
4. **Execute with constraints**:
449
+
- Execute waypoints step-by-step across end-effectors while enforcing subtask constraints (sequential, coordination with synchronous steps); optionally update planner visualization if enabled
461
450
462
-
5. Record and export
463
-
Accumulate states/observations/actions, set the episode success flag, and export the episode (the outer pipeline filters/consumes successes)
451
+
5. **Record and export**:
452
+
- Accumulate states/observations/actions, set the episode success flag, and export the episode (the outer pipeline filters/consumes successes)
0 commit comments