Repository navigation
Conversation
Collaborator
Author
|
run-ci |
Collaborator
Author
|
run-ci |
…pers resolve_ids resolves ids or a boolean mask to ids on a device, as resolve_1d_mask does to a mask. resolve_1d_mask takes an optional scratch mask, copies a Warp mask on another device, and accepts a boolean torch mask on its device inside a graph capture. The experimental package now re-exports it instead of keeping a copy.
…red helpers SensorBase, Camera and WrenchComposer resolve env_ids, env_mask and body_ids through resolve_ids and resolve_1d_mask instead of their own copies. The test doubles that build these objects without their initializer get the env masks a real sensor creates.
The nodal mask writers of BaseDeformableObject, which the OVPhysX deformable object inherits, and of the PhysX deformable object called wp.nonzero on a Warp array, which raised a RuntimeError. They now resolve the mask to ids with resolve_ids and call the index writers.
…sk writers through masks The Newton assets resolve ids and masks through resolve_ids and resolve_1d_mask. The RigidObjectCollection mask writers and the fixed-tendon mask setters write through the masks instead of converting them to ids, which waited for the GPU on every call; the joint-coordinate writes reuse a scratch mask; one generic masked 2-D write kernel replaces two copies.
The OVPhysX assets resolve env, body, joint and tendon selections through resolve_ids and resolve_1d_mask instead of their own copies.
The PhysX assets resolve env, body, joint and tendon selections through resolve_ids and resolve_1d_mask instead of their own copies. The sensor test doubles get the env masks a real sensor creates.
Collaborator
Author
|
run-ci |
hujc7
force-pushed
the
jichuanh/id-mask
branch
from
October 26, 2026 09:48
87c34b8 to
3d3661f
Compare
6 of 7 tasks
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Id and mask selections now resolve through two shared helpers,
resolve_idsandresolve_1d_mask, instead ofabout 30 hand-written copies across the Newton, OVPhysX and PhysX assets, sensors and the wrench composer
(−1086 / +612 source lines). Newton mask writers that converted masks to ids now write through the mask: 4-11x faster.
Description
1. Changes
isaaclab/utils/warp/utils.py)resolve_ids: ids or a boolean mask → ids on a device.resolve_1d_mask:scratch_maskis optional for callers that never pass ids; a Warp mask on another device iscopied; a boolean torch mask already on the device is accepted inside a CUDA graph capture.
isaaclab_experimental.utils.warp.resolve_1d_maskis now this function instead of a copy.SensorBase,CameraandWrenchComposer. Every selection now accepts the same inputs: any integer sequence, slices with a negative step,ids on another device (moved to the owner's device). A
ProxyArrayraisesTypeError.RigidObjectCollectionmask writers and the fixed-tendon mask setters write through the masks instead ofconverting them to ids, which waited for the GPU on every call.
write_nodal_*_to_sim_maskwriters raised aRuntimeErrorwheneverenv_maskwas given(
BaseDeformableObject, so OVPhysX, and PhysX).2. Performance
Desk RTX PRO 6000, Newton,
mainvs this PR. Micro: contract-test Newton assets, 4096 envs, host µs per callincluding the GPU wait, median of 7x300 calls, 2 alternated runs per side.
write_fixed_tendon_properties_to_sim_maskwrite_joint_position_to_sim_index/write_joint_state_to_sim_indexEnd to end,
isaaclab benchmark runtime ... presets=newton_mjwarp, 3 alternated runs per side, total FPS:Type of change
Checklist
Docker and GPU tests run on demand. Push the commits you want tested, then
comment
run-cion the pull request.pre-commitchecks withuv run isaaclab --formatsource/<pkg>/changelog.d/for every touched package (do not editCHANGELOG.rstor bump package versions — CI handles that)CONTRIBUTORS.mdor my name already exists there