-
Notifications
You must be signed in to change notification settings - Fork 3.9k
[FEAT] Add OVPhysX support to Franka deformable lift tasks #7077
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
4a2f355
4fab654
325881a
77171bc
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| Added | ||
| ^^^^^ | ||
|
|
||
| * Added OVPhysX presets for the Franka soft-body and cloth lift tasks, including their camera | ||
| variants. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -16,6 +16,7 @@ | |
| ) | ||
| from isaaclab_newton.sim.schemas import NewtonDeformableBodyPropertiesCfg | ||
| from isaaclab_newton.sim.spawners.materials import NewtonDeformableBodyMaterialCfg | ||
| from isaaclab_ov.physics import OvPhysxCfg | ||
| from isaaclab_physx.physics import PhysxCfg | ||
| from isaaclab_physx.sim.schemas import PhysxCollisionCfg, PhysxDeformableBodyPropertiesCfg | ||
| from isaaclab_physx.sim.spawners.materials import PhysxDeformableBodyMaterialCfg | ||
|
|
@@ -50,7 +51,7 @@ | |
| CouplerProxyMappingCfg, | ||
| ) | ||
|
|
||
| from isaaclab_tasks.utils import PresetCfg | ||
| from isaaclab_tasks.utils import PresetCfg, preset | ||
| from isaaclab_tasks.utils.presets import MultiBackendRendererCfg | ||
|
|
||
| from ... import mdp | ||
|
|
@@ -135,6 +136,7 @@ class DeformableCfg(PresetCfg): | |
| ), | ||
| ) | ||
| isaacsim_physx = physx | ||
| ovphysx = physx | ||
|
|
||
| default = newton_mjwarp_vbd_proxy | ||
|
|
||
|
|
@@ -185,8 +187,9 @@ class PhysicsCfg(PresetCfg): | |
| ) | ||
|
|
||
| isaacsim_physx: PhysxCfg = PhysxCfg() | ||
| ovphysx: OvPhysxCfg = OvPhysxCfg() | ||
|
|
||
| physx: PhysxAutoCfg = PhysxAutoCfg(isaacsim_physx=isaacsim_physx) | ||
| physx: PhysxAutoCfg = PhysxAutoCfg(isaacsim_physx=isaacsim_physx, ovphysx=ovphysx) | ||
|
|
||
| default = newton_mjwarp_vbd_proxy | ||
|
|
||
|
|
@@ -609,9 +612,10 @@ class FrankaSoftSceneCfg(PresetCfg): | |
| num_envs=2048, env_spacing=2.0, replicate_physics=True | ||
| ) | ||
|
|
||
| # PhysX does not support replicating physics for deformable objects | ||
| # Isaac Sim PhysX does not support replicating physics for deformable objects | ||
| physx: _FrankaSoftSceneCfg = _FrankaSoftSceneCfg(num_envs=2048, env_spacing=2.0, replicate_physics=False) | ||
| isaacsim_physx = physx | ||
| ovphysx: _FrankaSoftSceneCfg = _FrankaSoftSceneCfg(num_envs=2048, env_spacing=2.0, replicate_physics=True) | ||
|
|
||
| default = newton_mjwarp_vbd_proxy | ||
|
|
||
|
|
@@ -625,6 +629,9 @@ class FrankaSoftCameraSceneCfg(PresetCfg): | |
| ) | ||
| physx: _FrankaSoftCameraSceneCfg = _FrankaSoftCameraSceneCfg(num_envs=128, env_spacing=2.0, replicate_physics=False) | ||
| isaacsim_physx = physx | ||
| ovphysx: _FrankaSoftCameraSceneCfg = _FrankaSoftCameraSceneCfg( | ||
| num_envs=128, env_spacing=2.0, replicate_physics=True | ||
| ) | ||
| default = newton_mjwarp_vbd_proxy | ||
|
|
||
|
|
||
|
|
@@ -660,6 +667,25 @@ def __post_init__(self) -> None: | |
| self.sim.render_interval = self.decimation | ||
| self.sim.physics = PhysicsCfg() | ||
|
|
||
| # OVPhysX does not expose a runtime gravity setter. | ||
| default_events = self.events | ||
| self.events = preset( | ||
| default=default_events, | ||
| physx=default_events, | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
When a Kit-less training run selects the broad Knowledge Base Used: isaaclab_tasks: Task Registration and Organization |
||
| isaacsim_physx=default_events, | ||
| newton_mjwarp_vbd_proxy=default_events, | ||
| ovphysx=default_events.replace(variable_gravity=None), | ||
| ) | ||
| if self.curriculum is not None: | ||
| default_curriculum = self.curriculum | ||
| self.curriculum = preset( | ||
| default=default_curriculum, | ||
| physx=default_curriculum, | ||
| isaacsim_physx=default_curriculum, | ||
| newton_mjwarp_vbd_proxy=default_curriculum, | ||
| ovphysx=default_curriculum.replace(gravity=None), | ||
| ) | ||
|
|
||
| self.viewer.eye = (0.75, 0.25, 0.65) | ||
| self.viewer.lookat = (0.0, 0.75, 0.4) | ||
| self.sim.default_visualizer_cfg = _FrankaSoftVisualizerCfg( | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🟡 Warning · Design Architecture — Auto physx preset keeps unsupported gravity terms
PhysxAutoCfgnow also carriesovphysx(and likewise at line 97 in the cloth config), so selecting the genericphysxpreset can resolve to OVPhysX. The new events/curriculum presets mapphysxto the unmodified configs (lines 663, 672), leavingvariable_gravityand the gravity curriculum active on a backend that this PR states has no runtime gravity setter. Mapphysxto the gravity-free variants, or key the workaround on the resolved backend.