Commit a6cacd0
committed
fix(mjlab): go1 Newton can finally stand (PD actuators + init pose + action order)
Three stacked bugs kept go1 collapsed on the Newton path (so 'go1 walks'
was never real):
- go1.xml has NO <actuator> elements (mjlab adds them at runtime). The Newton
RobotCfg path loaded the raw XML -> mj nu=0 -> zero position-control torque
-> free-fall. Now patch_mjcf_with_pd_actuators(go1.xml, GO1_KP) on the Newton
path too (nu=12), matching the mujoco scene path.
- init height 0.42 -> 0.278 (mjlab INIT_STATE) + hip 0.0 -> ±0.1 (R/L).
- action target was emitted in cfg joint order but Newton applies tensor
actions in get_joint_names(sort=True) order -> PD targets scrambled to wrong
joints. Reorder cfg->sorted in _apply_action.
Verified: go1 holds z~0.30 stable under zero action (was collapsing to 0.05);
12/12 mujoco + 12/12 Newton smoke still passes (no regression). Depends on the
MetaSim bare-joint-name alias fix. Retraining in progress to verify walking.1 parent 9b943a3 commit a6cacd0
2 files changed
Lines changed: 47 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
37 | 45 | | |
38 | 46 | | |
39 | 47 | | |
| |||
72 | 80 | | |
73 | 81 | | |
74 | 82 | | |
75 | | - | |
| 83 | + | |
76 | 84 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
| |||
491 | 492 | | |
492 | 493 | | |
493 | 494 | | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
494 | 512 | | |
495 | 513 | | |
496 | 514 | | |
| |||
643 | 661 | | |
644 | 662 | | |
645 | 663 | | |
646 | | - | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
| 674 | + | |
| 675 | + | |
647 | 676 | | |
648 | 677 | | |
649 | 678 | | |
| |||
0 commit comments