docs: clarify ring bar task state contracts

This commit is contained in:
Logic
2026-04-23 16:47:05 +08:00
parent 4ea75966ee
commit 636290d36a
2 changed files with 22 additions and 11 deletions

View File

@@ -110,9 +110,9 @@ Run:
- [ ] **Step 1: Write failing tests for object reset helpers and scene-specific joint naming assumptions**
In `tests/test_air_insert_env.py`, add unit tests for helper functions that:
- write ring pose to `ring_block_joint`
- write bar pose to `bar_block_joint`
- read back task state in a stable structure
- write ring pose to `ring_block_joint` from the named task-state mapping
- write bar pose to `bar_block_joint` from the named task-state mapping
- read back `env_state` as a stable 14D vector `[ring_pos, ring_quat, bar_pos, bar_quat]`
Use fake `mj_data` objects so tests stay fast and deterministic.
@@ -209,8 +209,9 @@ Run:
Add tests covering:
- the new policy produces a 16D action
- trajectory generation accepts sampled ring/bar state without error
- trajectory generation accepts sampled named task state without error
- the first action is a valid open-gripper safe pose command
- a deterministic nominal smoke path (with canonical sampled state or fake env shim) reaches the intended terminal interface contract without shape/reward mismatches
Keep the tests unit-level; do not require a full MuJoCo rollout for every assertion.