fix(wuji_hand): finger mid-segments never collided with objects; capsules -> visual-mesh hulls

#13
by Everloom - opened
SomaStacks Inc org

Teleop shows fingers sinking INTO objects at sharp edges/corners, on both hands, multiple
angles. Two defects in the Wuji hand fragment, present identically in tianji_wuji.xml and
openarm_wuji.xml:

  1. ALL twelve link2 collision geoms per robot (5 proximal-middle capsules + the thumb
    softbody pad, x2 hands) were authored contype="2" conaffinity="2". Objects are 1/1, and
    (2&1)|(2&1)=0 -- the finger mid-segments and thumb pad collided with NOTHING in the
    world. Pressing with those segments passed straight through geometry. (The mask's
    apparent intent was to keep link2 off the palm; the object pass-through came with it.)

  2. The link2/link3 collision proxies were capsules inset 3.6-5.6 mm from the visual
    meshes (30% of link2 visual vertices outside the capsule), so even the colliding
    segments contacted late and slid off sharp features.

Fix, per hand and finger:

  • link2/link3 capsule -> convex hull of the link's own visual mesh (same mesh asset, body
    frame, rgba kept), contype/conaffinity 1/1
  • thumb softbody pad mesh: mask 2/2 -> 1/1
  • openarm only: 10 explicit pairs palm_link<->finger*_link2 appended to the
    existing block -- on this hand the palm hull wraps the knuckles (4.6-12.6 mm
    rest-pose overlap), which is what the old mask was hiding; tianji's palm is clear
    (0 overlap measured at rest and at 90% curl) and needs no excludes.

Every finger body has an explicit , so masses/inertias are unchanged; nq/nv
unchanged (recorded demo state buffers still fit).

Validation (MuJoCo 3.8.0, raw load AND composed metasim scene):

  • rest pose (teleop hard-zero) and 90%-curled pose: 0 penetrating self-pairs on both robots
  • 1000-step zero-ctrl stability: |qvel|max 0.02-0.03, all finite
  • visual-vs-collision inset on link2/link3: 3.6-5.6 mm -> 0.00 mm
  • step cost (bare robot): tianji 0.087 -> 0.125 ms, openarm ~0.11 ms
  • grasp regression re-simulating recorded PD torques across 6 tasks x 2 demos: worst
    hand<->object penetration improves in 12/12 cases (e.g. grasp_apple -10.4 -> -3.5 mm),
    no object leaves the table
  • composed-scene deep-contact set is a strict subset of the original's (the remaining
    pairs are the openarm layout's pre-existing rest-hands-on-desk overlap)

Caveat: demos recorded before this change embedded the non-colliding mid-segments inside
object volumes (measured up to 14 mm in an open_cabinet_12 take); state-replay verification
is unaffected, but open-loop torque re-simulation of old takes starts interpenetrated and
depenetrates in the first frames. Live teleop is the intended acceptance test.

tianji_wuji.xml base includes the fused-hand visual graft already on main; the diff is
collision-only.

Everloom changed pull request status to merged

Sign up or log in to comment