mirror of
https://github.com/huggingface/lerobot.git
synced 2026-07-25 02:36:11 +00:00
@@ -1108,6 +1108,7 @@ class PlannerController(StandingEncoderDecoder):
|
|||||||
|
|
||||||
# ── Keyboard ──────────────────────────────────────────────────────────────────
|
# ── Keyboard ──────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
|
|
||||||
class RawKeyboard:
|
class RawKeyboard:
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.fd = sys.stdin.fileno()
|
self.fd = sys.stdin.fileno()
|
||||||
|
|||||||
@@ -103,9 +103,7 @@ class PicoHeadset(Teleoperator):
|
|||||||
if not self._stream.has_data or self._stream.is_stale:
|
if not self._stream.has_data or self._stream.is_stale:
|
||||||
return {}
|
return {}
|
||||||
action = {f"{SMPL_ACTION_PREFIX}{i}": float(v) for i, v in enumerate(window)}
|
action = {f"{SMPL_ACTION_PREFIX}{i}": float(v) for i, v in enumerate(window)}
|
||||||
action.update(
|
action.update({f"{ROOT_ACTION_PREFIX}{i}": float(v) for i, v in enumerate(self._stream.root_quat)})
|
||||||
{f"{ROOT_ACTION_PREFIX}{i}": float(v) for i, v in enumerate(self._stream.root_quat)}
|
|
||||||
)
|
|
||||||
return action
|
return action
|
||||||
|
|
||||||
def send_feedback(self, feedback: dict[str, Any]) -> None:
|
def send_feedback(self, feedback: dict[str, Any]) -> None:
|
||||||
|
|||||||
@@ -117,9 +117,7 @@ def main() -> None:
|
|||||||
p.add_argument("--skeleton", type=str, default=None, help="Path to smpl_skeleton.npz")
|
p.add_argument("--skeleton", type=str, default=None, help="Path to smpl_skeleton.npz")
|
||||||
src = p.add_mutually_exclusive_group()
|
src = p.add_mutually_exclusive_group()
|
||||||
src.add_argument("--fake", action="store_true", help="Publish synthetic motion (no headset)")
|
src.add_argument("--fake", action="store_true", help="Publish synthetic motion (no headset)")
|
||||||
src.add_argument(
|
src.add_argument("--motion-file", type=str, default=None, help="Replay an SMPL .npz clip over rt/smpl")
|
||||||
"--motion-file", type=str, default=None, help="Replay an SMPL .npz clip over rt/smpl"
|
|
||||||
)
|
|
||||||
p.add_argument("--no-loop", action="store_true", help="Play a --motion-file once, then stop")
|
p.add_argument("--no-loop", action="store_true", help="Play a --motion-file once, then stop")
|
||||||
args = p.parse_args()
|
args = p.parse_args()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user