feat(simulation): opt-in ground-truth object pose stream for eval scoring - #3960
feat(simulation): opt-in ground-truth object pose stream for eval scoring#3960Jerrybery wants to merge 1 commit into
Conversation
…ring MujocoSimModule gains publish_ground_truth (default off) and ground_truth_hz (20 Hz). When enabled, world poses of every free-joint scene body (robot root excluded — odom already covers it) publish on a new gt_object_poses Out[PoseStamped] stream, frame_id = body name. Ground truth is privileged scoring data for the evals framework (issue dimensionalOS#3594): never consumed by the agent. Part 1 of 2; part 2 adds the eval-side gt_store() and predicate library.
Greptile SummaryThis change adds an opt-in, throttled ground-truth pose stream for eligible free-joint scene bodies. It is not safe to merge until Confidence Score: 4/5Not safe to merge because an enabled ground-truth stream can crash from an accepted configuration value. Execution reproduced the failure in the ground-truth publishing path and also demonstrated incorrect behavior for other invalid rates. Files Needing Attention: dimos/simulation/engines/mujoco_sim_module.py
What T-Rex did
Important Files Changed
|
| # free-joint scene bodies (robot root excluded, odom covers it). Never | ||
| # consumed by the agent. Off = zero overhead, zero behavior change. | ||
| publish_ground_truth: bool = False | ||
| ground_truth_hz: float = 20.0 |
There was a problem hiding this comment.
When ground-truth publishing is enabled, ground_truth_hz=0 reaches the throttle calculation and raises ZeroDivisionError in the post-step callback. Negative, infinite, and NaN rates are also accepted, causing immediate or permanently suppressed publishing instead of the requested stream. Require a finite value strictly greater than zero during configuration validation.
Artifacts
- This authored harness extracts and runs the unchanged production post-step method with enabled ground-truth publishing and invalid rates, showing the affected execution path.
- This command capture shows zero raises ZeroDivisionError, while negative and infinity publish and NaN suppresses publication, confirming invalid values are not safely handled.
❌ 3 Tests Failed:
View the top 3 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
|
Part 2 of the #3594 split is implemented and pushed as a stacked branch on my fork: It adds the eval-side consumption of this PR's GT stream:
I'll open it as a PR once this one lands. Local verification: Note: the current |
Summary
Part 1 of 2 for #3594 (privileged ground-truth channel for interactive eval scoring).
MujocoSimModulegains an opt-in ground-truth stream:publish_ground_truth: bool = False(default off — zero overhead, zero behavior change) andground_truth_hz: float = 20.0config fieldsgt_object_poses: Out[PoseStamped]stream: world poses of every free-joint scene body, throttled,frame_id= body nameodom); resolved by matching the same root qpos addressodomuses/from MuJoCo 3.10's attached-submodel namespacing is stripped soframe_idstays a stable plain body nameGround truth is privileged scoring data — never consumed by the agent. Part 2 will add the eval-side
gt_store()accessor, a predicate library, and an xArm7 regression suite.Test plan
test_mujoco_sim_module.py: disabled-by-default publishes nothing; enabled publishes throttled poses; free-joint body resolution excludes the robot root against a real composed modelNote for part 2 consumers:
async def handle_<stream>auto-subscription uses a single-slot LATEST mailbox (module.py), so same-tick bursts overwrite; GT consumers must use directsubscribe()(asRecorderdoes).