Buckets:
| <meta charset="utf-8" /><meta name="hf:doc:metadata" content="{"title":"Policy Deployment (lerobot-rollout)","local":"policy-deployment-lerobot-rollout","sections":[{"title":"Quick Start","local":"quick-start","sections":[],"depth":2},{"title":"Strategies","local":"strategies","sections":[{"title":"Base ( --strategy.type=base )","local":"base----strategytypebase-","sections":[],"depth":3},{"title":"Sentry ( --strategy.type=sentry )","local":"sentry----strategytypesentry-","sections":[],"depth":3},{"title":"Highlight ( --strategy.type=highlight )","local":"highlight----strategytypehighlight-","sections":[],"depth":3},{"title":"DAgger ( --strategy.type=dagger )","local":"dagger----strategytypedagger-","sections":[],"depth":3},{"title":"Episodic ( --strategy.type=episodic )","local":"episodic----strategytypeepisodic-","sections":[],"depth":3}],"depth":2},{"title":"Inference Backends","local":"inference-backends","sections":[{"title":"Sync (default)","local":"sync-default","sections":[],"depth":3},{"title":"Real-Time Chunking ( --inference.type=rtc )","local":"real-time-chunking----inferencetypertc-","sections":[],"depth":3}],"depth":2},{"title":"Common Flags","local":"common-flags","sections":[],"depth":2},{"title":"Cadence Reporting","local":"cadence-reporting","sections":[],"depth":2},{"title":"Programmatic Usage","local":"programmatic-usage","sections":[],"depth":2}],"depth":1}"/> | |
| <link href="/docs/lerobot/main/en/_app/immutable/entry/start.BtqGEk2h.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/chunks/tAaxsU29.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/chunks/B6Ur1TrR.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/entry/app.C2DcaLJF.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/chunks/B0U_5Rah.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/chunks/BwNHWMUY.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/chunks/DsnmJJEf.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/chunks/CLXITcYA.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/nodes/0.CJGFM5n3.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/chunks/on1HecCW.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/nodes/4.BcjAc3ui.js" rel="modulepreload"> | |
| <link href="/docs/lerobot/main/en/_app/immutable/chunks/DVZaU7Qs.js" rel="modulepreload"> | |
| <!--br6948--><meta name="hf:doc:metadata" content="{"title":"Policy Deployment (lerobot-rollout)","local":"policy-deployment-lerobot-rollout","sections":[{"title":"Quick Start","local":"quick-start","sections":[],"depth":2},{"title":"Strategies","local":"strategies","sections":[{"title":"Base ( --strategy.type=base )","local":"base----strategytypebase-","sections":[],"depth":3},{"title":"Sentry ( --strategy.type=sentry )","local":"sentry----strategytypesentry-","sections":[],"depth":3},{"title":"Highlight ( --strategy.type=highlight )","local":"highlight----strategytypehighlight-","sections":[],"depth":3},{"title":"DAgger ( --strategy.type=dagger )","local":"dagger----strategytypedagger-","sections":[],"depth":3},{"title":"Episodic ( --strategy.type=episodic )","local":"episodic----strategytypeepisodic-","sections":[],"depth":3}],"depth":2},{"title":"Inference Backends","local":"inference-backends","sections":[{"title":"Sync (default)","local":"sync-default","sections":[],"depth":3},{"title":"Real-Time Chunking ( --inference.type=rtc )","local":"real-time-chunking----inferencetypertc-","sections":[],"depth":3}],"depth":2},{"title":"Common Flags","local":"common-flags","sections":[],"depth":2},{"title":"Cadence Reporting","local":"cadence-reporting","sections":[],"depth":2},{"title":"Programmatic Usage","local":"programmatic-usage","sections":[],"depth":2}],"depth":1}"/><!----> | |
| <link href="/docs/lerobot/main/en/_app/immutable/assets/0.tn0RQdqM.css" rel="modulepreload"> <!--[--><!--[0--><!--[--><!--[0--><!--[--><p></p> <div class="items-center shrink-0 min-w-[100px] max-sm:min-w-[50px] justify-end ml-auto flex" style="float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"><div class="inline-flex rounded-md max-sm:rounded-sm"><button class="inline-flex items-center gap-1 h-7 max-sm:h-7 px-2 max-sm:px-1.5 text-sm font-medium text-gray-800 border border-r-0 rounded-l-md max-sm:rounded-l-sm border-gray-200 bg-white hover:shadow-inner dark:border-gray-850 dark:bg-gray-950 dark:text-gray-200 dark:hover:bg-gray-800" aria-live="polite"><span class="inline-flex items-center justify-center rounded-md p-0.5 max-sm:p-0 hover:text-gray-800 dark:hover:text-gray-200"><svg class="sm:size-3.5 size-3" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----></span> <span>Copy page</span></button> <button class="inline-flex items-center justify-center w-6 max-sm:w-5 h-7 max-sm:h-7 disabled:pointer-events-none text-sm text-gray-500 hover:text-gray-700 dark:hover:text-white rounded-r-md max-sm:rounded-r-sm border border-l transition border-gray-200 bg-white hover:shadow-inner dark:border-gray-850 dark:bg-gray-950 dark:text-gray-200 dark:hover:bg-gray-800" aria-haspopup="menu" aria-expanded="false" aria-label="Open copy menu"><svg class="transition-transform text-gray-400 overflow-visible sm:size-3.5 size-3 rotate-0" width="1em" height="1em" viewBox="0 0 12 7" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M1 1L6 6L11 1" stroke="currentColor"></path></svg><!----></button></div> <!--[-1--><!--]--></div><!----> <!--[0--><h1 class="relative group"><a id="policy-deployment-lerobot-rollout" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#policy-deployment-lerobot-rollout"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Policy Deployment (lerobot-rollout)</span></h1><!--]--><!----> <p><code>lerobot-rollout</code> is the single CLI for deploying trained policies on real robots. It supports multiple execution strategies and inference backends, from quick evaluation to continuous recording and human-in-the-loop data collection.</p> <!--[1--><h2 class="relative group"><a id="quick-start" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#quick-start"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Quick Start</span></h2><!--]--><!----> <p>No extra dependencies are needed beyond your robot and policy extras.</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-bash "><!---->lerobot-rollout \ | |
| --strategy.type=base \ | |
| --policy.path=lerobot/act_koch_real \ | |
| --robot.type=koch_follower \ | |
| --robot.port=/dev/ttyACM0 \ | |
| --task=<span class="hljs-string">"pick up cube"</span> \ | |
| --duration=30<!----></pre></div><!----> <p>This runs the policy for 30 seconds with no recording.</p> <hr/> <!--[1--><h2 class="relative group"><a id="strategies" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#strategies"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Strategies</span></h2><!--]--><!----> <p>Select a strategy with <code>--strategy.type=<name></code>. Each strategy defines a different control loop with its own recording and interaction semantics.</p> <!--[2--><h3 class="relative group"><a id="base----strategytypebase-" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#base----strategytypebase-"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Base ( --strategy.type=base )</span></h3><!--]--><!----> <p>Autonomous policy execution with no data recording. Use this for quick evaluation, demos, or when you only need to observe the robot.</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-bash "><!---->lerobot-rollout \ | |
| --strategy.type=base \ | |
| --policy.path=<span class="hljs-variable">${HF_USER}</span>/my_policy \ | |
| --robot.type=so100_follower \ | |
| --robot.port=/dev/ttyACM0 \ | |
| --robot.cameras=<span class="hljs-string">"{ front: {type: opencv, index_or_path: 0, width: 640, height: 480, fps: 30}}"</span> \ | |
| --task=<span class="hljs-string">"Put lego brick into the box"</span> \ | |
| --duration=60<!----></pre></div><!----> <table><thead><tr><th>Flag</th><th>Description</th></tr></thead><tbody><tr><td><code>--duration</code></td><td>Run time in seconds (0 = infinite)</td></tr><tr><td><code>--task</code></td><td>Task description passed to the policy</td></tr><tr><td><code>--display_data</code></td><td>Stream observations/actions to Rerun for visualization</td></tr></tbody></table> <!--[2--><h3 class="relative group"><a id="sentry----strategytypesentry-" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#sentry----strategytypesentry-"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Sentry ( --strategy.type=sentry )</span></h3><!--]--><!----> <p>Continuous autonomous recording with periodic upload to the Hugging Face Hub. Episode boundaries are auto-computed from camera resolution and FPS so each saved episode produces a complete video file, keeping uploads efficient.</p> <p>Policy state (hidden state, RTC queue) persists across episode boundaries: the robot does not reset between episodes.</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-bash "><!---->lerobot-rollout \ | |
| --strategy.type=sentry \ | |
| --strategy.upload_every_n_episodes=5 \ | |
| --policy.path=<span class="hljs-variable">${HF_USER}</span>/my_policy \ | |
| --robot.type=so100_follower \ | |
| --robot.port=/dev/ttyACM0 \ | |
| --robot.cameras=<span class="hljs-string">"{ front: {type: opencv, index_or_path: 0, width: 640, height: 480, fps: 30}}"</span> \ | |
| --dataset.repo_id=<span class="hljs-variable">${HF_USER}</span>/rollout_eval_data \ | |
| --dataset.single_task=<span class="hljs-string">"Put lego brick into the box"</span> \ | |
| --duration=3600<!----></pre></div><!----> <table><thead><tr><th>Flag</th><th>Description</th></tr></thead><tbody><tr><td><code>--strategy.upload_every_n_episodes</code></td><td>Push to Hub every N episodes (default: 5)</td></tr><tr><td><code>--strategy.target_video_file_size_mb</code></td><td>Target video file size for episode rotation (default: auto)</td></tr><tr><td><code>--dataset.repo_id</code></td><td><strong>Required.</strong> Hub repository for the recorded dataset</td></tr><tr><td><code>--dataset.push_to_hub</code></td><td>Whether to push to Hub on teardown (default: true)</td></tr></tbody></table> <!--[2--><h3 class="relative group"><a id="highlight----strategytypehighlight-" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#highlight----strategytypehighlight-"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Highlight ( --strategy.type=highlight )</span></h3><!--]--><!----> <p>Autonomous rollout with on-demand recording via a memory-bounded ring buffer. The robot runs continuously while the buffer captures the last N seconds of telemetry. Press the save key to flush the buffer and start live recording; press it again to save the episode.</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-bash "><!---->lerobot-rollout \ | |
| --strategy.type=highlight \ | |
| --strategy.ring_buffer_seconds=30 \ | |
| --strategy.save_key=s \ | |
| --strategy.push_key=h \ | |
| --policy.path=<span class="hljs-variable">${HF_USER}</span>/my_policy \ | |
| --robot.type=koch_follower \ | |
| --robot.port=/dev/ttyACM0 \ | |
| --dataset.repo_id=<span class="hljs-variable">${HF_USER}</span>/rollout_highlight_data \ | |
| --dataset.single_task=<span class="hljs-string">"Pick up the red cube"</span><!----></pre></div><!----> <p><strong>Keyboard controls:</strong></p> <table><thead><tr><th>Key</th><th>Action</th></tr></thead><tbody><tr><td><code>s</code> (configurable)</td><td>Start recording (flushes buffer) / stop and save episode</td></tr><tr><td><code>h</code> (configurable)</td><td>Push dataset to Hub</td></tr><tr><td><code>ESC</code></td><td>Stop the session</td></tr></tbody></table> <table><thead><tr><th>Flag</th><th>Description</th></tr></thead><tbody><tr><td><code>--strategy.ring_buffer_seconds</code></td><td>Duration of buffered telemetry (default: 30)</td></tr><tr><td><code>--strategy.ring_buffer_max_memory_mb</code></td><td>Memory cap for the ring buffer (default: 2048)</td></tr><tr><td><code>--strategy.save_key</code></td><td>Key to toggle recording (default: <code>s</code>)</td></tr><tr><td><code>--strategy.push_key</code></td><td>Key to push to Hub (default: <code>h</code>)</td></tr></tbody></table> <!--[2--><h3 class="relative group"><a id="dagger----strategytypedagger-" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#dagger----strategytypedagger-"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>DAgger ( --strategy.type=dagger )</span></h3><!--]--><!----> <p>Human-in-the-loop data collection. Alternates between autonomous policy execution and human intervention via a teleoperator. Intervention frames are tagged with <code>intervention=True</code>. Requires a teleoperator (<code>--teleop.type</code>).</p> <p>See the <a href="./hil_data_collection">Human-In-the-Loop Data Collection</a> guide for a detailed walkthrough.</p> <p><strong>Corrections-only mode</strong> (default): Only human correction windows are recorded. Each correction becomes one episode.</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-bash "><!---->lerobot-rollout \ | |
| --strategy.type=dagger \ | |
| --strategy.num_episodes=20 \ | |
| --policy.path=outputs/pretrain/checkpoints/last/pretrained_model \ | |
| --robot.type=bi_openarm_follower \ | |
| --teleop.type=bi_openarm_mini \ | |
| --dataset.repo_id=<span class="hljs-variable">${HF_USER}</span>/rollout_hil_data \ | |
| --dataset.single_task=<span class="hljs-string">"Fold the T-shirt"</span><!----></pre></div><!----> <p><strong>Continuous recording mode</strong> (<code>--strategy.record_autonomous=true</code>): Both autonomous and correction frames are recorded with time-based episode rotation (same as Sentry).</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-bash "><!---->lerobot-rollout \ | |
| --strategy.type=dagger \ | |
| --strategy.record_autonomous=<span class="hljs-literal">true</span> \ | |
| --strategy.num_episodes=50 \ | |
| --policy.path=<span class="hljs-variable">${HF_USER}</span>/my_policy \ | |
| --robot.type=so100_follower \ | |
| --robot.port=/dev/ttyACM0 \ | |
| --teleop.type=so101_leader \ | |
| --teleop.port=/dev/ttyACM1 \ | |
| --dataset.repo_id=<span class="hljs-variable">${HF_USER}</span>/rollout_dagger_data \ | |
| --dataset.single_task=<span class="hljs-string">"Grasp the block"</span><!----></pre></div><!----> <p><strong>Keyboard controls</strong> (default input device):</p> <table><thead><tr><th>Key</th><th>Action</th></tr></thead><tbody><tr><td><code>Space</code></td><td>Pause / resume policy execution</td></tr><tr><td><code>Tab</code></td><td>Start / stop human correction</td></tr><tr><td><code>Enter</code></td><td>Push dataset to Hub (corrections-only mode)</td></tr><tr><td><code>ESC</code></td><td>Stop the session</td></tr></tbody></table> <p>Foot pedal input is also supported via <code>--strategy.input_device=pedal</code>. Configure pedal codes with <code>--strategy.pedal.*</code> flags.</p> <table><thead><tr><th>Flag</th><th>Description</th></tr></thead><tbody><tr><td><code>--strategy.num_episodes</code></td><td>Number of correction episodes to record (default: 10)</td></tr><tr><td><code>--strategy.record_autonomous</code></td><td>Record autonomous frames too (default: false)</td></tr><tr><td><code>--strategy.upload_every_n_episodes</code></td><td>Push to Hub every N episodes (default: 5)</td></tr><tr><td><code>--strategy.input_device</code></td><td>Input device: <code>keyboard</code> or <code>pedal</code> (default: keyboard)</td></tr><tr><td><code>--strategy.smooth_handover</code></td><td>Smoothly hand control over at pause / correction start (default: true). Disable for clutch-style teleops that re-reference at the current robot pose on engage</td></tr><tr><td><code>--teleop.type</code></td><td><strong>Required.</strong> Teleoperator type</td></tr></tbody></table> <!--[2--><h3 class="relative group"><a id="episodic----strategytypeepisodic-" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#episodic----strategytypeepisodic-"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Episodic ( --strategy.type=episodic )</span></h3><!--]--><!----> <p>Episode-oriented recording that mirrors the behavior of <code>lerobot-record</code>. The policy drives the robot for each episode; an optional teleoperator can drive the robot during the reset phase between episodes.</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-bash "><!---->lerobot-rollout \ | |
| --strategy.type=episodic \ | |
| --policy.path=<span class="hljs-variable">${HF_USER}</span>/my_policy \ | |
| --robot.type=so100_follower \ | |
| --robot.port=/dev/ttyACM0 \ | |
| --teleop.type=so100_leader \ | |
| --teleop.port=/dev/ttyACM1 \ | |
| --dataset.repo_id=<span class="hljs-variable">${HF_USER}</span>/my_eval_data \ | |
| --dataset.num_episodes=20 \ | |
| --dataset.episode_time_s=30 \ | |
| --dataset.reset_time_s=10 \ | |
| --dataset.single_task=<span class="hljs-string">"Pick up the red cube"</span><!----></pre></div><!----> <p>Teleop is optional — if omitted the robot holds its position during the reset phase.</p> <p><strong>Keyboard controls:</strong></p> <table><thead><tr><th>Key</th><th>Action</th></tr></thead><tbody><tr><td><code>→</code> (right)</td><td>End the current episode early</td></tr><tr><td><code>←</code> (left)</td><td>Discard episode and re-record it</td></tr><tr><td><code>ESC</code></td><td>Stop the recording session</td></tr></tbody></table> <table><thead><tr><th>Flag</th><th>Description</th></tr></thead><tbody><tr><td><code>--dataset.num_episodes</code></td><td>Number of episodes to record</td></tr><tr><td><code>--dataset.episode_time_s</code></td><td>Duration of each recording episode in seconds</td></tr><tr><td><code>--dataset.reset_time_s</code></td><td>Duration of the reset phase between episodes in seconds</td></tr><tr><td><code>--teleop.type</code></td><td>Optional. Teleoperator to drive the robot during resets</td></tr><tr><td><code>--strategy.reset_to_initial_position</code></td><td>Whether to reset the robot to its initial position between episodes</td></tr><tr><td><code>--strategy.smooth_leader_to_follower_handover</code></td><td>Whether to turn on or off the leader -> follower smooth handover behavior.</td></tr><tr><td><code>--strategy.smooth_handover</code></td><td>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</td></tr></tbody></table> <hr/> <!--[1--><h2 class="relative group"><a id="inference-backends" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#inference-backends"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Inference Backends</span></h2><!--]--><!----> <p>Select a backend with <code>--inference.type=<name></code>. All strategies work with both backends.</p> <!--[2--><h3 class="relative group"><a id="sync-default" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#sync-default"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Sync (default)</span></h3><!--]--><!----> <p>One policy call per control tick. The main loop blocks until the action is computed.</p> <p>Works with all policies. No extra flags needed.</p> <!--[2--><h3 class="relative group"><a id="real-time-chunking----inferencetypertc-" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#real-time-chunking----inferencetypertc-"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Real-Time Chunking ( --inference.type=rtc )</span></h3><!--]--><!----> <p>A background thread produces action chunks asynchronously. The main control loop polls for the next ready action while the policy computes the next chunk in parallel.</p> <p>Use RTC with large, slow VLA models (Pi0, Pi0.5, SmolVLA) for smooth, continuous motion despite high inference latency.</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-bash "><!---->lerobot-rollout \ | |
| --strategy.type=base \ | |
| --inference.type=rtc \ | |
| --inference.rtc.execution_horizon=10 \ | |
| --inference.rtc.max_guidance_weight=10.0 \ | |
| --policy.path=<span class="hljs-variable">${HF_USER}</span>/pi0_policy \ | |
| --robot.type=so100_follower \ | |
| --robot.port=/dev/ttyACM0 \ | |
| --robot.cameras=<span class="hljs-string">"{ front: {type: opencv, index_or_path: 0, width: 640, height: 480, fps: 30}}"</span> \ | |
| --task=<span class="hljs-string">"Pick up the cube"</span> \ | |
| --duration=60 \ | |
| --device=cuda<!----></pre></div><!----> <table><thead><tr><th>Flag</th><th>Description</th></tr></thead><tbody><tr><td><code>--inference.rtc.execution_horizon</code></td><td>Steps to blend with previous chunk (default: varies by policy)</td></tr><tr><td><code>--inference.rtc.max_guidance_weight</code></td><td>Consistency enforcement strength (default: varies by policy)</td></tr><tr><td><code>--inference.rtc.prefix_attention_schedule</code></td><td>Blend schedule: <code>LINEAR</code>, <code>EXP</code>, <code>ONES</code>, <code>ZEROS</code></td></tr><tr><td><code>--inference.queue_threshold</code></td><td>Max queue size before backpressure (default: 30)</td></tr></tbody></table> <p>See the <a href="./rtc">Real-Time Chunking</a> guide for details on tuning RTC parameters.</p> <hr/> <!--[1--><h2 class="relative group"><a id="common-flags" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#common-flags"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Common Flags</span></h2><!--]--><!----> <table><thead><tr><th>Flag</th><th>Description</th><th>Default</th></tr></thead><tbody><tr><td><code>--policy.path</code></td><td><strong>Required.</strong> HF Hub model ID or local checkpoint path</td><td>—</td></tr><tr><td><code>--robot.type</code></td><td><strong>Required.</strong> Robot type (e.g. <code>so100_follower</code>, <code>koch_follower</code>)</td><td>—</td></tr><tr><td><code>--robot.port</code></td><td>Serial port for the robot</td><td>—</td></tr><tr><td><code>--robot.cameras</code></td><td>Camera configuration (JSON dict)</td><td>—</td></tr><tr><td><code>--fps</code></td><td>Policy inference and dataset recording frequency</td><td>30</td></tr><tr><td><code>--duration</code></td><td>Run time in seconds (0 = infinite)</td><td>0</td></tr><tr><td><code>--device</code></td><td>Torch device (<code>cpu</code>, <code>cuda</code>, <code>mps</code>)</td><td>auto</td></tr><tr><td><code>--task</code></td><td>Task description (used when no dataset is provided)</td><td>—</td></tr><tr><td><code>--display_data</code></td><td>Stream telemetry to Rerun visualization</td><td>false</td></tr><tr><td><code>--display_ip</code> / <code>--display_port</code></td><td>Remote Rerun server address</td><td>—</td></tr><tr><td><code>--interpolation_multiplier</code></td><td>Robot commands per policy action (control at <code>fps × N</code> Hz)</td><td>1</td></tr><tr><td><code>--use_torch_compile</code></td><td>Enable <code>torch.compile</code> for inference</td><td>false</td></tr><tr><td><code>--resume</code></td><td>Resume a previous recording session</td><td>false</td></tr><tr><td><code>--play_sounds</code></td><td>Vocal synthesis for events</td><td>true</td></tr></tbody></table> <hr/> <!--[1--><h2 class="relative group"><a id="cadence-reporting" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#cadence-reporting"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Cadence Reporting</span></h2><!--]--><!----> <p>Every strategy reports what its control loop actually achieved, as do <code>lerobot-record</code>, <code>lerobot-teleoperate</code> and <code>lerobot-replay</code> — they all pace through the same timer. Each saved episode gets a one-line digest, and when the loop ends — including on <code>Ctrl-C</code> — a block covering the whole run:</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class=" "><!----><span class="hljs-attribute">Cadence</span> (episode <span class="hljs-number">1</span>): <span class="hljs-number">29</span>.<span class="hljs-number">84</span> Hz policy vs <span class="hljs-number">30</span> Hz target · <span class="hljs-number">1200</span> ticks, <span class="hljs-number">20</span>.<span class="hljs-number">1</span> s measured · <span class="hljs-number">6</span>/<span class="hljs-number">598</span> cycles over the <span class="hljs-number">33</span>.<span class="hljs-number">3</span> ms budget (work mean <span class="hljs-number">18</span>.<span class="hljs-number">7</span> ms, worst <span class="hljs-number">48</span>.<span class="hljs-number">1</span> ms) | |
| <span class="hljs-attribute">Cadence</span> (episode <span class="hljs-number">2</span>): <span class="hljs-number">29</span>.<span class="hljs-number">84</span> Hz policy vs <span class="hljs-number">30</span> Hz target · <span class="hljs-number">1200</span> ticks, <span class="hljs-number">20</span>.<span class="hljs-number">1</span> s measured · <span class="hljs-number">6</span>/<span class="hljs-number">599</span> cycles over the <span class="hljs-number">33</span>.<span class="hljs-number">3</span> ms budget (work mean <span class="hljs-number">18</span>.<span class="hljs-number">7</span> ms, worst <span class="hljs-number">48</span>.<span class="hljs-number">1</span> ms) | |
| <span class="hljs-attribute">Cadence</span> summary — whole run, <span class="hljs-number">2</span> episodes · target <span class="hljs-number">30</span> Hz × <span class="hljs-number">2</span> (<span class="hljs-number">16</span>.<span class="hljs-number">7</span> ms tick slot, <span class="hljs-number">33</span>.<span class="hljs-number">3</span> ms cycle budget): <span class="hljs-number">2400</span> ticks, <span class="hljs-number">1197</span> cycles judged | |
| <span class="hljs-attribute">effective</span> cadence: <span class="hljs-number">29</span>.<span class="hljs-number">84</span> Hz policy / <span class="hljs-number">59</span>.<span class="hljs-number">67</span> Hz commands over <span class="hljs-number">40</span>.<span class="hljs-number">2</span> s measured | |
| <span class="hljs-attribute">cycles</span> over the <span class="hljs-number">33</span>.<span class="hljs-number">3</span> ms work budget: <span class="hljs-number">12</span>/<span class="hljs-number">1197</span> (<span class="hljs-number">1</span>.<span class="hljs-number">0</span>%) — work mean <span class="hljs-number">18</span>.<span class="hljs-number">7</span> ms, worst <span class="hljs-number">48</span>.<span class="hljs-number">1</span> ms | |
| <span class="hljs-attribute">ticks</span> over their <span class="hljs-number">16</span>.<span class="hljs-number">7</span> ms slot: <span class="hljs-number">40</span>/<span class="hljs-number">2400</span> (costs interpolation smoothness only) | |
| <span class="hljs-attribute">loop</span>-body steps (share of measured work): | |
| <span class="hljs-attribute">observe</span> mean <span class="hljs-number">3</span>.<span class="hljs-number">13</span> ms · worst <span class="hljs-number">9</span>.<span class="hljs-number">00</span> ms · <span class="hljs-number">31</span>.<span class="hljs-number">7</span>% of work · <span class="hljs-number">2400</span> calls | |
| <span class="hljs-attribute">process_obs</span> mean <span class="hljs-number">0</span>.<span class="hljs-number">50</span> ms · worst <span class="hljs-number">1</span>.<span class="hljs-number">00</span> ms · <span class="hljs-number">5</span>.<span class="hljs-number">1</span>% of work · <span class="hljs-number">2400</span> calls | |
| <span class="hljs-attribute">infer</span> mean <span class="hljs-number">5</span>.<span class="hljs-number">18</span> ms · worst <span class="hljs-number">40</span>.<span class="hljs-number">00</span> ms · <span class="hljs-number">52</span>.<span class="hljs-number">4</span>% of work · <span class="hljs-number">2400</span> calls | |
| <span class="hljs-attribute">send</span> mean <span class="hljs-number">0</span>.<span class="hljs-number">40</span> ms · worst <span class="hljs-number">0</span>.<span class="hljs-number">40</span> ms · <span class="hljs-number">4</span>.<span class="hljs-number">1</span>% of work · <span class="hljs-number">2400</span> calls | |
| <span class="hljs-attribute">record</span> mean <span class="hljs-number">0</span>.<span class="hljs-number">67</span> ms · worst <span class="hljs-number">620</span>.<span class="hljs-number">00</span> ms · <span class="hljs-number">6</span>.<span class="hljs-number">8</span>% of work · <span class="hljs-number">2402</span> calls | |
| <span class="hljs-attribute">pacing</span> headroom: <span class="hljs-number">7</span>.<span class="hljs-number">4</span> ms slept per tick <span class="hljs-literal">on</span> average (max <span class="hljs-number">13</span>.<span class="hljs-number">0</span> ms) — near zero means the loop is saturated<!----></pre></div><!----> <p>Read it top-down: <strong>effective cadence</strong> is what you got against <code>--fps</code>, <strong>cycles over budget</strong> is how often the loop could not hold it, the <strong>step breakdown</strong> says where the time went, and <strong>pacing headroom</strong> near zero means there is nothing left to absorb a slow tick. A high <code>infer</code> share points at the policy or the device; a high <code>observe</code> share points at the cameras. A step’s <code>worst</code> far above its <code>mean</code> is a one-off — above, <code>record</code> is 0.67 ms per frame and the 620 ms outlier is the blocking <code>save_episode</code> that closed an episode.</p> <p>A <em>cycle</em> here is one policy action’s worth of ticks (<code>--interpolation_multiplier</code> of them). Only whole cycles over the <code>1/fps</code> budget can cost you frames; a single tick overrunning its slot only makes the interpolated motion less smooth, which is why the two are counted separately. Without interpolation a cycle is a single tick, so the report drops the distinction and counts ticks throughout.</p> <hr/> <!--[1--><h2 class="relative group"><a id="programmatic-usage" class="header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full" href="#programmatic-usage"><span><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 256"><path d="M167.594 88.393a8.001 8.001 0 0 1 0 11.314l-67.882 67.882a8 8 0 1 1-11.314-11.315l67.882-67.881a8.003 8.003 0 0 1 11.314 0zm-28.287 84.86l-28.284 28.284a40 40 0 0 1-56.567-56.567l28.284-28.284a8 8 0 0 0-11.315-11.315l-28.284 28.284a56 56 0 0 0 79.196 79.197l28.285-28.285a8 8 0 1 0-11.315-11.314zM212.852 43.14a56.002 56.002 0 0 0-79.196 0l-28.284 28.284a8 8 0 1 0 11.314 11.314l28.284-28.284a40 40 0 0 1 56.568 56.567l-28.285 28.285a8 8 0 0 0 11.315 11.314l28.284-28.284a56.065 56.065 0 0 0 0-79.196z" fill="currentColor"></path></svg><!----></span></a> <span>Programmatic Usage</span></h2><!--]--><!----> <p>For custom deployments (e.g. with kinematics processors), use the rollout module API directly:</p> <div class="code-block relative "><div class="absolute top-2.5 right-4"><button class="inline-flex items-center relative text-sm focus:text-green-500 cursor-pointer focus:outline-none transition duration-200 ease-in-out opacity-0 mx-0.5 text-gray-600 " title="code excerpt" type="button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z" transform="translate(0)"></path><path d="M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z" transform="translate(0)"></path><rect fill="none" width="32" height="32"></rect></svg><!----> <div class=" absolute pointer-events-none transition-opacity bg-black text-white py-1 px-2 leading-tight rounded font-normal shadow left-1/2 top-full transform -translate-x-1/2 translate-y-2 opacity-0 "><div class="absolute bottom-full left-1/2 transform -translate-x-1/2 w-0 h-0 border-black border-4 border-t-0" style="border-left-color: transparent; border-right-color: transparent;"></div> Copied</div><!----></button><!----></div> <pre class="language-python "><!----><span class="hljs-keyword">from</span> lerobot.rollout <span class="hljs-keyword">import</span> BaseStrategyConfig, RolloutConfig, build_rollout_context | |
| <span class="hljs-keyword">from</span> lerobot.rollout.inference <span class="hljs-keyword">import</span> SyncInferenceConfig | |
| <span class="hljs-keyword">from</span> lerobot.rollout.strategies <span class="hljs-keyword">import</span> BaseStrategy | |
| <span class="hljs-keyword">from</span> lerobot.utils.process <span class="hljs-keyword">import</span> ProcessSignalHandler | |
| cfg = RolloutConfig( | |
| robot=my_robot_config, | |
| policy=my_policy_config, | |
| strategy=BaseStrategyConfig(), | |
| inference=SyncInferenceConfig(), | |
| fps=<span class="hljs-number">30</span>, | |
| duration=<span class="hljs-number">60</span>, | |
| task=<span class="hljs-string">"my task"</span>, | |
| ) | |
| signal_handler = ProcessSignalHandler(use_threads=<span class="hljs-literal">True</span>) | |
| ctx = build_rollout_context( | |
| cfg, | |
| signal_handler.shutdown_event, | |
| robot_action_processor=my_custom_action_processor, <span class="hljs-comment"># optional</span> | |
| robot_observation_processor=my_custom_obs_processor, <span class="hljs-comment"># optional</span> | |
| ) | |
| strategy = BaseStrategy(cfg.strategy) | |
| <span class="hljs-keyword">try</span>: | |
| strategy.setup(ctx) | |
| strategy.run(ctx) | |
| <span class="hljs-keyword">finally</span>: | |
| strategy.teardown(ctx)<!----></pre></div><!----> <p>See <code>examples/so100_to_so100_EE/rollout.py</code> and <code>examples/phone_to_so100/rollout.py</code> for full examples with kinematics processors.</p> <a class="!text-gray-400 !no-underline text-sm flex items-center not-prose mt-4" href="https://github.com/huggingface/lerobot/blob/main/docs/source/inference.mdx" target="_blank"><svg class="mr-1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" fill="currentColor" focusable="false" role="img" width="1em" height="1em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 32 32"><path d="M31,16l-7,7l-1.41-1.41L28.17,16l-5.58-5.59L24,9l7,7z"></path><path d="M1,16l7-7l1.41,1.41L3.83,16l5.58,5.59L8,23l-7-7z"></path><path d="M12.419,25.484L17.639,6.552l1.932,0.518L14.351,26.002z"></path></svg><!----> <span><span class="underline">Update</span> on GitHub</span></a><!----> <p></p><!--]--><!----><!--]--><!--]--><!--]--> <!--[-1--><!--]--><!--]--> | |
| <script> | |
| { | |
| __sveltekit_kifkyj = { | |
| base: "/docs/lerobot/main/en", | |
| assets: "/docs/lerobot/main/en" | |
| }; | |
| const element = document.currentScript.parentElement; | |
| Promise.all([ | |
| import("/docs/lerobot/main/en/_app/immutable/entry/start.BtqGEk2h.js"), | |
| import("/docs/lerobot/main/en/_app/immutable/entry/app.C2DcaLJF.js") | |
| ]).then(([kit, app]) => { | |
| kit.start(app, element, { | |
| node_ids: [0, 4], | |
| data: [null,null], | |
| form: null, | |
| error: null | |
| }); | |
| }); | |
| } | |
| </script> | |
Xet Storage Details
- Size:
- 58.8 kB
- Xet hash:
- 8015783698dc9a2a48b67ffbd822325c66a1cb420dd5106c1d65af2fbb7443e6
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.