Recalibrate the grasp point and camera for reliable top grasps
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
+2
-2
@@ -49,8 +49,8 @@ cup = lambda x, y, top=-260.0: {"name": "cup", "colour": "grey", "x": float(x),
|
||||
reach = lambda o: skills.reachable_pick(o, accept=fetch._carry_ok)
|
||||
trusted = lambda o: skills.reachable_pick(o, accept=fetch._carry_ok, max_yaw=skills.TRUSTED_YAW_DEG) # fetch's first try
|
||||
|
||||
plan = reach(cup(-96, 598)) # picked live 2026-10-2x 15:39 (J5 +20, no turn): now
|
||||
assert plan and round(skills.yaw_of(plan[0][1][1])) == -15, plan # no IK at the grasp unturned there; -15 is trusted
|
||||
plan = reach(cup(-96, 598)) # picked live 2026-10-2x 15:39 (J5 +20, no turn): planned
|
||||
assert plan and round(skills.yaw_of(plan[0][1][1])) == 0, plan # unturned, J5 +22
|
||||
for xy in ((-171, 697), (-395, 629), (-480, 652)): # refused live from where it stood: still out of reach
|
||||
assert reach(cup(*xy)) is None, xy # of the arm alone at waist 0 (base moved then)
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ head_cam.head_centre = lambda: np.array([-92.97, -19.87, 356.12]) # the head's
|
||||
|
||||
cup = {"name": "cup", "colour": "white", "x": -126.5, "y": 613.0, "top_mm": -261.0, "width_mm": 72.0}
|
||||
R = calib.rpy_matrix(*skills.GRASP_RPY)
|
||||
g = np.array([cup["x"], cup["y"], cup["top_mm"] - 40])
|
||||
g = np.array([cup["x"], cup["y"], cup["top_mm"] - skills.BELOW_RIM_MM])
|
||||
|
||||
(n1, above), (n2, grasp), (n3, lift) = skills.plan_pick(cup)
|
||||
assert np.allclose(grasp[:3], g - R @ skills.GRASP_OFFSET) and grasp[3:] == list(skills.GRASP_RPY)
|
||||
|
||||
Reference in New Issue
Block a user