Repository navigation
Move the teleop scripts into isaaclab_teleop.entrypoints - #8845
Conversation
teleop_se3_agent.py, record_demos.py and teleop_replay_agent.py become isaaclab_teleop.entrypoints modules with run_*_cli(argv) functions, following isaaclab_rl.entrypoints. The scripts keep their paths as thin wrappers, so documented commands, the wheel staging and "isaaclab teleop" keep working. Function bodies are unchanged; the import-time argument parsing becomes _parse_args(argv). record_demos no longer requires isaaclab_mimic: Mimic task variants register when it is installed, and the instruction display, which only record_demos used, moves from isaaclab_mimic.ui into the entrypoints package. Without Kit the display has no labels and shows nothing, replacing the SimpleNamespace stand-ins. Signed-off-by: Rafael Wiltz <rwiltz@nvidia.com>
[Medium impact] The PR appears safe to merge; the remaining test coverage suggestion is non-blocking. Findings
SummaryMoves the teleoperation, recording, and capture-replay scripts into
Diagram%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Existing script path] --> B[Public run_*_cli function]
B --> C[Load installed downstream tasks]
C --> D[Parse arguments]
D --> E[Run main]
E --> F[Restore caller arguments]
Reviews (2) · Last reviewed commit: "Test that the teleop entrypoints load ou..." · Reviewed by Greptile |
The teleop scripts resolved tasks before any installed downstream project was imported, and "isaaclab teleop" runs them in a separate process, so tasks registered through the isaaclab.tasks entry point were not found. Each run_*_cli now calls load_external_tasks() first, as the RL entrypoints do. Signed-off-by: Rafael Wiltz <rwiltz@nvidia.com>
Signed-off-by: Rafael Wiltz <rwiltz@nvidia.com>
|
run-ci |
There was a problem hiding this comment.
Isaac Lab Review Bot
Needs attention: Design and architecture (1), API (1), Compatibility and deprecation (1), Implementation (1), Style consistency (1). Other reviewed categories look good.
- PR description: Replace the inaccurate rename and unchanged-body claims with external-task and optional-Mimic changes, document license provenance, and list focused wrapper, argv, and Mimic-present/absent validation.
- Design and architecture: Documented direct entrypoint calls skip the wrappers’ Warp bootstrap, allowing imported kernels to enable unnecessary adjoint generation; configure Warp before implementation imports.
- Scope and over-engineering: No over-engineering issues.
- API: The three public run functions do not document argv ownership, None behavior, or integer results; add complete Google-style Args and Returns sections.
- Compatibility and deprecation: Breaking changes: isaaclab_mimic.ui.instruction_display is removed without a functional deprecated forwarding module, targeted warning, migration guidance, removal schedule, or transition coverage.
- Implementation: All three entrypoint modules eagerly import undeclared isaaclab_tasks, so lazy API access fails without that cyclic dependency; move task-specific imports into execution paths.
- Style consistency: Replay docstrings reference helpers under the obsolete scripts.tools.record_demos location; update them to isaaclab_teleop.entrypoints.record_demos.
- Test quality: Test quality looks good.
Significant concerns. Posted 5 inline findings.
Automated review; human maintainers own approval decisions.
isaaclab teleop run and record now call the isaaclab_teleop entrypoints directly, like isaaclab train, instead of launching the scripts under scripts/. replay still runs scripts/tools/replay_demos.py. Signed-off-by: Rafael Wiltz <rwiltz@nvidia.com>
Disable Warp backward codegen when the entrypoints package is imported, so direct callers get it too; document the run_*_cli argv and return contracts; point the replay agent's docstrings at the new record_demos module; extend the entrypoint test. Signed-off-by: Rafael Wiltz <rwiltz@nvidia.com>
|
run-ci |
AntoineRichard
left a comment
There was a problem hiding this comment.
Experimental review tooling 🤖
Thanks for opening this PR to IsaacLab! We're currently experimenting with automated review tooling, and we'd appreciate a little human time to review the review! The reviewer is under review, too.
Please reply with feedback on useful findings, false positives, and anything the tool missed.
Open Code Review v1.13.3 with Sol6.1 (azure/openai/gpt-6.1-sol, via NVIDIA Inference Hub) reviewed 116616efc54fc98bb14e5f9c884553ec878c34fd.
Result: No findings reported across 18 selected text files.
Scope: 18 of 18 changed files selected, including Python tests and .rst files. This was a static review; simulation tests were not run.
Review time: 1m3s. Token usage: 398,358.
|
Please preserve the existing license notices in the moved Isaac Lab uses BSD-3-Clause by default, including Both notices were already present in the initial version I traced, |
Restore the Apache-2.0 and BSD-3-Clause notices the module carried in isaaclab_mimic, and license it like the mimic files so the header hooks leave them in place. Signed-off-by: Rafael Wiltz <rwiltz@nvidia.com>
Thanks for catching that, you're right. I've restored the original Apache-2.0 and BSD-3-Clause notices verbatim and excluded this file from the BSD header hook (it's now handled like the mimic files), so the hooks keep them. |
|
run-ci |
|
Do we still support teleoperation on Linux aarch64 with pip-installed Isaac Sim? If so, the switch to in-process dispatch may introduce a startup regression. Previously, A focused base/head dispatch probe confirms the preload is omitted, but I have not reproduced an actual simulator startup failure on ARM. If this remains supported, could we verify an ARM launch or preserve the subprocess/re-exec bootstrap before importing Torch/Isaac Sim? |
Good catch, thanks. Digging in, this isn't teleop-specific: _aarch64_libgomp_env() (#6458) only applies through run_python_command(), and since #6553 moved train/play in process they've had the same gap on pip installs (install CI sets LD_PRELOAD itself, so it doesn't show up there). Teleop now matches RL here. I'd rather fix it once in cli() for every in process command on aarch64, re-execing through run_python_command() when the system libgomp isn't preloaded, verified on an ARM machine, in a follow-up PR. @StafaH thoughts? |
|
This is just a copy of the scripts into the submodule? Will a cleanup/refactor happen afterwards to split the large files, consolidate the common code, and make it less script-like and more module-like logic? Also will the tests move and get refactored as well into the submodule? |
…eleop there replay_demos.py becomes isaaclab_teleop.entrypoints.replay_demos with a wrapper at its old path. isaaclab_teleop.entrypoints.run_cli owns the run/record/replay dispatch, so isaaclab teleop calls it in process like isaaclab train. The entrypoint and replay loop tests move to isaaclab_teleop/test; the loop test now imports the function directly. Signed-off-by: Rafael Wiltz <rwiltz@nvidia.com>
Yes, intentionally a move for this PR: function bodies unchanged so the diff stays reviewable as renames. Follow-ups I have planned:
|
|
run-ci |
Description
Moves
teleop_se3_agent.py,record_demos.pyandteleop_replay_agent.pyintoisaaclab_teleop.entrypoints, following theisaaclab_rl.entrypointspattern (#6553, #6793), and untanglesrecord_demos.pyfromisaaclab_mimic, which is slated for deprecation.run_teleop_se3_agent_cli,run_record_demos_cliandrun_teleop_replay_agent_clitake the command line without the program name. The function bodies are unchanged; the argumentparsing that ran at import time becomes
_parse_args(argv). Git tracks the modules as renames, so review with rename detection.random_agent.py), so documented commands and the wheel staging list keep working.isaaclab teleop run|recordcall the entrypoints in process, likeisaaclab train, instead of launching the scripts.replaystill runsscripts/tools/replay_demos.py, which is not moved.load_external_tasks()before parsing, so tasks registered through theisaaclab.tasksentry point work with the scripts andisaaclab teleop.record_demos.py:*-Mimic-v0) are registered only whenisaaclab_mimicis installed.record_demos.py, moves fromisaaclab_mimic.uiinto the entrypoints package as a private module.SimpleNamespacestand-ins from Run the teleop scripts without Kit when nothing needs it #8828.Notes for review:
The entrypoints import
isaaclab_taskswithoutisaaclab_teleopdeclaring it. Declaring it would create a cycle, sinceisaaclab_tasksimportsisaaclab_teleop; the import only happens when a CLIfunction runs.
The instruction display moves from isaaclab_mimic with its original Apache-2.0 and BSD-3-Clause notices;
.pre-commit-config.yaml licenses it like the mimic files so the header hooks keep them.
The modules keep a module-level
args_cli, so the moved functions stay unchanged. Passing it explicitly, as the RL backends do, is left for a follow-up.Type of change
isaaclab_mimic.ui.instruction_displayis removed; its only user wasrecord_demos.py)Checklist
Docker and GPU tests run on demand. Push the commits you want tested, then
comment
run-cion the pull request.pre-commitchecks withuv run isaaclab --formatsource/<pkg>/changelog.d/for every touched package (do not editCHANGELOG.rstor bump package versions — CI handles that)CONTRIBUTORS.mdor my name already exists there