Skip to content

Generate tabletop tasks from sampled SimReady object categories - #9165

Merged
ooctipus merged 68 commits into
isaac-sim:mainfrom
Fanxing-LI:fansing/heterogeneous-tasks-v2
Nov 25, 2026
Merged

ooctipus merged 68 commits into
isaac-sim:mainfrom
Fanxing-LI:fansing/heterogeneous-tasks-v2

Conversation

@Fanxing-LI

@Fanxing-LI Fanxing-LI commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

Description

Add IsaacContrib-TableTop-PickPlace-Franka, a flat Franka/Robotiq tabletop environment with 100 NVIDIA-hosted SimReady props and nine real SimReady table variants. Object count, categories, concrete assets, table and collision-free poses are sampled again at reset. Every environment can use every declared task family.

The scene declares eight interchangeable object slots. Each slot contains the same complete catalog plus an invisible, non-colliding placeholder. Reset samples a count from 2–8, samples a compatible source category and an asset uniformly within that category, reserves a fitting receiver, then samples categories and assets for the remaining occupied slots. Occupied objects and placeholders are shuffled across slots. A composition such as one container and two food items therefore uses three slots and five placeholders; no slot is permanently assigned a receiver or object role. Repeated assets are allowed. Placement retries preserve the sampled count.

InclusionSet(assets=["objects", "work_table"], sample_by="category") keeps initial clone planning factorized. Runtime selection uses Newton's existing native body variants through rigid-object and collection APIs, updating geometry, mass, inertia and COM-dependent state. There is no enumeration of complete world combinations or stored catalog-pair product, and no additional ReplicateSession customization. Identical collision-only source meshes share native SDF texture allocations across slots; visual meshes and prebuilt SDFs retain their ownership.

Task rules are declared beside the scene config as put_in_container and put_on_tray. Task IDs are stable indices into env.cfg.tasks, shared across all environments. Requesting a family before reset samples objects that make it evaluable. Instructions and source/target masks are rebuilt from current category- and size-compatible objects after every reset. Success requires release, footprint containment and supporting contact; container placement additionally checks the bottom against the rim.

Reset uses the intersection of the hand-defined robot workspace and each table's measured usable support polygon, including holes. Batched tensor checks test complete footprints against measured edges and holes, while XYZ bounds enforce the workspace; no polygon Boolean construction or Shapely task dependency is needed. Proposal bounds only narrow the search and do not replace the measured surface. Collision geometry is transformed relative to the simulator COM. Full footprints must fit, object pairs need clearance, and Newton's native collision pipeline rejects penetrating placements, including robot intersections. Tables retain their real visual geometry and triangle collisions; articulated table equipment is frozen into one kinematic body. A reset selects a different feasible table. Partial resets preserve untouched worlds. Pending worlds publish their new geometry and poses together; unplaced slots are kept apart outside the workspace during retries. The task declares SAH geometry BVHs: the same dense 64-world reset case passes with SAH and crashes inside Newton’s mesh-overlap kernel with LBVH.

The config composes constants with .copy() and .replace(). Reset and success evaluation stay in task-local MDP terms. There are no per-task configuration files, task YAML, config factories, post-init scene generation, task-local object-cooking subclasses or core task manager. Objects, tables and robot support use NVIDIA-hosted SimReady paths; no Hugging Face cache or custom object/table uploads are required. The known problematic Big_Plastic_Plate_A01 is excluded.

The Newton backend declares optional SDF triangle reduction through NewtonCfg(sdf_mesh_reduction=0.75), retaining original visual geometry and body inertia. This task uses 0.75 mm SDF voxels, four solver substeps with contact refresh, and a shared 5 ms gripper/object contact response. Robot home pose and actuator gains are preserved. Camera lighting comes from scene dome/distant-light assets translated at the builder boundary; renderer configs do not duplicate scene lighting. Unsupported light types are reported, and scenes with no supported lights keep Newton's defaults.

The robot references ISAACLAB_NUCLEUS_DIR/Robots/FrankaEmika/Robotiq/franka_robotiq_2F_85.usd. Its corrected replacement was requested and bucket propagation is pending. Local simulation uses the corrected saved USD through a runner-only override; no robot USD is bundled in this PR.

Based on main after #9156 merged. This PR is a prerequisite for #9184.

Validation

  • Automated coverage includes the catalog/factorization check and backend collision-approximation and visual-import checks.
  • A 1,000-entry, five-category catalog remains factorized across eight slots, with at most 128 materialized world prototypes for 128 environments.
  • A negative control fails when identical collision meshes allocate separate SDF textures. An isolated replay of the captured dense mesh-overlap query also reproduces the LBVH crash and passes with SAH.
  • The actual 100-asset scene passed 896 forced resets across 64 worlds: every count from 2–8 and both task families in every environment. All 100 concrete props were observed. Partial resets preserved untouched object variants and poses, and 30 subsequent simulation steps kept object states finite. These checks used the cached NVIDIA assets and the corrected local robot override; MJWarp still emitted line-search iteration-limit warnings.
  • The Shapely-free support check matches an independent geometry oracle on 90,000 cases, including concave outlines, enclosed holes and three clearance distances. Local physical reset/task-success and actual Robotiq validation passed after removing the direct dependency. Shapely remains a transitive dependency of the existing Newton alphashape importer.
  • Repository formatting/lint, changelog checks and offline lockfile validation pass.

The workspace is hand-defined rather than an IK reachability calculation. Size compatibility is conservative, not a grasp planner, and bounded placement can fail explicitly for infeasible configurations. The current documentation image was rendered before this reset change; no new policy success rate is claimed.

Screenshot

16 sampled SimReady tabletop worlds in a clean 4×4 view

Type of change

  • New feature
  • Documentation update

Checklist

  • Read the contribution guidelines
  • Run formatting and lint checks
  • Update documentation
  • Validate behavior with focused coverage and apply the test-audit criteria
  • Add package changelog fragments
  • Contributor names already exist in CONTRIBUTORS.md

FRANKA_ROBOTIQ_GRIPPER_CFG spawned the Isaac Sim Franka asset, whose arm
links carry placeholder inertias (centers of mass at the link origins,
inertias near 1e-6 kg m^2), and disabled gravity only on PhysX, as Newton
reads gravity switches on the physics scene. It now spawns the corrected
asset hosted with the Robotiq gripper on Hugging Face until it is on the
Isaac Lab Nucleus, compensates gravity in MuJoCo Warp, and limits the arm
torques to the Franka limits.
The franka_robotiq dataset now holds the OmniPBR MDL modules its materials reference next to the USD, so loading the robot no longer queries the server for a missing file.
@Fanxing-LI
Fanxing-LI requested a review from a team November 23, 2026 15:29
@github-actions github-actions Bot added documentation Improvements or additions to documentation isaac-lab Related to Isaac Lab team labels Nov 23, 2026
@Fanxing-LI Fanxing-LI changed the title Fansing/heterogeneous tasks v2 Add heterogeneous Franka pick-and-place tasks on Newton Nov 23, 2026
@greptile-apps

greptile-apps Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 4/5

[High impact] The PR changes how batched environments select scenes and evaluate task completion.

Restore task-specific object velocities before merging so task selection preserves the intended starting state.

Findings

  1. P1 Tasks inherit the wrong velocity ▶

Summary

Adds 256 Newton pick-and-place tasks and a shared environment that can select a different task for each environment.

  • Environments in one batch can run different tasks and switch them on reset.
  • Clone combinations can keep selected assets on fixed variants.
  • Task success checks cover common object placement goals and follow each environment’s task.
  • The VLA task bank adds 256 Franka pick-and-place scenes and a combined environment.

Acknowledged scope:

  • Fanxing-LI describes Hugging Face hosting as intentional until the assets move to Nucleus.
  • Fanxing-LI describes excluding these tasks from shared smoke tests because their assets download from Hugging Face.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Task configurations] --> B[Compose shared object slots]
    B --> C[Pin initial clone variants]
    C --> D[Select task on reset]
    D --> E[Switch object variants and default poses]
    E --> F[Reset scene]
    F --> G[Evaluate success by task]
Loading

Reviews (1) · Last reviewed commit: "Adapt the heterogeneous tasks to the def..." · Reviewed by Greptile

Comment on lines +238 to +239
for slot, obj in enumerate(self._slots):
obj.data.default_root_pose.torch[env_ids] = self._poses[slot, tasks]

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.

P1 Tasks inherit the wrong velocity

HeterogeneousTaskManager switches each object's pose but keeps the first task's default velocity. compose_tasks initializes the slot with objects[0].init_state, while resets update only default_root_pose. If tasks specify different init_state.lin_vel or init_state.ang_vel values, reset_scene_to_default starts them with the first task's speed or spin instead. Store task velocities alongside _poses and update default_root_vel for the environments being reset.

@isaaclab-review-bot isaaclab-review-bot Bot left a comment

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.

Isaac Lab Review Bot

Needs attention: Design and architecture (2), Scope and over-engineering (6), Implementation (2), Style consistency (4), Test quality (4). Other reviewed categories look good.

  • PR description: Name included manager/cloner changes, shorten repeated backend prose, and substantiate “3 ms/step” with baseline/candidate revisions, workload/command, hardware, backend, environment count, warmup, and latency measurements; otherwise remove the claim.
  • Design and architecture: Cross-config composition in post_init violates configuration ownership and can replace caller task edits; move composition to preparation or construction.
  • Scope and over-engineering: Minimal implementation: Extend ReplicateSession, EventManager, and TerminationManager mechanisms; keep heterogeneous_task_manager.py for reset state, package/MDP initializers and stub for contracts, shared environment configuration, objects.py, and test utilities; merge robot_cfg.py into the scene and mdp/utils.py into terminations.py; merge all 256 task modules and their manifest into data-driven construction, preserving registrations and remaining package initializers. Suggested PR breakdown: (1) cloner pins, algebra/Newton tests; (2) manager lifecycle, composition/reset tests; (3) task data and predicates, registered-environment integration.
  • API: API changes look good.
  • Compatibility and deprecation: No breaking changes identified.
  • Implementation: Geometry selection follows task IDs instead of asset.mesh_variant_ids, producing stale success results after independent variant writes and failing standalone multi-variant scenes; read active IDs from each asset.
  • Style consistency: The camera helper omits fixed-length pose types, coordinate frames, and focal-length units; specify those contracts in its signature and docstring.
  • Test quality: The pinning case uses only single-candidate slots, so it does not demonstrate the promised clone-planning behavior; compose distinct candidates and verify initial world selection.

Needs rework. Posted 18 inline findings.

The full PR diff was reviewed; some supplemental surrounding file context was omitted.

Automated review; human maintainers own approval decisions.

# Rows of the geometry tables (N, M).
self._rows = self._offsets + torch.stack(candidates, dim=1)
self.corners = self._to_world(self._corners[self._rows]) # (N, M, 8, 3)
self.box_center = self._to_world(self._box_center[self._rows].unsqueeze(2)).squeeze(2) # (N, M, 3)

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.

🔴 Critical · Implementation — Read the active asset variant

Geometry selection uses task IDs, not each object's mesh_variant_ids. A separate variant write makes success evaluate stale geometry; a standalone multi-variant scene has no task_manager. Read the selected IDs from each asset.

if cfg.events is None:
cfg.events = {}
if cfg.terminations is None or isinstance(cfg.terminations, type(MISSING)):
cfg.terminations = {}

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.

🟡 Warning · Implementation — Validate before mutating composition

Recomposing different tasks pops select_task before raising, leaving the configuration without its selector; recomposing changed tasks with the same names retains removed generated terms. Reject recomposition before modifying events or terms.

changed = changed[self._slot_task_ids[changed] != self.task_ids[changed]]
if len(changed):
for slot, obj in enumerate(self._slots):
# A slot whose tasks all have the same object has no variant to select.

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.

🟡 Warning · Scope Complexity — Cache reset environment indices

Every reset allocates a full device arange before filtering changed environments, including partial resets. Cache the index tensor at initialization and select from it.

)
from isaaclab.managers.heterogeneous_task_manager import task_term

pytestmark = pytest.mark.unit

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.

🟡 Warning · Test Quality — Mark simulator-free tests kitless

These configuration tests need no simulator, but the file lacks pytest.mark.kitless and misses text-based kitless CI selection. Add the file-level marker.

HeterogeneousTaskManager.compose_tasks(cfg, {"shelf": shelf, "cube": cube})
stand_ins = [cfg.scene.object_1.spawn.assets_cfg[1], cfg.scene.object_2.spawn.assets_cfg[1]]
assert [spawn.rigid_props.kinematic_enabled for spawn in stand_ins] == [True, False]

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.

🟡 Warning · Test Quality — Exercise actual candidate pinning

One task gives each slot one candidate, so removing the pins does not change initial worlds. Compose distinct candidates and verify the resulting clone plan selects the first task.

"PickPlace254": PickPlace254EnvCfg(),
"PickPlace255": PickPlace255EnvCfg(),
}
HeterogeneousTaskManager.compose_tasks(self, self.tasks)

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.

🟡 Warning · Design Architecture — Compose outside configuration hooks

The post_init hook constructs and merges 256 configurations; copying the config reruns it and replaces caller changes to tasks. Move cross-config composition to launch preparation or construction.

from ..objects import library_object


@configclass

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.

🟡 Warning · Scope Complexity — Replace generated classes with task data

The 256 modules repeat configuration construction while varying instruction, objects, poses, and success parameters. Store those variations as data and construct configs at the registered entry points, preserving task IDs.

"coffee_can", (0.50815, -0.18363, 0.14107), (0.0, 0.0, 0.278894, 0.960322)
)
self.terminations.success = DoneTerm(
func=mdp.object_on_top,

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.

🟡 Warning · Design Architecture — Defer runtime term resolution

Resolving mdp.object_on_top while building a configuration imports the predicate module and its pxr/SciPy dependencies before simulator startup. Use resolvable strings for generated predicates and the shared success term.

assert _term(env, mdp.stacked, objects=[SceneEntityCfg("ball"), box])() == [True, False]
both = [SceneEntityCfg("ball"), SceneEntityCfg("ball_b")]
assert _term(env, mdp.object_in_container, objects=both, container=box, logical="any")() == [True, False]
assert _term(env, mdp.object_in_container, objects=both, container=box, logical="choose", count=1)() == [

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.

🟡 Warning · Test Quality — Distinguish exact count from any

The choose and any cases have at most one contained ball, so treating choose(count=1) as any passes. Include two contained balls and assert that exact count rejects them.

This test is the last one: its second environment stays diverged, as no event resets the scene.
"""
ball, box = [SceneEntityCfg("ball")], SceneEntityCfg("box")
place(env, "ball", [(0.5, 0.0, 0.05), (float("nan"),) * 3])

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.

🟡 Warning · Test Quality — Restore the scene after divergence

The NaN case leaves the module-scoped environment diverged and relies on running last. Restore finite state in teardown so test order does not determine whether sibling cases pass.

@ooctipus ooctipus changed the title Add heterogeneous Franka pick-and-place tasks on Newton Define heterogeneous Franka tasks from one flat scene catalog Nov 24, 2026
@ooctipus ooctipus changed the title Define heterogeneous Franka tasks from one flat scene catalog Generate tabletop tasks from sampled object categories Nov 24, 2026
@Fanxing-LI Fanxing-LI mentioned this pull request Nov 24, 2026
6 tasks done
@ooctipus ooctipus changed the title Generate tabletop tasks from sampled object categories Generate tabletop tasks from sampled SimReady object categories Nov 24, 2026
ooctipus added a commit that referenced this pull request Nov 24, 2026
…9156)

## Description

Multi-asset spawners can expose an enormous Cartesian product even when
a task only needs a few compatible worlds. Declare compatibility with
existing semantic tags and keep the legal choices compact until scene
planning selects concrete worlds.

```python
InclusionSet(assets=["gear", "fixture"], match_tags=["size", "assembly"])
```

- `InclusionSet` owns only asset membership, inclusion weight, and
matching tag types. No matching subclass, override method, positional
layouts, separate labels, environment count, or random seed is required.
- Selected variants must share a value for each requested tag type. A
universal fixture can list several `size` values. Repeat asset names for
cardinality; all selected instances share the requested tags. Unclaimed
assets remain independent. This expresses shared compatibility, not
separate pairwise constraints or sampling without replacement.
- Scene planning reads individual spawner tags, including inherited
wrapper tags, and resolves compatible tag-value groups. Each slot
retains its candidate prototype IDs instead of expanding every concrete
combination.
- `make_clone_plan` uses the existing scene clone strategy to select
groups and each slot's candidates, materializes only selected worlds,
and reuses identical concrete prototypes. Inclusion weights split
equally across compatible groups. Multi-valued tags can make groups
overlap; this is group-weighted selection, not uniform sampling over the
exhaustive union of concrete worlds.
- Without matching tags, retain the existing independent product and
assignment behavior.
- Replication execution remains unchanged. `ReplicateSession` only
receives broader type annotations for forwarding compact definitions;
inclusion interpretation stays outside it.

This is the generic prerequisite. Downstream task-manager,
heterogeneous-task, and VLA evaluation example changes (#9161, #9165 and
#9184 ) need to adopt the declarative API when restacked.

## Validation

- 36 clone-plan algebra tests, 17 replication-session tests, and one
Newton native asset test passed (54 total).
- Tests cover multi-valued universal tags, multiple matching tag types,
repeated instances, independent unclaimed assets, collection columns,
mixed concrete/factorized definitions, prototype reuse, invalid choices,
and external random-seed reproducibility.
- A case with 1,000 variants, five categories, and eight slots retained
five groups rather than expanding `5 * 200**8` concrete worlds; planning
128 environments created at most 128 concrete world prototypes.
- A standalone scene-planning check passed for collection members,
shared offsets, concrete MultiUsd candidates, inherited tags, and source
preservation. The Isaac Sim scene test cannot launch without its runtime
in this checkout.
- Removing inherited tag propagation makes the native regression fail;
restored code passes.
- Local planning benchmark: approximately 4.37 ms to resolve the
1,000-variant case and 0.85 ms to select 128 worlds, with about 510 KiB
peak Python planning allocation. This measures planning, not asset
loading or simulation.
- Full formatting checks and a file-by-file structural audit passed,
including unchanged replication execution after stripping annotations.

---------

Co-authored-by: Octi Zhang <[email protected]>
ManagerBasedRLEnvCfg.tasks lists the tasks that the environments run. Their
rigid objects are composed into switchable slots, their termination terms
are masked to the environments of each task, and their episode lengths are
kept per environment. Each environment runs one task and switches tasks on
reset, only where its task changed.
The environment classes are left as they are: the environment configuration calls HeterogeneousTaskManager.compose_tasks(cfg, tasks), which also adds the reset event that creates the task manager and selects the tasks before the other reset events.

The event creates the manager before the solver is built, where selecting objects has no effect. The clone combinations therefore pin the first candidate of every slot: every environment starts with the objects of the first task, and clone planning does not enumerate the combinations of all candidates.
Cover HeterogeneousTaskManager.task_terms and the rule that a termination defined by the environment configuration is not added again for each task.
Composing other tasks into a composed configuration raises instead of keeping the first select_task event; composing the same tasks again, as copying a configuration does, changes nothing. A configuration without events or terminations gets those of the tasks, and the docstring says when to compose configurations with presets.
@ooctipus

Copy link
Copy Markdown
Collaborator

run-ci

@isaaclab-bot isaaclab-bot Bot added ci:run-docker Trigger the on-demand Docker and GPU CI workflow and removed ci:run-docker Trigger the on-demand Docker and GPU CI workflow labels Nov 25, 2026
@ooctipus

Copy link
Copy Markdown
Collaborator

run-ci

@isaaclab-bot isaaclab-bot Bot added ci:run-docker Trigger the on-demand Docker and GPU CI workflow and removed ci:run-docker Trigger the on-demand Docker and GPU CI workflow labels Nov 25, 2026
Comment thread uv.lock Outdated
{ name = "rich" },
{ name = "rsl-rl-lib" },
{ name = "scipy" },
{ name = "shapely" },

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.

can we file an OSRB for this one?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

removed

@ooctipus

Copy link
Copy Markdown
Collaborator

run-ci

@isaaclab-bot isaaclab-bot Bot added ci:run-docker Trigger the on-demand Docker and GPU CI workflow and removed ci:run-docker Trigger the on-demand Docker and GPU CI workflow labels Nov 25, 2026
@ooctipus
ooctipus merged commit e6fc4fd into isaac-sim:main Nov 25, 2026
94 of 95 checks passed
ooctipus added a commit that referenced this pull request Nov 26, 2026
## Description

Evaluate pi0.5 on `IsaacContrib-TableTop-PickPlace-Franka` from merged
#9165 with one command. The first run fetches a pinned OpenPI revision,
prepares its separate Python 3.11 environment, anonymously downloads the
joint-position checkpoint and starts inference. Subsequent runs reuse
the caches. Evaluation shuts down its inference process on completion or
interruption.

The PR adds two scripts: the evaluator owns scene setup, trial
scheduling and local process lifetime; the server entrypoint owns OpenPI
model configuration and loading. There are no framework, task, asset or
dependency-file changes. OpenPI's dependencies stay outside the Isaac
Lab environment.

Any idle world requests the next global task-family ID and resets to a
fresh object count, category composition, assets and table. Each episode
records its instruction, objects, mesh variants, table variant and
success/timeout. Completed worlds discard their remaining action chunk
and hold their reset arm pose with the gripper open. Every terminal
result counts, including one-step episodes.

The client uses the standard OpenPI WebSocket protocol, querying active
worlds serially. No custom batch adapter is required. Camera updates
follow the action chunk interval; both views are letterboxed to 224 ×
224, and DROID gripper closure maps to the environment's binary command.

## Run

With Isaac Lab installed on Linux and an NVIDIA GPU, git and uv
available:

```bash
uv run --with msgpack python scripts/large_models/pi05_evaluate.py --viz none
```

No manual OpenPI installation, server launch or Google login is
required. The first run downloads the approximately 12.4 GB
`gs://openpi-assets-simeval/pi05_droid_jointpos` checkpoint.
Source/environment are cached under `~/.cache/isaaclab/pi05`;
weights/tokenizer use `~/.cache/openpi` (`OPENPI_DATA_HOME` overrides
it). Inference uses the first visible GPU without JAX preallocation;
simulation and inference must fit in available GPU memory.

Optional controls:

- `--num_envs 4 --trials 2`: two trials per task family, distributed
across four worlds.
- `--policy-device 1`: select another inference GPU through
`CUDA_VISIBLE_DEVICES`.
- `--checkpoint /path/to/pi05_droid_jointpos`: reuse existing weights.
- `--policy HOST:PORT`: use an existing standard OpenPI joint-position
server and skip local setup.
- `--tasks put_in_container`: select a task family.
- `env.episode_length_s=10`: ordinary task configuration overrides.

Reports go to a new timestamped directory under `logs/pi05`; `--output
PATH` selects one explicitly. The action contract is seven absolute arm
joint positions and gripper closure in [0, 1]. The standard
velocity-action DROID checkpoint is incompatible.

## Validation

- Started with an empty OpenPI checkout/environment cache: automatic
fetch of revision `215abfb217dbac7d5f1273282331b9b1866c0479` and locked
dependency installation succeeded.
- Real pi0.5 inference completed both task families in two worlds with
three-second episodes: two timeouts, 45 shared control steps, 90 trial
steps and six standard policy requests. This checks integration, not
policy performance.
- That run used the published robot and scene configuration with no
local asset overrides. Existing checkpoint and asset caches were reused;
the full 12.4 GB model was not downloaded again.
- Separately verified anonymous download of checkpoint normalization
assets into a fresh cache, including recursive directory download and
cache reuse.
- Verified cached environment startup, interruption cleanup and
propagation of server startup failure for a missing checkpoint. No
inference process remains after exit.
- Scheduler checks cover global family scheduling, fresh instructions,
one-step episodes, completion within a chunk, idle holds, row ordering,
gripper signs and exact step accounting. Reply guards reject short
chunks, wrong width/rank, NaNs and server errors.
- CLI help, full repository formatting/lint and changelog checks pass.
No new simulation tests were added.

## Type of change

- New example scripts

## Checklist

- [x] Follow contribution guidelines
- [x] Run formatting and lint checks
- [x] Document setup and usage in the scripts
- [x] Validate real inference, lifecycle and scheduling locally
- [x] No source-package changes requiring a changelog fragment

---------

Co-authored-by: Octi Zhang <[email protected]>
kellyguo11 added a commit that referenced this pull request Nov 30, 2026
…l task support (#9306)

## Description

Backport #9155, #9184, and #9217 to `release/3.1.0`:

- #9155: fix RLinf playback checkpoint selectors and relative config
paths, strengthen train-to-play regression coverage, and update the VLA
post-training guide.
- #9184: add pi0.5 evaluation and inference-server scripts for sampled
tabletop tasks, and change the gripper/prop contact response to 20 ms.
- #9217: support external RLinf tasks, preserve split-specific recipe
overrides, capture terminal episode success, add deterministic image
resizing and validation, and support an optional training runner
context.

Cherry-picked with `-x` from `c1afcee17283aacaebd5ccdbb4e823827752ffd6`,
`92ecbeeb428fb50b242651d747be0fe3bcef6d4e`, and
`05e3a7dc46dce08a2e61511cf5ef358a5ffd4c2d`. All three applied without
conflicts or manual edits; stable patch IDs match the original commits.
The prerequisite tabletop task from #9165 is already on the release
branch. Original changelog fragments are included for every touched
package.

## Type of change

- Release backport: bug fixes, features, example scripts, and
documentation

## Validation

- Full repository formatting/lint and changelog hooks pass on the final
combined changes, using
`ISAACLAB_CHANGELOG_BASE_REF=upstream/release/3.1.0`.
- `git diff --check upstream/release/3.1.0` passes; all three stable
patch IDs match their source commits.
- Image utilities: **54 passed** locally after adding #9217.
- RLinf adapter: 32 passed locally; remaining tests are blocked by
missing dependencies in the local macOS environment. Entrypoint test
collection is also blocked by unavailable runtime dependencies.
- Clean docs build attempted locally; uv rejects macOS because the
lockfile supports Linux and Windows only.
- GPU inference, training, and simulation were not rerun locally for
this backport.
- Full CI retriggered with `run-ci` and completed on final head
`eae44aca5037347a7bd95cb2a5fdc5447c29eb25`: **54 passed, 7
skipped/neutral, no failures or pending checks**.
- [Docker +
Tests](https://github.com/isaac-sim/IsaacLab/actions/runs/46363334813)
passed, including RLinf, contrib, core, task, rendering, and performance
jobs. Windows, ARM, multi-GPU unit/training smoke tests, clean docs
build, wheel, licensing, pre-commit, and changelog checks also passed.
OVStage tests were not requested by the plain `run-ci` command.

## Checklist

- [x] Read the contribution guidelines
- [x] Run full formatting and lint checks
- [x] Preserve the original documentation, regression tests, and
changelog changes
- [x] Verify all three cherry-picks match the original patches
- [x] Complete CI on the final combined head

---------

Co-authored-by: Fanxing-LI <[email protected]>
Co-authored-by: Octi Zhang <[email protected]>
Co-authored-by: YunLiu <[email protected]>
Co-authored-by: Fanxing-LI <[email protected]>
kellyguo11 pushed a commit that referenced this pull request Dec 3, 2026
# Description

Follows #9074, which added `isaaclab_fovi`. This PR
now carries all of the active-gaze work: it includes
#9181 (gaze modes, now a draft), which was reviewed on
its own, and adds binocular gaze on top. Both were first reviewed in the
fork, as nblauch#6 and nblauch#7.

Following [FOVI-Dex](https://fovi-dex.github.io/), it lets a policy turn
a camera on a pan-tilt mount as well as the retina inside it, and fixate
a point with two foveated eyes on one head. Until now the gaze action
could only turn one camera's retina (software gaze). The
`foveated-camera` example's new `--stereo` mode shows binocular gaze.

**Fixes to `main`.** Three changes fix bugs in `gaze_teacher_labels`
from #9074, listed under Fixed in the changelog: it
rendered a frame for every label (see *Teacher pose reads*), a tracked
mount's teacher aimed from the mount of the step before (see *Mount
updates*), and a target naming the asset's only body raised a
`TypeError`, since Isaac Lab resolves body ids that cover every body to
a slice.

## Gaze modes (`isaaclab_fovi.mdp`)

`GazeActionCfg.mode` chooses what the gaze actions turn:

- `"software"` (the default, unchanged): the retina.
- `"physical"`: the rig's joints; each step adds to their last targets,
so a lagging head still reaches every command.
- `"hybrid"`: the retina at once, while the rig turns the camera after
it by at most `GazeRigCfg.max_step_deg` per step and the fixation holds
in the world.
- `"dual"` (experimental): four actions, the joints as in physical gaze
and then the retina, independently.

The `GazeAction` docstring and the Foveated Camera page describe each
mode in full. `GazeRigCfg` names the articulation and its pan and tilt
joints. The rig modes need `mount="tracked"` and a camera without image
roll. With a rig, `gaze_state` reports the fixation's direction from the
rig's zero pose, the head's turn composed with the retina's, so the
observation means the same in every mode. In physical gaze the retina
stays where the gaze action leaves it, on the optical axis, unless
something sets it directly with `FoveatedCamera.set_gaze_angles`; in
hybrid gaze such a call starts a new fixation, which
`FoveatedCamera.gaze_writes` lets the action tell apart from its own
writes.

`gaze_teacher_labels` labels from where the next step starts: in hybrid
gaze the software gaze re-aimed at its held fixation, and in physical
gaze the head's commanded pose, so it never repeats a turn the head has
made or has yet to make. Its target body may also be named when it is
the asset's only body.

- *Teacher targets in the world.* `gaze_teacher_labels` takes
`target_w`, a function of the environment that returns each
environment's target point, as an alternative to `target_cfg`. A target
chosen per environment, such as the object a command picks among
several, is not a point fixed to one asset.
- *Teacher pose reads.* The teacher took the camera's position from
`camera.data`, and reading a camera's data updates its image, so
labelling rendered a frame; a policy that observes every fourth control
step and labels every step rendered four frames for each one it used.
The teacher now reads the new `FoveatedCamera.mount_pos_w`, which
`update_mount` refreshes.

**Mount updates.** `FoveatedCamera.update_mount()` reads the camera's
pose and returns its mount. A lazily updated camera reads its pose only
when its data is read, so without it hybrid gaze aimed from the mount of
a step ago and the head never settled. The tracked-mount teacher from
#9074 had the same one-step lag and now uses it too.

**Tracked mounts on Isaac RTX.** A tracked mount needed a renderer that
turns the camera's pose by the gaze, so the rig modes ran only on Newton
and OVRTX. An Isaac RTX camera holds its gaze in its prim, relative to
the prim's parent, so it already follows a moving mount; only the
recorded mount was missing. `update_mount` now reads it back from the
prim, without the gaze, and `mount="tracked"` works with every renderer.

## Binocular gaze (`isaaclab_fovi.mdp`)

- `BinocularGazeActionCfg` moves two eyes with three actions: the
**version**, their shared line of sight (tilt, pan), and the
**vergence**, the angle between their lines of sight. Each eye turns
from the version by half the vergence, toward the other eye, in the
plane that holds the version and the baseline, so the two lines of sight
always meet; the farther the fixation, the smaller the vergence.
- The version moves as a single camera's gaze does in `"software"`,
`"physical"` or `"hybrid"` gaze; the vergence always turns the retinas.
Both are in field radii, and the vergence stays between zero (parallel)
and `vergence_limit`.
- `binocular_gaze_state` observes the version, the vergence and their
velocities; with a rig, the version is its direction from the rig's zero
pose, as for `gaze_state`.
- `binocular_gaze_teacher_labels` labels the actions that fixate a point
with both eyes: the version bisects the eyes' lines of sight to it and
the vergence is their angle. The decomposition is exact, since the two
lines of sight are symmetric about their bisector. Like
`gaze_teacher_labels`, it starts from where the next step does, takes
`target_w`, reads both eyes' positions from `mount_pos_w` without
rendering, and checks each eye's visibility with its own camera.
- `binocular_gaze_angles` turns a version, a vergence and the baseline
between the eyes into each eye's gaze without an action term, through
the same Warp function as the action's step, so code outside a
manager-based environment can drive two foveated cameras with the same
geometry.
- The eyes need one body to carry them (their prims share a parent),
parallel optical axes, and the same retina, on any renderer: Newton,
OVRTX or Isaac RTX. The rig modes also need eyes without image roll.
- The gaze actions write the rig's joint targets with a persistent
joint-id array. A list became a new device array on every write, and
with cameras rendering, a captured Newton physics step faulted on that
freed memory.

Each gaze mode has its own Warp kernel, only hybrid gaze allocates the
fixation it holds, and a Warp kernel resets the reset environments.

## Pan-tilt mount (`isaaclab_fovi.assets`)

`PAN_TILT_CFG` is FOVI-Dex's two-joint pan-tilt mount, with no visual
geometry. `spawn_pan_tilt` builds it in the stage, its three links and
its fixed, pan and tilt joints, so the package ships no USD and nothing
has to be hosted on Nucleus. It runs with or without Kit.
`PAN_TILT_CAMERA_OFFSET` places a camera on its tilting link, and
`PAN_TILT_STEREO_OFFSETS` two eyes 6.5 cm apart. Its drives are about
critically damped and settle in about 0.3 s; their armature carries the
inertia, since the links alone are too light for a stable stiff drive at
a 120 Hz physics step on MJWarp. The mount leaves gravity on: Newton
reads one body's `disable_gravity` as the whole scene's.

## Example

`isaaclab example foveated-camera` keeps its single camera and software
gaze. With `--stereo` it looks at the same YCB scene through two eyes
6.5 cm apart, which `binocular_gaze_angles` aims by a version and a
vergence:

- Below the viewer's Camera Source selector, sliders set the version
(tilt, pan) and the vergence; I/J/K/L and drags in the eyes' window turn
the version, and U/O converge and diverge the eyes. `--target` fixates
an object as the binocular teacher would, and a "Gaze to next object"
button glides both eyes onto the next object, the version and the
vergence arriving together.
- The viewer opens on a perspective view from beyond the objects that
draws each eye as an eyeball turned with its gaze, its line of sight,
and the point where they meet; a checkbox hides that overlay. A window
shows both eyes' cortical views side by side, and the camera menu offers
each eye.
- The eyeball is FOVI-Dex's
(`examples/assets/active_camera_eyeball.usda`, 0.8 MB in Git LFS, plain
preview-surface materials and no textures). It stays beside the examples
until it is uploaded to Nucleus. The viewer draws it as mesh instances,
so the eyes' own images never see it.

Both modes now light the scene by renderer. Since
#9165, Newton cameras read a dome light's intensity as
linear radiance, so the RTX-scale dome (900) washed their images out to
white; Newton now gets 1, and OVRTX and Isaac RTX keep 900. Core tasks
with RTX-scale domes, such as `reach` and `cabinet`, may be washed out
on Newton cameras the same way.

The separate `foveated-stereo` example from earlier revisions of this PR
is gone, so `isaaclab` itself is unchanged.

## Docs

"Gaze modes" and "Binocular gaze" sections on the Foveated Camera page,
each with a config example and a figure (below), plus API entries for
`GazeRigCfg`, binocular gaze, `binocular_gaze_angles` and
`isaaclab_fovi.assets`. The Binocular gaze section shows how to run
`foveated-camera --stereo`.

![Gaze
modes](https://github.com/nblauch/IsaacLab/blob/feat/isaaclab-fovi-stereo-vergence/docs/source/_static/overview/sensors/foveated_camera_gaze_modes.jpg?raw=true)

Each mode on the pan-tilt mount, simulated with Newton's MJWarp solver
at a 30 Hz policy step: the policy pans 4.5° left three times. In hybrid
gaze the fixation jumps at once and holds while the head takes over from
the retina.

![Binocular
gaze](https://github.com/nblauch/IsaacLab/blob/feat/isaaclab-fovi-stereo-vergence/docs/source/_static/overview/sensors/foveated_camera_binocular.jpg?raw=true)

Top: both eyes' 128 × 128 images at the end of each fixation. The
fixated object sits in both foveas, while nearer or farther objects fall
in different places in the two eyes. Below: the version jumps to each
object while the head turns after it, and the vergence follows the
object's distance. Hybrid gaze holds the version's direction rather than
a point, and turning the head moves the eyes, so for near objects the
teacher keeps adjusting the version and vergence while the head turns.

## Type of change

- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)

## Release backport

- [x] <!-- backport-active-release --> Backport this pull request to the
active release branch after it merges into `main`

## Validation

At 250824d (the later commit adds the demo's eyeballs and controls; its
glide was checked headless through all 17 objects, ending each with the
lines of sight within 0.3 mm of the object, and the 56 simulator-free
cases still pass after merging `main`):

- Simulator-free: the 56 cases in `test_active_gaze.py`,
`test_camera_gaze.py` and `test_camera_cfg.py` pass. New in
`test_active_gaze.py`:
- one kernel step per rig mode, and the dual observation against
quaternion composition;
- through `GazeAction` itself, a hybrid gaze set on the camera starting
a new fixation, the hybrid teacher after a head turn, and the physical
teacher on a tilted head with a turn already queued;
- a target body named by a slice, and a world-point target reaching the
gaze term with its offset;
- for binocular gaze, the lines of sight meeting at the vergence's angle
in one plane with the baseline, the vergence's limits, hybrid version
with the head following, the teacher's labels for a point ahead and one
behind, the physical and hybrid teachers after head turns, and the
rejection of eyes on two bodies;
  - `binocular_gaze_angles` against the action's step;
  - the rig, action and binocular config checks.
- All 11 Newton and Isaac RTX render cases pass; the four OptiX cases
skip without `optix`. Two new cases run on both renderers:
- `test_hybrid_gaze_turns_the_head_onto_the_fixation` pans three steps
without reading the camera between steps. It checks that the retina
leads the head, that the head and the camera's world axis end on the
fixation with the retina back on the optical axis, and that after a
reset the gaze and its observation are zero and the next step commands
the rig's default pose. It fails without `update_mount`.
- `test_binocular_gaze_fixates_a_near_point_with_both_eyes` steps the
stereo head with the teacher's labels toward a point 0.4 m away and 15°
to the left. It checks that both optical axes pass within 1 mm of the
point, that the head carries the version and the vergence matches the
distance, and that a reset restores parallel lines of sight. Flipping
the vergence's direction in the kernel fails it and the vergence unit
test.
- `foveated-camera --stereo`, built headless on Newton and on Isaac RTX:
after fixating three objects 0.5 m to 1 m away, steering, and setting
the eyes parallel, the measured angle between the lines of sight equals
the vergence and their bisector the version to within 0.0001°, and the
lines meet within 0.2 mm of each object. Both it and the single-camera
mode render normally on Newton and open in the Newton viewer.
- The joint-id fix: with list ids, 180 steps of the binocular scene in
physical or hybrid gaze, rendering both eyes with CUDA graphs on,
faulted in the first steps; with mask writes, full-buffer writes or a
persistent id array they run to the end. The pre-merge commit ad23446
faulted the same way.

Earlier, with the converted USD mount, whose links, masses, limits and
drives the spawner reproduces:

- Rollouts of all four modes on Newton + Warp reach the commanded 13.5°
(physical settles at 13.47°).
- FOVI-Dex's clutter-lift task, moved onto this gaze action: its render
smoke passes with software and physical gaze on Newton + Warp and on
PhysX + Isaac RTX, and a policy acting in four-step chunks renders once
per chunk.
- The docs build passed with warnings as errors.

Not rerun: OVRTX, the standalone-script smoke test, the contrib PPO
cases, and the docs build since the last changes (the Binocular gaze
section and the `isaaclab_fovi.assets` and `isaaclab_fovi.mdp` API
pages).

**Rig step cost.** One rig gaze step with one kernel and a runtime mode
(806a5ee) and with one kernel per mode, which also composes the head and
retina rotations (b8c47ef), on an RTX 6000 Ada with Warp 1.17 and random
actions and joints. Each kernel is launched 10 times to warm up, then
100 launches are captured in a CUDA graph, replayed 5 times, and timed
over 200 replays.

| Environments | Mode | 806a5ee | b8c47ef |
| --- | --- | --- | --- |
| 4,096 | physical | 2.53 µs | 2.73 µs |
| 4,096 | hybrid | 3.20 µs | 3.49 µs |
| 4,096 | dual | 2.35 µs | 2.49 µs |
| 65,536 | physical | 2.78 µs | 3.24 µs |
| 65,536 | hybrid | 3.94 µs | 4.31 µs |
| 65,536 | dual | 2.73 µs | 3.17 µs |

Launched from Python, either takes about 13 µs a step, which is launch
overhead. Hybrid gaze reads the camera's pose each step
(`update_mount`), which a camera read for its image that step would have
done anyway.

## Checklist

Docker and GPU tests run on demand. Push the commits you want tested,
then
comment `run-ci` on the pull request, or `run-ci ovstage` to include
kitless OVStage rendering tests for that run.

- [x] I have read and understood the [contribution
guidelines](https://isaac-sim.github.io/IsaacLab/main/source/refs/contributing.html)
- [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with
`uv run isaaclab --format`
- [x] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have validated the changed behavior with focused coverage and
applied the [test-audit
criteria](https://github.com/isaac-sim/IsaacLab/blob/HEAD/skills/developer/test-audit/SKILL.md)
to any test changes
- [x] I have added a changelog fragment under
`source/<pkg>/changelog.d/` for every touched package (do **not** edit
`CHANGELOG.rst` or bump package versions — CI handles that)
- [x] I have added my name to the `CONTRIBUTORS.md` or my name already
exists there
isaaclab-bot Bot pushed a commit that referenced this pull request Dec 3, 2026
# Description

Follows #9074, which added `isaaclab_fovi`. This PR
now carries all of the active-gaze work: it includes
#9181 (gaze modes, now a draft), which was reviewed on
its own, and adds binocular gaze on top. Both were first reviewed in the
fork, as nblauch#6 and nblauch#7.

Following [FOVI-Dex](https://fovi-dex.github.io/), it lets a policy turn
a camera on a pan-tilt mount as well as the retina inside it, and fixate
a point with two foveated eyes on one head. Until now the gaze action
could only turn one camera's retina (software gaze). The
`foveated-camera` example's new `--stereo` mode shows binocular gaze.

**Fixes to `main`.** Three changes fix bugs in `gaze_teacher_labels`
from #9074, listed under Fixed in the changelog: it
rendered a frame for every label (see *Teacher pose reads*), a tracked
mount's teacher aimed from the mount of the step before (see *Mount
updates*), and a target naming the asset's only body raised a
`TypeError`, since Isaac Lab resolves body ids that cover every body to
a slice.

## Gaze modes (`isaaclab_fovi.mdp`)

`GazeActionCfg.mode` chooses what the gaze actions turn:

- `"software"` (the default, unchanged): the retina.
- `"physical"`: the rig's joints; each step adds to their last targets,
so a lagging head still reaches every command.
- `"hybrid"`: the retina at once, while the rig turns the camera after
it by at most `GazeRigCfg.max_step_deg` per step and the fixation holds
in the world.
- `"dual"` (experimental): four actions, the joints as in physical gaze
and then the retina, independently.

The `GazeAction` docstring and the Foveated Camera page describe each
mode in full. `GazeRigCfg` names the articulation and its pan and tilt
joints. The rig modes need `mount="tracked"` and a camera without image
roll. With a rig, `gaze_state` reports the fixation's direction from the
rig's zero pose, the head's turn composed with the retina's, so the
observation means the same in every mode. In physical gaze the retina
stays where the gaze action leaves it, on the optical axis, unless
something sets it directly with `FoveatedCamera.set_gaze_angles`; in
hybrid gaze such a call starts a new fixation, which
`FoveatedCamera.gaze_writes` lets the action tell apart from its own
writes.

`gaze_teacher_labels` labels from where the next step starts: in hybrid
gaze the software gaze re-aimed at its held fixation, and in physical
gaze the head's commanded pose, so it never repeats a turn the head has
made or has yet to make. Its target body may also be named when it is
the asset's only body.

- *Teacher targets in the world.* `gaze_teacher_labels` takes
`target_w`, a function of the environment that returns each
environment's target point, as an alternative to `target_cfg`. A target
chosen per environment, such as the object a command picks among
several, is not a point fixed to one asset.
- *Teacher pose reads.* The teacher took the camera's position from
`camera.data`, and reading a camera's data updates its image, so
labelling rendered a frame; a policy that observes every fourth control
step and labels every step rendered four frames for each one it used.
The teacher now reads the new `FoveatedCamera.mount_pos_w`, which
`update_mount` refreshes.

**Mount updates.** `FoveatedCamera.update_mount()` reads the camera's
pose and returns its mount. A lazily updated camera reads its pose only
when its data is read, so without it hybrid gaze aimed from the mount of
a step ago and the head never settled. The tracked-mount teacher from
#9074 had the same one-step lag and now uses it too.

**Tracked mounts on Isaac RTX.** A tracked mount needed a renderer that
turns the camera's pose by the gaze, so the rig modes ran only on Newton
and OVRTX. An Isaac RTX camera holds its gaze in its prim, relative to
the prim's parent, so it already follows a moving mount; only the
recorded mount was missing. `update_mount` now reads it back from the
prim, without the gaze, and `mount="tracked"` works with every renderer.

## Binocular gaze (`isaaclab_fovi.mdp`)

- `BinocularGazeActionCfg` moves two eyes with three actions: the
**version**, their shared line of sight (tilt, pan), and the
**vergence**, the angle between their lines of sight. Each eye turns
from the version by half the vergence, toward the other eye, in the
plane that holds the version and the baseline, so the two lines of sight
always meet; the farther the fixation, the smaller the vergence.
- The version moves as a single camera's gaze does in `"software"`,
`"physical"` or `"hybrid"` gaze; the vergence always turns the retinas.
Both are in field radii, and the vergence stays between zero (parallel)
and `vergence_limit`.
- `binocular_gaze_state` observes the version, the vergence and their
velocities; with a rig, the version is its direction from the rig's zero
pose, as for `gaze_state`.
- `binocular_gaze_teacher_labels` labels the actions that fixate a point
with both eyes: the version bisects the eyes' lines of sight to it and
the vergence is their angle. The decomposition is exact, since the two
lines of sight are symmetric about their bisector. Like
`gaze_teacher_labels`, it starts from where the next step does, takes
`target_w`, reads both eyes' positions from `mount_pos_w` without
rendering, and checks each eye's visibility with its own camera.
- `binocular_gaze_angles` turns a version, a vergence and the baseline
between the eyes into each eye's gaze without an action term, through
the same Warp function as the action's step, so code outside a
manager-based environment can drive two foveated cameras with the same
geometry.
- The eyes need one body to carry them (their prims share a parent),
parallel optical axes, and the same retina, on any renderer: Newton,
OVRTX or Isaac RTX. The rig modes also need eyes without image roll.
- The gaze actions write the rig's joint targets with a persistent
joint-id array. A list became a new device array on every write, and
with cameras rendering, a captured Newton physics step faulted on that
freed memory.

Each gaze mode has its own Warp kernel, only hybrid gaze allocates the
fixation it holds, and a Warp kernel resets the reset environments.

## Pan-tilt mount (`isaaclab_fovi.assets`)

`PAN_TILT_CFG` is FOVI-Dex's two-joint pan-tilt mount, with no visual
geometry. `spawn_pan_tilt` builds it in the stage, its three links and
its fixed, pan and tilt joints, so the package ships no USD and nothing
has to be hosted on Nucleus. It runs with or without Kit.
`PAN_TILT_CAMERA_OFFSET` places a camera on its tilting link, and
`PAN_TILT_STEREO_OFFSETS` two eyes 6.5 cm apart. Its drives are about
critically damped and settle in about 0.3 s; their armature carries the
inertia, since the links alone are too light for a stable stiff drive at
a 120 Hz physics step on MJWarp. The mount leaves gravity on: Newton
reads one body's `disable_gravity` as the whole scene's.

## Example

`isaaclab example foveated-camera` keeps its single camera and software
gaze. With `--stereo` it looks at the same YCB scene through two eyes
6.5 cm apart, which `binocular_gaze_angles` aims by a version and a
vergence:

- Below the viewer's Camera Source selector, sliders set the version
(tilt, pan) and the vergence; I/J/K/L and drags in the eyes' window turn
the version, and U/O converge and diverge the eyes. `--target` fixates
an object as the binocular teacher would, and a "Gaze to next object"
button glides both eyes onto the next object, the version and the
vergence arriving together.
- The viewer opens on a perspective view from beyond the objects that
draws each eye as an eyeball turned with its gaze, its line of sight,
and the point where they meet; a checkbox hides that overlay. A window
shows both eyes' cortical views side by side, and the camera menu offers
each eye.
- The eyeball is FOVI-Dex's
(`examples/assets/active_camera_eyeball.usda`, 0.8 MB in Git LFS, plain
preview-surface materials and no textures). It stays beside the examples
until it is uploaded to Nucleus. The viewer draws it as mesh instances,
so the eyes' own images never see it.

Both modes now light the scene by renderer. Since
#9165, Newton cameras read a dome light's intensity as
linear radiance, so the RTX-scale dome (900) washed their images out to
white; Newton now gets 1, and OVRTX and Isaac RTX keep 900. Core tasks
with RTX-scale domes, such as `reach` and `cabinet`, may be washed out
on Newton cameras the same way.

The separate `foveated-stereo` example from earlier revisions of this PR
is gone, so `isaaclab` itself is unchanged.

## Docs

"Gaze modes" and "Binocular gaze" sections on the Foveated Camera page,
each with a config example and a figure (below), plus API entries for
`GazeRigCfg`, binocular gaze, `binocular_gaze_angles` and
`isaaclab_fovi.assets`. The Binocular gaze section shows how to run
`foveated-camera --stereo`.

![Gaze
modes](https://github.com/nblauch/IsaacLab/blob/feat/isaaclab-fovi-stereo-vergence/docs/source/_static/overview/sensors/foveated_camera_gaze_modes.jpg?raw=true)

Each mode on the pan-tilt mount, simulated with Newton's MJWarp solver
at a 30 Hz policy step: the policy pans 4.5° left three times. In hybrid
gaze the fixation jumps at once and holds while the head takes over from
the retina.

![Binocular
gaze](https://github.com/nblauch/IsaacLab/blob/feat/isaaclab-fovi-stereo-vergence/docs/source/_static/overview/sensors/foveated_camera_binocular.jpg?raw=true)

Top: both eyes' 128 × 128 images at the end of each fixation. The
fixated object sits in both foveas, while nearer or farther objects fall
in different places in the two eyes. Below: the version jumps to each
object while the head turns after it, and the vergence follows the
object's distance. Hybrid gaze holds the version's direction rather than
a point, and turning the head moves the eyes, so for near objects the
teacher keeps adjusting the version and vergence while the head turns.

## Type of change

- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)

## Release backport

- [x] <!-- backport-active-release --> Backport this pull request to the
active release branch after it merges into `main`

## Validation

At 250824d (the later commit adds the demo's eyeballs and controls; its
glide was checked headless through all 17 objects, ending each with the
lines of sight within 0.3 mm of the object, and the 56 simulator-free
cases still pass after merging `main`):

- Simulator-free: the 56 cases in `test_active_gaze.py`,
`test_camera_gaze.py` and `test_camera_cfg.py` pass. New in
`test_active_gaze.py`:
- one kernel step per rig mode, and the dual observation against
quaternion composition;
- through `GazeAction` itself, a hybrid gaze set on the camera starting
a new fixation, the hybrid teacher after a head turn, and the physical
teacher on a tilted head with a turn already queued;
- a target body named by a slice, and a world-point target reaching the
gaze term with its offset;
- for binocular gaze, the lines of sight meeting at the vergence's angle
in one plane with the baseline, the vergence's limits, hybrid version
with the head following, the teacher's labels for a point ahead and one
behind, the physical and hybrid teachers after head turns, and the
rejection of eyes on two bodies;
  - `binocular_gaze_angles` against the action's step;
  - the rig, action and binocular config checks.
- All 11 Newton and Isaac RTX render cases pass; the four OptiX cases
skip without `optix`. Two new cases run on both renderers:
- `test_hybrid_gaze_turns_the_head_onto_the_fixation` pans three steps
without reading the camera between steps. It checks that the retina
leads the head, that the head and the camera's world axis end on the
fixation with the retina back on the optical axis, and that after a
reset the gaze and its observation are zero and the next step commands
the rig's default pose. It fails without `update_mount`.
- `test_binocular_gaze_fixates_a_near_point_with_both_eyes` steps the
stereo head with the teacher's labels toward a point 0.4 m away and 15°
to the left. It checks that both optical axes pass within 1 mm of the
point, that the head carries the version and the vergence matches the
distance, and that a reset restores parallel lines of sight. Flipping
the vergence's direction in the kernel fails it and the vergence unit
test.
- `foveated-camera --stereo`, built headless on Newton and on Isaac RTX:
after fixating three objects 0.5 m to 1 m away, steering, and setting
the eyes parallel, the measured angle between the lines of sight equals
the vergence and their bisector the version to within 0.0001°, and the
lines meet within 0.2 mm of each object. Both it and the single-camera
mode render normally on Newton and open in the Newton viewer.
- The joint-id fix: with list ids, 180 steps of the binocular scene in
physical or hybrid gaze, rendering both eyes with CUDA graphs on,
faulted in the first steps; with mask writes, full-buffer writes or a
persistent id array they run to the end. The pre-merge commit ad23446
faulted the same way.

Earlier, with the converted USD mount, whose links, masses, limits and
drives the spawner reproduces:

- Rollouts of all four modes on Newton + Warp reach the commanded 13.5°
(physical settles at 13.47°).
- FOVI-Dex's clutter-lift task, moved onto this gaze action: its render
smoke passes with software and physical gaze on Newton + Warp and on
PhysX + Isaac RTX, and a policy acting in four-step chunks renders once
per chunk.
- The docs build passed with warnings as errors.

Not rerun: OVRTX, the standalone-script smoke test, the contrib PPO
cases, and the docs build since the last changes (the Binocular gaze
section and the `isaaclab_fovi.assets` and `isaaclab_fovi.mdp` API
pages).

**Rig step cost.** One rig gaze step with one kernel and a runtime mode
(806a5ee) and with one kernel per mode, which also composes the head and
retina rotations (b8c47ef), on an RTX 6000 Ada with Warp 1.17 and random
actions and joints. Each kernel is launched 10 times to warm up, then
100 launches are captured in a CUDA graph, replayed 5 times, and timed
over 200 replays.

| Environments | Mode | 806a5ee | b8c47ef |
| --- | --- | --- | --- |
| 4,096 | physical | 2.53 µs | 2.73 µs |
| 4,096 | hybrid | 3.20 µs | 3.49 µs |
| 4,096 | dual | 2.35 µs | 2.49 µs |
| 65,536 | physical | 2.78 µs | 3.24 µs |
| 65,536 | hybrid | 3.94 µs | 4.31 µs |
| 65,536 | dual | 2.73 µs | 3.17 µs |

Launched from Python, either takes about 13 µs a step, which is launch
overhead. Hybrid gaze reads the camera's pose each step
(`update_mount`), which a camera read for its image that step would have
done anyway.

## Checklist

Docker and GPU tests run on demand. Push the commits you want tested,
then
comment `run-ci` on the pull request, or `run-ci ovstage` to include
kitless OVStage rendering tests for that run.

- [x] I have read and understood the [contribution
guidelines](https://isaac-sim.github.io/IsaacLab/main/source/refs/contributing.html)
- [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with
`uv run isaaclab --format`
- [x] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have validated the changed behavior with focused coverage and
applied the [test-audit
criteria](https://github.com/isaac-sim/IsaacLab/blob/HEAD/skills/developer/test-audit/SKILL.md)
to any test changes
- [x] I have added a changelog fragment under
`source/<pkg>/changelog.d/` for every touched package (do **not** edit
`CHANGELOG.rst` or bump package versions — CI handles that)
- [x] I have added my name to the `CONTRIBUTORS.md` or my name already
exists there

(cherry picked from commit eb1b21b)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

asset New asset feature or request documentation Improvements or additions to documentation infrastructure isaac-lab Related to Isaac Lab team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants