feat(rollout): add smooth_handover flag to episodic strategy config

Follow-up to #3985, which added the same flag to the DAgger strategy.

The episodic strategy's reset-phase handover had two gaps:
- Non-actuated teleops could not skip the blocking follower slide at all.
- Setting smooth_leader_to_follower_handover=false on an actuated teleop
  swapped which arm moves instead of skipping the handover.

Add --strategy.smooth_handover (default true, existing behavior
unchanged) as a master switch that skips the interpolation entirely,
for clutch-style teleops that re-reference at the current robot pose
on engage.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
griffinaddison
2026-07-23 09:36:11 -07:00
committed by Maxime Ellerbach
parent 0d383d09f2
commit 360e619e18
3 changed files with 29 additions and 15 deletions
+1
View File
@@ -194,6 +194,7 @@ Teleop is optional — if omitted the robot holds its position during the reset
| `--teleop.type` | Optional. Teleoperator to drive the robot during resets | | `--teleop.type` | Optional. Teleoperator to drive the robot during resets |
| `--strategy.reset_to_initial_position` | Whether to reset the robot to its initial position between episodes | | `--strategy.reset_to_initial_position` | Whether to reset the robot to its initial position between episodes |
| `--strategy.smooth_leader_to_follower_handover` | Whether to turn on or off the leader -> follower smooth handover behavior. | | `--strategy.smooth_leader_to_follower_handover` | Whether to turn on or off the leader -> follower smooth handover behavior. |
| `--strategy.smooth_handover` | Smoothly hand control to the teleop at reset start (default: true). Disable for clutch-style teleops that re-reference at the current robot pose on engage |
--- ---
+9
View File
@@ -149,6 +149,15 @@ class EpisodicStrategyConfig(RolloutStrategyConfig):
# Note that leader -> follower handover is only supported when the leader has `send_feedback` capability. # Note that leader -> follower handover is only supported when the leader has `send_feedback` capability.
smooth_leader_to_follower_handover: bool = True smooth_leader_to_follower_handover: bool = True
# Whether to turn on or off the smooth handover behavior at the start of the
# reset phase: the leader is driven to the follower position (actuated
# teleops, see `smooth_leader_to_follower_handover`), or the follower is
# slid to the teleop pose (non-actuated teleops). Disable for clutch-style
# teleoperators (e.g. VR controllers) that re-reference at the current robot
# pose on engage: the handover is already continuous there, and the blocking
# interpolation only delays the start of the reset phase.
smooth_handover: bool = True
@RolloutStrategyConfig.register_subclass("dagger") @RolloutStrategyConfig.register_subclass("dagger")
@dataclass @dataclass
@@ -143,6 +143,10 @@ class EpisodicStrategy(RolloutStrategy):
# position so the operator takes over without fighting the arm. # position so the operator takes over without fighting the arm.
# For non-actuated teleops: slide the follower to the teleop's current # For non-actuated teleops: slide the follower to the teleop's current
# pose instead, since the leader cannot be driven. # pose instead, since the leader cannot be driven.
# Disabled entirely with --strategy.smooth_handover=false (useful for
# clutch-style teleops that re-reference at the current robot pose on
# engage).
if self.config.smooth_handover:
obs = robot.get_observation() obs = robot.get_observation()
current_pos = {k: v for k, v in obs.items() if k.endswith(".pos")} current_pos = {k: v for k, v in obs.items() if k.endswith(".pos")}
if ( if (