Skip to content

Updates task deprecation call sites#5410

Merged
AntoineRichard merged 2 commits into
isaac-sim:developfrom
AntoineRichard:antoiner/task-deprecation-warning-cleanup
May 8, 2026
Merged

Updates task deprecation call sites#5410
AntoineRichard merged 2 commits into
isaac-sim:developfrom
AntoineRichard:antoiner/task-deprecation-warning-cleanup

Conversation

@AntoineRichard

@AntoineRichard AntoineRichard commented Apr 27, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Migrates task/contrib camera callers from TiledCamera aliases to Camera.
  • Updates task state reads and in-hand write/target helper calls to explicit APIs.
  • Bumps task/contrib changelogs and extension versions for touched packages.

Verification

  • ./isaaclab.sh -f
  • Scoped deprecated-call-site search: concrete task/contrib deprecated calls removed.

Rebased onto develop after PR #5304 merged.

@github-actions github-actions Bot added documentation Improvements or additions to documentation isaac-lab Related to Isaac Lab team labels Apr 27, 2026
@AntoineRichard AntoineRichard changed the base branch from antoiner/feat/physx-sim-bindings to develop April 27, 2026 15:40
@AntoineRichard AntoineRichard changed the title fix: update task deprecation call sites fixes update task deprecation call sites Apr 27, 2026
@AntoineRichard AntoineRichard force-pushed the antoiner/task-deprecation-warning-cleanup branch from ae8f2f4 to f228f89 Compare April 28, 2026 06:55
@AntoineRichard AntoineRichard changed the title fixes update task deprecation call sites fix: update task deprecation call sites Apr 28, 2026
@AntoineRichard AntoineRichard marked this pull request as ready for review April 28, 2026 06:55
@greptile-apps

greptile-apps Bot commented Apr 28, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR is a mechanical migration of call sites away from deprecated TiledCamera/TiledCameraCfg aliases to the canonical Camera/CameraCfg classes, and replaces deprecated state-accessor properties (root_state_w, body_link_state_w) with their explicit split counterparts. All functional substitutions are semantically equivalent: the indexed write APIs are supported by Newton (confirmed in its own test suite), cat(body_link_pose_w, body_link_vel_w) reproduces the deprecated body_link_state_w, and root_link_quat_w is the direct replacement for root_state_w[:, 3:7].

Confidence Score: 4/5

Safe to merge; all functional changes are semantically equivalent and all backends support the new APIs.

Only P2 style findings (stale "Tiled" naming in class names, field names, and function names). All logic changes are verified to be correct substitutions for deprecated APIs.

cartpole_camera_presets_env_cfg.py, cartpole_showcase/cartpole_camera/cartpole_camera_env_cfg.py, shadow_hand_vision_env_cfg.py — stale "Tiled" naming.

Important Files Changed

Filename Overview
source/isaaclab_tasks/isaaclab_tasks/direct/inhand_manipulation/inhand_manipulation_env.py Removes Newton/PhysX backend detection and hardcodes indexed write APIs; Newton supports these APIs (confirmed in Newton test suite), so the change is functionally safe.
source/isaaclab_tasks/isaaclab_tasks/manager_based/manipulation/pick_place/mdp/observations.py Replaces deprecated body_link_state_w with explicit cat(body_link_pose_w, body_link_vel_w), producing the same [N, L, 13] tensor per the base data class docstring.
source/isaaclab_tasks/isaaclab_tasks/manager_based/manipulation/dexsuite/mdp/rewards.py Replaces root_state_w[:, 3:7] with root_link_quat_w, which is semantically equivalent; root_state_w was deprecated in favour of the split properties.
source/isaaclab_contrib/isaaclab_contrib/sensors/tacsl_sensor/visuotactile_sensor.py Migrates from TiledCamera to Camera for the internal camera sensor; type annotation and instantiation are consistent.
source/isaaclab_tasks/isaaclab_tasks/direct/cartpole/cartpole_camera_presets_env_cfg.py Renames base class from TiledCameraCfg to CameraCfg but MultiDataTypeCartpoleTiledCameraCfg and inner CartpoleTiledCameraCfg retain stale "Tiled" in their class names.
source/isaaclab_tasks/isaaclab_tasks/direct/cartpole_showcase/cartpole_camera/cartpole_camera_env_cfg.py Migrates type annotations and constructor calls to CameraCfg; function get_tiled_camera_cfg retains the stale "tiled" name.
source/isaaclab_tasks/isaaclab_tasks/direct/shadow_hand/shadow_hand_vision_env_cfg.py Base config class renamed from TiledCameraCfg to CameraCfg as parent, but _ShadowHandBaseTiledCameraCfg class name keeps stale "Tiled" prefix.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Camera Call Sites] --> B{Deprecated?}
    B -- TiledCamera / TiledCameraCfg --> C[Migrate to Camera / CameraCfg]
    B -- root_state_w / body_link_state_w --> D[Migrate to explicit split props]
    B -- Newton vs PhysX write dispatch --> E[Hardcode _index APIs - both backends supported]
    C --> F[Updated: cartpole, shadow_hand, dexsuite, stack, pick_place, tacsl]
    D --> G[Updated: dexsuite/rewards.py, pick_place/observations.py]
    E --> H[Updated: inhand_manipulation_env.py]
    F & G & H --> I[Version bumps: isaaclab_tasks 1.5.30, isaaclab_contrib 0.3.1]
Loading

Comments Outside Diff (1)

  1. source/isaaclab_tasks/isaaclab_tasks/direct/cartpole/cartpole_camera_presets_env_cfg.py, line 311 (link)

    P2 Stale "Tiled" names in class hierarchy

    MultiDataTypeCartpoleTiledCameraCfg and its inner CartpoleTiledCameraCfg both reference "Tiled" in their names even though they now inherit from CameraCfg. The same pattern appears in _ShadowHandBaseTiledCameraCfg (shadow_hand_vision_env_cfg.py) and get_tiled_camera_cfg (cartpole_showcase/cartpole_camera/cartpole_camera_env_cfg.py). Field names tiled_camera / _tiled_camera also remain in several env files. Since this PR is explicitly removing deprecated tiled-camera aliases, consider renaming these symbols for consistency — leaving "Tiled" identifiers creates confusion for downstream users about which camera type is actually in use.

    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!

Reviews (1): Last reviewed commit: "docs: document task deprecation cleanup" | Re-trigger Greptile

@AntoineRichard AntoineRichard changed the title fix: update task deprecation call sites Updates task deprecation call sites Apr 28, 2026
Comment on lines -80 to +85
# bind backend-optimal write methods (Newton prefers mask-based, PhysX prefers indexed)
use_mask = "newton" in self.sim.physics_manager.__name__.lower()
if use_mask:
self._set_joint_pos_target = self.hand.set_joint_position_target
self._write_obj_root_pose = self.object.write_root_pose_to_sim
self._write_obj_root_vel = self.object.write_root_velocity_to_sim
self._write_hand_joint_pos = self.hand.write_joint_position_to_sim
self._write_hand_joint_vel = self.hand.write_joint_velocity_to_sim
else:
self._set_joint_pos_target = self.hand.set_joint_position_target_index
self._write_obj_root_pose = self.object.write_root_pose_to_sim_index
self._write_obj_root_vel = self.object.write_root_velocity_to_sim_index
self._write_hand_joint_pos = self.hand.write_joint_position_to_sim_index
self._write_hand_joint_vel = self.hand.write_joint_velocity_to_sim_index
# bind write methods
self._set_joint_pos_target = self.hand.set_joint_position_target_index
self._write_obj_root_pose = self.object.write_root_pose_to_sim_index
self._write_obj_root_vel = self.object.write_root_velocity_to_sim_index
self._write_hand_joint_pos = self.hand.write_joint_position_to_sim_index
self._write_hand_joint_vel = self.hand.write_joint_velocity_to_sim_index

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

This is the correct change. write_joint_velocity_to_sim resolves to write_joint_velocity_to_sim_index by default regardless of the framework.

@AntoineRichard

Copy link
Copy Markdown
Collaborator Author

@pbarejko @bdilinila could one of you approve this PR. It's meant to reduce the number of warnings we're seeing in CI.

@AntoineRichard AntoineRichard requested a review from pbarejko April 28, 2026 13:35

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

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🤖 Isaac Lab Review Bot

Summary

This PR migrates task and contrib modules from deprecated TiledCamera/TiledCameraCfg aliases to the canonical Camera/CameraCfg classes, and updates task state reads and simulation write calls to use explicit indexed APIs. The changes are mechanical find-and-replace operations that appear correct, though one semantic change in the inhand manipulation env removes backend-adaptive write method selection that may have performance implications.

Architecture Impact

Cross-module impact is minimal. The TiledCamera/TiledCameraCfg types were aliases pointing to Camera/CameraCfg, so this is purely a naming cleanup. The changes touch:

  • isaaclab_contrib sensors (TacSL visuotactile sensor)
  • isaaclab_tasks direct environments (cartpole, shadow_hand, inhand_manipulation)
  • isaaclab_tasks manager-based environments (cartpole, dexsuite, pick_place, stack)

The removal of backend-adaptive write methods in inhand_manipulation_env.py changes behavior but shouldn't break functionality since the indexed APIs work across backends.

Implementation Verdict

Ship it — This is a straightforward deprecation cleanup with one minor concern noted below.

Test Coverage

The existing test test_visuotactile_sensor.py is updated to use CameraCfg and provides adequate coverage for the TacSL sensor changes. However, there are no new tests added for the inhand manipulation write method changes. The CI shows isaaclab_tasks tests passing across all 3 shards, which provides confidence the changes don't break functionality.

CI Status

All relevant checks pass:

  • isaaclab_tasks [1/3], [2/3], [3/3]: success
  • isaaclab_contrib: success
  • pre-commit: success
  • environments_training: success

Multiple core tests are skipped but this appears intentional based on the change detection system.

Findings

🔵 Improvement: source/isaaclab_tasks/isaaclab_tasks/direct/inhand_manipulation/inhand_manipulation_env.py:80-84 — Removed backend-adaptive optimization

The original code selected between mask-based writes (preferred by Newton) and indexed writes (preferred by PhysX) based on the physics backend. The new code unconditionally uses indexed writes. While this is functionally correct (indexed APIs work on both backends), it may have minor performance implications on Newton. The original comment stated "Newton prefers mask-based, PhysX prefers indexed" — if this optimization was meaningful, consider documenting why it was removed or whether the indexed path is now universally optimal.

# Before: Adaptive selection based on backend
use_mask = "newton" in self.sim.physics_manager.__name__.lower()
if use_mask:
    self._set_joint_pos_target = self.hand.set_joint_position_target
    ...
else:
    self._set_joint_pos_target = self.hand.set_joint_position_target_index
    ...

# After: Always use indexed
self._set_joint_pos_target = self.hand.set_joint_position_target_index

🔵 Improvement: source/isaaclab_tasks/isaaclab_tasks/manager_based/manipulation/dexsuite/mdp/rewards.py:221 — State access change is correct but verify equivalence

The change from asset.data.root_state_w.torch[:, 3:7] to asset.data.root_link_quat_w.torch is semantically cleaner. However, verify that root_link_quat_w provides the same reference frame as the quaternion component of root_state_w. Based on Isaac Lab conventions, these should be equivalent for the root link, but confirm this doesn't change the orientation tracking reward behavior.

🔵 Improvement: source/isaaclab_tasks/isaaclab_tasks/manager_based/manipulation/pick_place/mdp/observations.py:83-90 — Explicit concatenation is clearer

The change from accessing the compound body_link_state_w to explicitly concatenating body_link_pose_w and body_link_vel_w is clearer and aligns with the PR's goal of using explicit state properties. This is a good change.

🔵 Improvement: source/isaaclab_tasks/docs/CHANGELOG.rst:4 — Changelog entry date appears to be in the future

The changelog entry shows date 2026-04-27 which appears to be a placeholder or future date. This should be updated to the actual merge date. (Same issue in source/isaaclab_contrib/docs/CHANGELOG.rst:4)

🔵 Improvement: source/isaaclab_contrib/docs/README.md:259,291 — Documentation update is complete

The README documentation correctly updates both the import statement and the usage example to use CameraCfg instead of TiledCameraCfg. Good attention to documentation consistency.

from isaaclab.envs import DirectRLEnvCfg, ViewerCfg
from isaaclab.scene import InteractiveSceneCfg
from isaaclab.sensors import TiledCameraCfg
from isaaclab.sensors import CameraCfg

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.

There is a separate MR that does this: #5377

@kellyguo11

Copy link
Copy Markdown
Contributor

I think we can merge #5377 first and rebase this one on top. This seems to cover some additional updates than just the cameras. but 5377 had more thorough coverage of the camera APIs.

@kellyguo11 kellyguo11 moved this to In review in Isaac Lab May 3, 2026
@AntoineRichard AntoineRichard force-pushed the antoiner/task-deprecation-warning-cleanup branch from a747e6d to c35a47b Compare May 8, 2026 10:21
@AntoineRichard AntoineRichard merged commit 513a017 into isaac-sim:develop May 8, 2026
54 of 56 checks passed
@github-project-automation github-project-automation Bot moved this from In review to Done in Isaac Lab May 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation isaac-lab Related to Isaac Lab team

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants