Repository navigation
Env Profile Design & Bin Stack Task for SkillGen - #38
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughAdds YAML-driven environment profiles for Isaac Lab scene and event overlays, integrates profile-selected planners into dataset generation, records profile metadata, and adds bin-stack SkillGen configurations with unit and end-to-end tests. ChangesEnvironment Profiled SkillGen Generation
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant CLI
participant EnvironmentProfile
participant setup_env_config
participant apply_env_profile
participant CuroboPlannerCfg
participant GenerationResult
CLI->>EnvironmentProfile: load profile YAML
CLI->>setup_env_config: pass profile
setup_env_config->>apply_env_profile: overlay scene and events
CLI->>CuroboPlannerCfg: select profile planner
CLI->>GenerationResult: record profile metadata
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
20e2d41 to
e66eac3
Compare
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@isaac_autodata_examples/generate_dataset.py`:
- Around line 223-239: Keep the existing planner-profile precedence and
task-name fallback in _build_motion_planners unchanged. Add focused unit
coverage for CuroboPlannerCfg.from_profile that verifies a known profile key
returns the expected configuration and an unknown profile raises the intended
assertion or error.
In `@isaac_autodata_interfaces/env/env_profile.py`:
- Around line 140-209: Update the public classmethod docstrings for
EnvironmentProfile.from_yaml and EnvironmentProfile.from_dict to include
Google-style Args sections documenting path and data respectively, with clear
descriptions of their expected inputs. Preserve the existing behavior and other
docstring content.
- Around line 248-288: Update _validate_scene_dict to validate vector-valued
fields on each rigid_objects.add entry, ensuring position, rotation, and scale
values are sequence-like with the expected vector length and rejecting strings
or malformed values before coercion. Validate rigid_props as a dict for both add
and override entries, while preserving the existing non-empty requirement for
override.rigid_props.
In `@isaac_autodata_tests/interfaces/env/test_env_profile.py`:
- Around line 93-97: Update the match pattern in
test_validate_unknown_rigid_objects_key_fails to escape the dot in
“scene.rigid_objects,” ensuring pytest’s regex matches the literal field path
and satisfies RUF043.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Enterprise
Run ID: 39cf86ed-5ec5-4949-9026-d73626ca0213
📒 Files selected for processing (15)
.gitignoreisaac_autodata_examples/env_profiles/franka_bin_stack.yamlisaac_autodata_examples/generate_dataset.pyisaac_autodata_examples/tasks/franka_bin_stack_skillgen.yamlisaac_autodata_interfaces/env/__init__.pyisaac_autodata_interfaces/env/env_profile.pyisaac_autodata_interfaces/env/isaaclab_env_interface.pyisaac_autodata_interfaces/motion_planners/curobo/curobo_planner_cfg.pyisaac_autodata_tests/e2e/test_skillgen_bin_data_generation.pyisaac_autodata_tests/interfaces/env/__init__.pyisaac_autodata_tests/interfaces/env/test_env_profile.pyisaac_autodata_tests/interfaces/env/test_env_profile_apply.pyisaac_autodata_tests/utils/constants.pyisaac_autodata_tests/utils/test_generation_result.pyisaac_autodata_utils/generation_result.py
peterd-NV
left a comment
There was a problem hiding this comment.
lgtm. The additional set of schema checks suggested by bot review seems like a good idea to consider adding.
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@isaac_autodata_tests/interfaces/env/test_env_profile.py`:
- Around line 128-133: Replace the manual case loop in
test_validate_added_rigid_object_bad_vector_shapes_fail with
pytest.mark.parametrize, passing each key and bad_value as a separate case while
retaining the existing assertion message matching and validation setup.
In `@isaac_autodata_tests/interfaces/motion_planners/test_curobo_planner_cfg.py`:
- Around line 26-30: Rename the unused first parameter in the lambda passed to
classmethod within test_from_profile_dispatches_to_registered_factories to an
underscore-prefixed name, preserving positional binding and the sentinel return
behavior.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Enterprise
Run ID: 8e78c1c2-ea3d-4320-934c-a5046ce6d1c2
📒 Files selected for processing (4)
isaac_autodata_interfaces/env/env_profile.pyisaac_autodata_tests/interfaces/env/test_env_profile.pyisaac_autodata_tests/interfaces/motion_planners/__init__.pyisaac_autodata_tests/interfaces/motion_planners/test_curobo_planner_cfg.py
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@isaac_autodata_interfaces/motion_planners/curobo/curobo_planner_cfg.py`:
- Around line 460-463: Replace the assertion guarding the profile_name lookup in
the planner-profile factory with an explicit ValueError (or the project’s
configuration error) when profile_name is absent from PLANNER_PROFILES,
preserving the existing descriptive message and valid-profile return behavior.
In `@isaac_autodata_tests/interfaces/motion_planners/test_curobo_planner_cfg.py`:
- Around line 23-25: Extend test_planner_profile_registry_contents or add a
focused test that exercises from_profile() for every registered name, verifying
each dispatches to the expected profile-specific factory/configuration. Use
monkeypatching or lightweight configuration assertions so the test does not
download assets, while retaining the existing registry shape and callable
checks.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Enterprise
Run ID: 4e807226-9251-4aa7-b5c9-f49fef351af1
📒 Files selected for processing (2)
isaac_autodata_interfaces/motion_planners/curobo/curobo_planner_cfg.pyisaac_autodata_tests/interfaces/motion_planners/test_curobo_planner_cfg.py
Summary
Adds a declarative environment profile mechanism for creating task variants without new env ids, and uses it to enable SkillGen bin-stack data generation on the generic Franka cube-stack task.
Detailed description
Environment profiles (
isaac_autodata_interfaces/env/env_profile.py)EnvironmentProfileis a validated YAML schema describing a task variant: rigid objects to add (USD spawn, pose, scale, rigid props) or override, event terms to add/remove (e.g. reset randomizations), and the motion-planner profile matching the modified scene.gym.make(apply_env_profileinisaaclab_env_interface.py); the schema module itself has noisaaclabdependency and fails fast on invalid input.Planner-profile registry (
curobo_planner_cfg.py)PLANNER_PROFILESregistry andCuroboPlannerCfg.from_profile(), so env profiles select planner tuning by name instead of relying on task-id substring matching (which stays as the fallback).CLI & Results (
scripts/generate_dataset.py,generation_result.py)--env_profile <yaml>flag; when set, the profile is applied before env creation and its planner profile drives planner construction.Bin-stack SkillGen example
env_profiles/franka_bin_stack.yaml: blue sorting bin fixed at table center with the blue cube pinned inside; red/green cubes randomize outside; stiffer contact solving for cubes settling against the bin walls.tasks/franka_bin_stack_skillgen.yaml: SkillGen task descriptor for stacking into the bin.Tests
test_skillgen_bin_data_generation.py, single- and multi-env).