Skip to content

Migrate the default Docker runtime to cuRoboV2 - #1514

Closed
qianl-nv wants to merge 4 commits into
mainfrom
qianl/feature/curobo-v2
Closed

qianl-nv wants to merge 4 commits into
mainfrom
qianl/feature/curobo-v2

Conversation

@qianl-nv

@qianl-nv qianl-nv commented Oct 23, 2026 •

Copy link
Copy Markdown
Collaborator

Update Arena to cuRoboV2 and its cuda.core runtime backend. Include cuRobo in the default developer image and remove the separate cuRobo image variant.

Why this change?

The pinned cuRobo revision uses APIs removed by Warp 1.17 and requires a separate CUDA extension build. Current cuRobo supports Warp 1.17 and compiles kernels at runtime through cuda.core.

Keeping cuRobo in a separate image also duplicates Docker build, test, and publication paths for functionality used by Arena's placement reachability validation.

What changes?

  • Pin cuRobo main at 78fd485fa82d9b9a063fb4985e371814587e666a with its CUDA 13 runtime dependencies.
  • Remove the stale proprietary cuRobo-license.txt; the pinned upstream cuRoboV2 revision is Apache-2.0, and the installed nvidia-curobo distribution includes its Apache license under *.dist-info/licenses/LICENSE.
  • Replace the v1 IK, device, pose, and world APIs with the cuRoboV2 public APIs.
  • Convert Arena's existing DROID robot configuration fields to the cuRoboV2 schema when loading them.
  • Install cuRobo in the default dev image through uv and remove the CUDA toolkit, wheel-builder, and runtime-wheel installation stages.
  • Remove the dev-curobo target and the -c options from Docker launch and publication scripts.
  • Run the cuRobo checks against the default CI image and require them before publishing :latest.
  • Update setup guidance and examples to use ./docker/run_docker.sh for cuRobo workflows.

The native uv environment still does not install cuRobo. This change affects the Docker workflow only. uv support for curobo will be added in a follow up PR.

Usage example

Before:

./docker/run_docker.sh -c

After:

./docker/run_docker.sh

Validation

  • Built the default dev Docker image successfully.
  • Passed all 35 focused curobo_deps tests.
  • Ran a real DROID IK solve using the cuda.core backend.
  • Updated a DROID collision world, ran collision-aware IK, and generated robot collision spheres.
  • Passed pre-commit on all changed files.

Compared documented agentic-environment-generation ik_reachable pass rates with live runs in isaaclab_arena:curobo-v2-dev:

Workflow Documented Live cuRoboV2 Difference Result
Homogeneous tabletop 8/42 (19.05%) 5/39 (12.82%) -6.23 pp Completed
Heterogeneous tabletop 478/597 (80.07%) 468/592 (79.05%) -1.01 pp IK measured; 12-env policy startup later exhausted 24 GB GPU memory
Composite tabletop 6/36 (16.67%) 5/62 (8.06%) -8.60 pp Completed; live result aggregates 1/35 and 4/27 retry batches
Kitchen pick-and-place 15/44 (34.09%) 21/42 (50.00%) +15.91 pp Completed

The 600-candidate heterogeneous case provides the strongest parity signal and differs by 1.01 percentage points. The 50-candidate cases have wider sampling variability, so exact count equality is not expected.

Placement reachability visualization

Collected deterministic Maple-table placement samples with:

python isaaclab_arena/scripts/environment_runner.py \
  --env_spec isaaclab_arena/tests/test_data/placement_debug_view_env_graph.yaml

For collection, max_placement_attempts was set to 25 and placement_seed to 42, then restored. Of 125 candidates, 124 reached IK after geometry checks. The cube was reachable in 98/124 poses, the bowl in 122/124 poses, and both targets were reachable in 96/124 layouts.

Object and destination IK reachability heatmap

The six isolated red cube samples are not one stable unreachable region. Layouts 11, 16, 48, 75, and 103 place the cube close enough to the bowl that two active robot collision spheres enter cuRobo's 10 mm collision-activation margin; removing the bowl obstacle makes all five reachable. Layout 68 has no nearby bowl collision and succeeds when replayed, indicating seed/convergence variability near the IK threshold. The cube heatmap projects away the independently varying bowl position, so neighboring points do not represent identical collision worlds.

Reachable example (layout 1; both targets reachable):

Reachable placement in Rerun

Unreachable example (layout 93; destination unreachable):

Unreachable placement in Rerun

@qianl-nv
qianl-nv force-pushed the qianl/feature/curobo-v2 branch from 8f55cd9 to 4e0c340 Compare October 26, 2026 11:29
@qianl-nv
qianl-nv changed the base branch from main to qianl/chore/reduce-docker-venv-layer October 26, 2026 11:40
@qianl-nv
qianl-nv force-pushed the qianl/feature/curobo-v2 branch 2 times, most recently from 4d355f6 to bd33df5 Compare October 26, 2026 12:20
@qianl-nv
qianl-nv marked this pull request as ready for review October 26, 2026 12:20
@greptile-apps

greptile-apps Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The change reaches Docker users who run placement workflows and the CI image workflow.

The PR appears safe to merge, with non-blocking gaps in automated GPU coverage and Docker upgrade guidance.

Findings

  1. P2 Real solves go unchecked ▶
  2. P2 Docker upgrade step is missing ▶

Summary

Moves cuRoboV2 into the default Docker image and updates Arena’s solver calls and DROID configuration.

  • Arena's placement reachability checks use cuRoboV2's solver and robot formats.
  • The default Docker image now includes cuRobo, so placement checks need no separate image.

The removal of the separate image variant and proprietary license is intentional, as stated in the PR description supplied for qianl-nv; neither is treated as a defect.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  A[Default dev image] --> B[Main test job]
  B --> C[cuRobo checks]
  C --> D[Publish latest]
  A --> E[cuRoboV2 solver]
  E --> F[Placement reachability]
Loading

Reviews (1) · Last reviewed commit: "Add native cuRoboV2 DROID configuration" · Reviewed by Greptile

Comment on lines +102 to +114
def solve_pose(self, goal_tool_poses, seed_config=None) -> _FakeIKResult:
config = self.kinematics.config.kinematics_config
self.radii_during_solve = {name: config.radius(name) for name in config.link_name_to_idx_map}
if self._raises:
raise RuntimeError("solve blew up")
return _FakeIKResult(goal_pose.position.shape[0], self._success)
return _FakeIKResult(goal_tool_poses.batch_size, self._success)

def compute_kinematics(self, joint_state):
"""Return one set of link spheres per given joint configuration."""
config = self.kinematics.config.kinematics_config
spheres = torch.stack([config.get_link_spheres(name)[0] for name in config.link_name_to_idx_map])
batch_spheres = spheres.expand(joint_state.position.shape[0], 1, -1, -1)
return type("_State", (), {"robot_spheres": batch_spheres})()

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.

P2 Real solves go unchecked

The updated tests replace solve_pose and compute_kinematics with fakes. The dependency checks only import modules and inspect YAML. No test builds the real solver, updates its world, or solves a pose, so CI does not check the new runtime or tensor shapes before publishing the default image. Turn the manual GPU validation into a small repeatable smoke test.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Comment on lines 120 to +122
The container will build (if needed) and drop you into an interactive shell.

For :doc:`cuRobo-based reachability validation
</pages/concepts/object_placement/validation>`, launch with the ``-c`` flag
instead (native ``uv`` installs do not support this check):

:docker_run_curobo:
The default image includes :doc:`cuRobo-based reachability validation
</pages/concepts/object_placement/validation>`; native ``uv`` installs do not support this check.

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.

P2 Docker upgrade step is missing

If a user already has the old isaaclab_arena:latest image, the new default launcher reuses it without rebuilding. That image lacks cuRobo, despite the promise here. The launcher also attaches to an existing running container. Add a one-time upgrade note telling users to stop the old container and rebuild with ./docker/run_docker.sh -r.

position_threshold=position_threshold,
rotation_threshold=rotation_threshold,
position_tolerance=position_threshold,
orientation_tolerance=rotation_threshold,

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.

🟡 Same rotation threshold, about half the angle

The two cuRobo versions measure rotation error differently:

  • v1 reported rotation_error as |sin(θ/2)|, the length of the error quaternion's vector part (pose_distance_kernel.cu).
  • v2 reports the angle θ in radians (curobo/_src/cost/wp_tool_pose.py: angle = 2.0 * wp.atan2(...), stored as geometric_rotation_distance).

ik_rotation_threshold_rad = 0.1 feeds both orientation_tolerance here and the check in solve_ik_feasibility. It used to accept up to about 0.20 rad (11.5°) and now accepts 0.1 rad (5.7°).

Is the tighter check intended?

  • If not, doubling the defaults keeps the v1 behavior: ReachabilityConfig.ik_rotation_threshold_rad 0.1 → 0.2, and the CuroboIKSolver default 0.05 → 0.1.
  • If it is, could the PR description say so? It may explain part of the lower pass rates in the parity table.

with _disabled_link_spheres(ik_solver, muted_links):
ik_result = ik_solver.solve_batch(goal_pose, seed_config=ik_seed)
goal_tool_poses = GoalToolPose.from_poses({ik_solver.tool_frames[0]: goal_pose})
ik_result = ik_solver.solve_pose(goal_tool_poses, seed_config=ik_seed)

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.

🟡 v2 solve_pose accepts only one pose here

InverseKinematicsCfg.create defaults to max_batch_size=1, and solve_pose raises when goal_tool_poses.batch_size is larger (curobo/_src/solver/solver_ik.py:671). CuroboIKSolver doesn't set it, so solve_ik_feasibility, which is documented for (b, 4, 4), now fails for b > 1.

Nothing breaks today, because the validator sends one pose at a time. The unit tests use two poses (_identity_grasps()), though, and pass only because _FakeIKSolver.solve_pose accepts any batch size.

Could we do one of these?

  • Pass max_batch_size through CuroboIKSolver.__init__.
  • Make the single-pose contract explicit: assert target_poses.shape[0] == 1, update the docstring, and use one pose in the test fixtures.

RUN --mount=type=cache,target=/root/.cache/uv \
--mount=type=bind,source=docker/setup/repair_venv_permissions.sh,target=/tmp/repair_venv_permissions.sh \
uv pip install \
"nvidia-curobo[cu13] @ git+https://github.com/NVlabs/curobo.git@${CUROBO_COMMIT}" && \

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.

🟡 ik_reachable now runs by default in Docker

isaaclab_arena_curobo/__init__.py registers ik_reachable whenever cuRobo imports, and ObjectPlacerParams runs and requires every registered check by default. With cuRobo in the default image, every DROID pick-and-place spec that doesn't set placer_params (kitchen_bench, maple_table_top, robolab) now rejects unreachable layouts in Docker but not in native uv.

The same spec and placement_seed therefore give different layouts depending on the install route. Each environment build also now pays for a solver build and per-candidate IK.

Should ik_reachable become opt-in, for example via placer_params.enabled_checks, now that installing cuRobo no longer means someone asked for it? If the new default is intended, could the PR description and release notes say so?

ARG CUROBO_COMMIT=78fd485fa82d9b9a063fb4985e371814587e666a
RUN --mount=type=cache,target=/root/.cache/uv \
--mount=type=bind,source=docker/setup/repair_venv_permissions.sh,target=/tmp/repair_venv_permissions.sh \
uv pip install \

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.

🔵 cuRobo is installed outside Arena's lock

The removed install_curobo_runtime_deps.sh held torch, numpy, warp-lang and a few other packages at Isaac Sim's versions with pip constraints. This step now relies on cuRobo's current requirements happening to match.

There is already one mismatch:

  • viser, a cuRobo dependency, requires rich<15.
  • uv.lock pins rich==15.0.0, which comes in through pytetwild[all].
  • The later uv sync --frozen --inexact restores 15.0.0, so the image would likely end up with an unmet requirement.

Could we do one of these?

  • Keep a constraints file for the Isaac Sim pins here.
  • Add cuRobo as an optional dependency in pyproject.toml, so uv.lock resolves it together with everything else. The planned uv follow-up will need that anyway.

./docker/run_docker.sh"""

# Docker run with Curobo dependencies
# Keep the cuRobo marker as an alias now that the default image includes cuRobo.

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.

🔵 Unused :docker_run_curobo: alias

After this PR no page uses :docker_run_curobo:, so curobo_replacer and its re.sub line are dead code. Could we delete them instead of keeping an alias?


For native ``uv``, ``isaaclab_arena_curobo`` is not installed; use the Docker
container with ``-c`` if you need
For native ``uv``, ``isaaclab_arena_curobo`` is not installed; use the default Docker

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.

🔵 It's cuRobo that's missing in native uv

isaaclab_arena_curobo is part of the native install: it's in the pyproject.toml package list and test_packaging.py checks it. Only curobo itself is missing. Suggest matching the wording in installation.rst:

Suggested change
For native ``uv``, ``isaaclab_arena_curobo`` is not installed; use the default Docker
For native ``uv``, cuRobo is not installed; use the default Docker


kinematics = robot_cfg_utils.load_robot_yaml(config)["robot_cfg"]["kinematics"]

assert kinematics["format_version"] == 2.0

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.

🔵 Leftover assertions from the conversion step

load_robot_yaml now only overwrites urdf_path. The format_version, tool_frames, grasp_contact_link_names and cspace assertions therefore only check that yaml.safe_load reads the fixture back unchanged.

Could we keep just the urdf_path assertion and trim the fixture to match? The module docstring also still says "pure import checks", which is no longer true.

@arena-review-bot

Copy link
Copy Markdown
Contributor

🤖 Isaac Lab-Arena Review Bot

Summary

This PR moves isaaclab_arena_curobo to the cuRoboV2 API and adds a native v2 DROID config. It also installs cuRobo in the default dev image and removes the dev-curobo target, its CI jobs, and the -c/-t launcher options. Dropping the separate image and the CUDA toolkit build is a good simplification. Two v2 behavior differences aren't handled yet, though: rotation-error units changed, and solve_pose now has a batch cap. Installing cuRobo by default also changes placement for DROID environments in Docker.

Design, Boundaries & Scope

  • Reachability checks become the Docker default.
    • Why: isaaclab_arena_curobo/__init__.py registers ik_reachable whenever cuRobo imports, and ObjectPlacerParams runs and requires every registered check by default.
    • Effect: with this PR, DROID pick-and-place specs that don't set placer_params will reject unreachable layouts in Docker but not in native uv. That covers almost every DROID spec under isaaclab_arena_environments/: kitchen_bench, maple_table_top, and robolab. The same spec and seed then produce different layouts depending on the install route, which works against the reproducibility that pooled_placement.rst describes.
    • Cost: every DROID environment build in Docker now also builds a solver and runs IK for each candidate. This includes CI tests such as test_relation_placement_from_yaml.py.
    • Memory: the PR notes a 12-env run that ran out of 24 GB of GPU memory at policy startup. The solver stays referenced from the placement event term for the env's lifetime, so is it worth checking how much of that memory it holds?
    • See the inline comment on the Dockerfile for the question of whether this should be opt-in.
  • Old local images lose reachability checks without warning. run_docker.sh reuses an existing isaaclab_arena:latest. Anyone with an image built before this change gets no cuRobo, and ik_reachable is dropped silently because the ImportError is swallowed. A one-line "rebuild once with -r" note in installation.rst would help.
  • Infra changes. This touches docker/ and .github/workflows/, and removes the -c/-t options, so existing run_docker.sh -c calls now fail as unknown options. That's fine for alpha, but worth a release note.

Findings

🟡 Warning: isaaclab_arena_curobo/ik_solver.py:90 — v1 reported rotation error as |sin(θ/2)| and v2 reports θ in radians. The same 0.1 threshold therefore now accepts about 5.7° instead of about 11.5°, in both cuRobo's success and Arena's own check. Is this intended?
🟡 Warning: isaaclab_arena_curobo/utils/ik_solver_utils.py:150 — v2 solve_pose raises for more than max_batch_size poses, and the default is 1. solve_ik_feasibility is documented for (b, 4, 4), and the fake-based tests use two poses.
🟡 Warning: docker/Dockerfile.isaaclab_arena:63 — installing cuRobo by default turns on ik_reachable gating for DROID environments in Docker only.
🔵 Improvement: docker/Dockerfile.isaaclab_arena:62 — cuRobo is now installed without the constraints that used to protect Isaac Sim's pinned packages. viser, which cuRobo depends on, needs rich<15, but the later uv sync restores the locked rich 15.0.0.
🔵 Improvement: docs/_ext/isaaclab_arena_doc_tools.py:86 — no page uses the :docker_run_curobo: alias anymore.
🔵 Improvement: docs/pages/example_workflows/agentic_env_gen/index.rst:123 — isaaclab_arena_curobo is part of the native uv install. Only curobo itself is missing.
🔵 Improvement: isaaclab_arena_curobo/tests/test_curobo_deps.py:89 — the leftover assertions from the removed conversion step only check that the YAML loads back unchanged.

The PR description still says Arena "converts the existing DROID robot configuration fields to the cuRoboV2 schema when loading them". The final commit ships a native v2 YAML instead.

Test Coverage and CI Cost

  • The cuRobo test step doesn't exercise real cuRobo. The curobo_deps step runs only import checks, YAML reads, and fakes. _FakeIKSolver.solve_pose accepts any batch size, so the v2 batch cap went unnoticed.
  • Real v2 calls run only indirectly. test_relation_placement_from_yaml.py builds a DROID pick-and-place env in the PhysX phase. It checks object positions, not reachability results.
  • Suggestion: add one small real-solver test to the cuRobo step, without a SimulationApp:
    • build CuroboIKSolver(DROID_CUROBO_CFG) once;
    • call update_world with one cuboid;
    • assert that one reachable single pose passes and one out-of-reach pose fails.
    • Cost: one solver build, runtime kernel compilation, and the URDF download.
    • Payoff: it pins the v2 API on future cuRobo bumps. Adding a pose with a known rotation offset would also pin what the rotation threshold means.
  • CI status unknown: when I reviewed, the image build for this head was still running and the test jobs hadn't reported, so I couldn't confirm CI results.

Verdict

Minor fixes needed

Base automatically changed from qianl/chore/reduce-docker-venv-layer to main October 26, 2026 17:25
Signed-off-by: Qian Lin <qianl@nvidia.com>
Signed-off-by: Qian Lin <qianl@nvidia.com>
Signed-off-by: Qian Lin <qianl@nvidia.com>
Signed-off-by: Qian Lin <qianl@nvidia.com>
@qianl-nv
qianl-nv force-pushed the qianl/feature/curobo-v2 branch from bd33df5 to cb2552d Compare October 26, 2026 17:51
xyao-nv added a commit that referenced this pull request Oct 28, 2026
Make cuRobo v2 a locked Arena dependency (nvidia-curobo[cu13], pinned to
NVlabs/curobo@78fd485 through tool.uv.sources), so the native uv install
and the Docker image both get the same cuRobo from uv.lock under the
existing torch/numpy/warp overrides. The lock adds cuRobo and its
runtime deps; the only version change is rich 15.0.0 -> 14.3.4, which
cuRobo's viser dependency requires.

With cuRobo installed everywhere, drop the separate dev-curobo image:
remove the cuRobo builder stage, its scripts, the -c launcher flag and
the cuRobo-only CI job. Docs and the setup-arena skill now describe
ik_reachable validation as available in both routes, and the agentic
env-gen workflow pages show the cuRobo v2 placement output.

Docker, CI, launcher, docs and skill changes adapted from #1514.

Co-authored-by: Qian Lin <qianl@nvidia.com>
Signed-off-by: Xinjie Yao <xyao@nvidia.com>
@qianl-nv

Copy link
Copy Markdown
Collaborator Author

moving to #1550

@qianl-nv qianl-nv closed this Oct 29, 2026
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