Skip to content

Cherry-pick: Turn on each Run's cameras for camera video recording in the Experiment Runner (#1829) - #1843

Open
xyao-nv wants to merge 3 commits into
release/0.4.0from
xyao/cp/1829/release/0.4.0
Open

xyao-nv wants to merge 3 commits into
release/0.4.0from
xyao/cp/1829/release/0.4.0

Conversation

@xyao-nv

@xyao-nv xyao-nv commented Dec 3, 2026 •

Copy link
Copy Markdown
Collaborator

Cherry-pick #1829 into release/0.4.0: turn on every Run's cameras when experiment_runner.py --record_camera_video is set. Replace the AttributeError from CameraObsVideoRecorder with a message that names the setting to change.

CameraObsVideoRecorder failed with an AttributeError when the env had no
camera_obs observation group. It now asserts that the group exists, with
a message that names environment.enable_cameras, --enable_cameras, and
an embodiment with cameras.

Recorder and test files of #1829.
(cherry picked from commit 95d95a0)
(cherry picked from commit fb764f9)
Signed-off-by: Xinjie Yao <[email protected]>
Release-only adaptation of #1829. release/0.4.0 reads a YAML Experiment
before startup with find_environment_field_values and composes it after
startup, so the runner change of #1829 does not apply.

With --record_camera_video, the Experiment Runner adds
runs.<name>.environment.enable_cameras=true for each Run of a YAML
Experiment that leaves it unset. A Run that sets it to anything other
than true fails before Isaac Sim starts. Legacy JSON Experiments take
no overrides and keep their jobs' values; the recorder names the
setting when a job has no cameras.

Two fixes make the overrides work:
- find_environment_field_values applies shared overrides, as
  composition does, so it sees shared.environment.enable_cameras.
- A graph-spec Run passes --enable_cameras to the graph-environment CLI
  when its enable_cameras field is true. An override sets the field but
  not per_run_overrides, which that CLI reads.

Signed-off-by: Xinjie Yao <[email protected]>
@greptile-apps

greptile-apps Bot commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

Confidence Score: 4/5RetriggerView in Greptile

[Medium impact] The change reaches YAML Experiment runs that record camera video, including OSMO submissions.

Fix the rejection of enabled camera expressions before merging.

Findings

  1. P1 Enabled camera expressions are rejected ▶
  2. P2 Camera opt-out is ignored ▶

Summary

The PR enables cameras for YAML Runs when camera video is requested and improves the recorder's missing-camera error.

  • Camera video turns on cameras for YAML Runs that leave them unset.
  • The camera recorder explains why a Run has no camera video.

xyao-nv explicitly notes that legacy JSON jobs retain their own camera settings because they do not accept Experiment overrides.

Reviews (1) · Last reviewed commit: "Turn on each Run's cameras for camera vi..." · Reviewed by Greptile

arena_env_args = legacy_environment_args_to_cli_args({"environment": cfg.env_spec_path, **cfg.per_run_overrides})
environment_args = {"environment": cfg.env_spec_path, **cfg.per_run_overrides}
# A Hydra override such as runs.<name>.environment.enable_cameras=true sets the field, not per_run_overrides.
if cfg.enable_cameras:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Let cfg.enable_cameras decide in both directions

cfg.enable_cameras starts from per_run_overrides and then takes any Hydra override, so it already holds the value the Run should use. With the if, an override of runs.<name>.environment.enable_cameras=false on a graph Run whose YAML sets true still passes --enable_cameras. Meanwhile the startup check and _assert_camera_support_enabled both see false. legacy_environment_args_to_cli_args drops False values, so always assigning the field handles both cases:

    environment_args["enable_cameras"] = cfg.enable_cameras

@arena-review-bot

Copy link
Copy Markdown
Contributor

🤖 Isaac Lab-Arena Review Bot

Summary

This cherry-picks #1829 into release/0.4.0. When an env has no camera_obs group, CameraObsVideoRecorder now fails with a message that names the setting to change. With --record_camera_video, the Experiment Runner adds an enable_cameras=true override for each YAML Run that leaves the setting unset. The release-only commit also makes find_environment_field_values apply shared. overrides and passes an overridden enable_cameras through to graph-spec Runs. Local runs of the getting-started Experiment should now work. Default OSMO submissions, which the PR also targets, still fail for every typed Run.

Findings

🔴 Critical: isaaclab_arena/evaluation/experiment_runner.py:83: ExperimentRunnerTask embeds the Experiment with serialize_arena_experiment_to_yaml, which writes every field of the composed config. A Run that left cameras unset therefore reaches the runner as enable_cameras: false. With OSMO's default record_camera_video=True, this assert rejects every typed Run before startup and tells the user to remove a setting that isn't in their YAML. The PR description says default OSMO submissions now render cameras, but they don't. peterd-NV reported the same problem on #1829. Two possible fixes: turn on every Run's cameras when recording, as policy_runner.py does, or set the field in ExperimentRunnerTask before serializing.

🔵 Improvement: isaaclab_arena/evaluation/legacy_graph_environment_cli.py:65: An override only reaches a graph-spec Run when it turns cameras on. An override to false on a graph Run whose YAML sets true still passes --enable_cameras, while the startup check sees false. Always assigning cfg.enable_cameras fixes both directions.

Test Coverage and CI Cost

The new tests don't start a SimulationApp and cover the local path. None of them feeds a serialized Experiment back into the runner, which is how OSMO calls it. A test in test_osmo_experiment_workflow.py that doesn't need the simulator would cover the finding above:

  1. Build an ExperimentRunnerTask from _zero_action_experiment_cfg().
  2. Write the contents it embeds at REMOTE_EXPERIMENT_PATH to tmp_path.
  3. Assert that experiment_runner._camera_video_overrides(path, []) returns ["runs.baseline.environment.enable_cameras=true"].

From reading the code, this test would hit the new AssertionError on this head. I didn't run it.

The rejection test sets up its own stub that fails if the simulator starts (line 638), copied from the --viz none test. #1829 already shares that setup through _run_experiment_runner_main_until_simulation_starts (fb764f9), and that helper could be picked here.

Pre-commit and the uv check were still queued when I reviewed this, so I couldn't confirm the tests pass.

Verdict

Significant concerns

Release-only adaptation of a3bb7a2 on #1829. An OSMO task writes the
typed Experiment to YAML with every default, including
enable_cameras: false, and runs it with --record_camera_video, which
OSMO turns on by default. The Experiment Runner rejected every such Run
because it could not tell that default from an author's false.

--record_camera_video now adds runs.<name>.environment.enable_cameras=true
for every Run of a YAML Experiment whose value is not true, as
policy_runner.py turns on its cameras, and prints those Runs.

Signed-off-by: Xinjie Yao <[email protected]>
@xyao-nv xyao-nv changed the title Cherry-pick: Turn on each Run's cameras for camera video in the Experiment Runner (#1829) Cherry-pick: Turn on each Run's cameras for camera video recording in the Experiment Runner (#1829) Dec 3, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant