From 53172873e37b02c984ec81c22e19130c00efeabd Mon Sep 17 00:00:00 2001 From: Pepijn Date: Tue, 12 May 2026 18:21:58 +0200 Subject: [PATCH] chore(smolvla2-runtime): probe obs once at dry-run startup MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The dry-run REPL only fires a tick when the user types, so the ``_log_obs_tensors_once`` diagnostic never reached stdout (the provider was never called). Probe the provider once at startup — the result is discarded; we only care about the obs log it triggers. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/lerobot/scripts/lerobot_smolvla2_runtime.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/lerobot/scripts/lerobot_smolvla2_runtime.py b/src/lerobot/scripts/lerobot_smolvla2_runtime.py index 84d7a9d00..8923fa5f4 100644 --- a/src/lerobot/scripts/lerobot_smolvla2_runtime.py +++ b/src/lerobot/scripts/lerobot_smolvla2_runtime.py @@ -1318,6 +1318,15 @@ def main(argv: list[str] | None = None) -> int: initial_task=args.task, max_ticks=args.max_ticks, ) + # Fire the observation provider once at startup so the + # ``_log_obs_tensors_once`` diagnostic prints before the REPL + # blocks on stdin. The REPL otherwise only ticks on user input — + # useful for the train/inference tensor-comparison workflow. + if observation_provider is not None: + try: + _ = observation_provider() + except Exception as exc: # noqa: BLE001 + logger.warning("startup obs probe failed: %s", exc) return _run_repl(runtime, initial_task=args.task, max_ticks=args.max_ticks)