Skip to content
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -966,8 +966,7 @@ jobs:
# (dexterous, many contacts). Deformable/MPM kernels are not covered;
# widen if a test job reports large cache growth.
include-files: >-
test_environments.py,
test_environments_newton.py
test_environments.py
# No Soft/Cloth: the deformable envs depend on optional extras the CI
# image does not install (Soft needs pytetwild), so they only ever fail.
test-k-expr: "Cartpole or Drawer or AnymalD or Handover"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Changed
^^^^^^^

* **Breaking:** Changed the Ant, Humanoid, and Velocity task families to use
Newton MJWarp by default. Pass an explicit physics preset to retain Isaac Sim PhysX.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ class AntPhysicsCfg(PresetCfg):
isaacsim_physx: PhysxCfg = PhysxCfg(bounce_threshold_velocity=0.2)
ovphysx: OvPhysxCfg = OvPhysxCfg()
physx: PhysxAutoCfg = PhysxAutoCfg(isaacsim_physx=isaacsim_physx, ovphysx=ovphysx)
default = isaacsim_physx
newton_mjwarp: NewtonCfg = NewtonCfg(
solver_cfg=MJWarpSolverCfg(
njmax=45,
Expand All @@ -50,6 +49,7 @@ class AntPhysicsCfg(PresetCfg):
debug_mode=False,
use_cuda_graph=True,
)
default = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ class AntPhysicsCfg(PresetCfg):
isaacsim_physx: PhysxCfg = PhysxCfg(bounce_threshold_velocity=0.2)
ovphysx: OvPhysxCfg = OvPhysxCfg()
physx: PhysxAutoCfg = PhysxAutoCfg(isaacsim_physx=isaacsim_physx, ovphysx=ovphysx)
default: PhysxCfg = isaacsim_physx
newton_mjwarp: NewtonCfg = NewtonCfg(
solver_cfg=MJWarpSolverCfg(
njmax=45,
Expand All @@ -54,6 +53,7 @@ class AntPhysicsCfg(PresetCfg):
debug_mode=False,
use_cuda_graph=True,
)
default: NewtonCfg = newton_mjwarp


@configclass
Expand Down Expand Up @@ -143,8 +143,8 @@ def __post_init__(self):
class AntObservationsCfg(PresetCfg):
physx: ObservationsCfg = ObservationsCfg()
isaacsim_physx: ObservationsCfg = physx
default: ObservationsCfg = isaacsim_physx
newton_mjwarp: ObservationsCfg = ObservationsCfg()
default: ObservationsCfg = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ class HumanoidPhysicsCfg(PresetCfg):
isaacsim_physx: PhysxCfg = PhysxCfg(bounce_threshold_velocity=0.2)
ovphysx: OvPhysxCfg = OvPhysxCfg()
physx: PhysxAutoCfg = PhysxAutoCfg(isaacsim_physx=isaacsim_physx, ovphysx=ovphysx)
default = isaacsim_physx
newton_mjwarp: NewtonCfg = NewtonCfg(
solver_cfg=MJWarpSolverCfg(
njmax=80,
Expand All @@ -42,6 +41,7 @@ class HumanoidPhysicsCfg(PresetCfg):
num_substeps=2,
debug_mode=False,
)
default = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ class HumanoidPhysicsCfg(PresetCfg):
isaacsim_physx: PhysxCfg = PhysxCfg(bounce_threshold_velocity=0.2)
ovphysx: OvPhysxCfg = OvPhysxCfg()
physx: PhysxAutoCfg = PhysxAutoCfg(isaacsim_physx=isaacsim_physx, ovphysx=ovphysx)
default: PhysxCfg = isaacsim_physx
newton_mjwarp: NewtonCfg = NewtonCfg(
solver_cfg=MJWarpSolverCfg(
njmax=80,
Expand All @@ -62,6 +61,7 @@ class HumanoidPhysicsCfg(PresetCfg):
num_substeps=2,
debug_mode=False,
)
default: NewtonCfg = newton_mjwarp


##
Expand Down Expand Up @@ -147,8 +147,8 @@ def __post_init__(self):
class HumanoidObservationsCfg(PresetCfg):
physx: ObservationsCfg = ObservationsCfg()
isaacsim_physx: ObservationsCfg = physx
default: ObservationsCfg = isaacsim_physx
newton_mjwarp: ObservationsCfg = ObservationsCfg()
default: ObservationsCfg = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class PhysicsCfg(PresetCfg):
debug_mode=False,
)
newton_kamino = NewtonCfg(solver_cfg=KaminoPADMMSolverCfg(max_contacts_per_world=64))
default = isaacsim_physx
default = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class PhysicsCfg(PresetCfg):
debug_mode=False,
)
newton_kamino = NewtonCfg(solver_cfg=KaminoPADMMSolverCfg(max_contacts_per_world=64))
default = isaacsim_physx
default = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class PhysicsCfg(PresetCfg):
debug_mode=False,
)
newton_kamino = NewtonCfg(solver_cfg=KaminoPADMMSolverCfg(max_contacts_per_world=64))
default = isaacsim_physx
default = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class PhysicsCfg(PresetCfg):
debug_mode=False,
)
newton_kamino = NewtonCfg(solver_cfg=KaminoPADMMSolverCfg(max_contacts_per_world=64))
default = isaacsim_physx
default = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class PhysicsCfg(PresetCfg):
debug_mode=False,
)
newton_kamino = NewtonCfg(solver_cfg=KaminoPADMMSolverCfg(max_contacts_per_world=64))
default = isaacsim_physx
default = newton_mjwarp


@configclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ class RoughPhysicsCfg(PresetCfg):
debug_mode=False,
default_shape_cfg=NewtonShapeCfg(margin=0.0, ke=160000.0, kd=1100.0),
)
default = isaacsim_physx
default = newton_mjwarp


##
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
@pytest.mark.parametrize(
"task_name",
setup_environment(
include_play=False, factory_envs=False, multi_agent=False, teleop_envs=False, cartpole_showcase_envs=True
factory_envs=False, multi_agent=False, teleop_envs=False, cartpole_showcase_envs=True
),
)
@pytest.mark.isaacsim_ci
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
@pytest.mark.parametrize(
"task_name",
setup_environment(
include_play=False, factory_envs=False, multi_agent=False, teleop_envs=False, cartpole_showcase_envs=True
factory_envs=False, multi_agent=False, teleop_envs=False, cartpole_showcase_envs=True
),
)
def test_cartpole_showcase_environments_with_stage_in_memory_and_clone_in_fabric_disabled(task_name, num_envs, device):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
@pytest.mark.parametrize(
"task_name",
setup_environment(
include_play=False,
multi_agent=False,
factory_envs=False,
cartpole_showcase_envs=False,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@
@pytest.mark.parametrize(
"task_name",
setup_environment(
include_play=False,
factory_envs=False,
multi_agent=False,
teleop_envs=False,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@

@pytest.mark.parametrize("num_envs, device", [(2, "cuda"), (1, "cuda")])
@pytest.mark.parametrize(
"task_name", setup_environment(include_play=False, factory_envs=False, multi_agent=False, teleop_envs=True)
"task_name", setup_environment(factory_envs=False, multi_agent=False, teleop_envs=True)
)
@pytest.mark.isaacsim_ci
def test_teleop_environments(task_name, num_envs, device):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

@pytest.mark.parametrize("num_envs, device", [(2, "cuda")])
@pytest.mark.parametrize(
"task_name", setup_environment(include_play=False, factory_envs=False, multi_agent=False, teleop_envs=True)
"task_name", setup_environment(factory_envs=False, multi_agent=False, teleop_envs=True)
)
def test_teleop_environments_with_stage_in_memory_and_clone_in_fabric_disabled(task_name, num_envs, device):
# skip test if stage in memory is not supported
Expand Down
8 changes: 5 additions & 3 deletions source/isaaclab_tasks/test/core/test_environments.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,19 @@
# Local imports should be imported last
from env_test_utils import _run_environments, setup_environment # isort: skip

@pytest.mark.parametrize("physics_preset_name", ["newton_mjwarp", "physx", "isaacsim_physx"])

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 Matrix silently uses default backend

The matrix applies every backend name to every core task without checking that the preset exists. For tasks such as Fourbar Pole, which only exposes newton_kamino, the newton_mjwarp, physx, and isaacsim_physx cases silently fall back to Kamino, so passing tests report backend coverage they did not exercise.

Knowledge Base Used: isaaclab_tasks: Task Registration and Organization

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Fixed in 52e373f: the smoke matrix now derives only task/backend pairs whose raw config declares the requested PhysicsCfg preset, so unsupported Fourbar combinations are omitted rather than falling back.


@pytest.mark.parametrize("num_envs, device", [(2, "cuda"), (1, "cuda")])
@pytest.mark.parametrize(
"task_name",
setup_environment(
include_play=False,
multi_agent=False,
tier="core",
),
)
@pytest.mark.isaacsim_ci
def test_environments(task_name, num_envs, device):
def test_environments(task_name, physics_preset_name, num_envs, device):
# run environments without stage in memory
_run_environments(task_name, device, num_envs, create_stage_in_memory=False)
_run_environments(
task_name, device, num_envs, create_stage_in_memory=False, physics_preset_name=physics_preset_name
)
38 changes: 0 additions & 38 deletions source/isaaclab_tasks/test/core/test_environments_newton.py

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

# TODO(mtrepte): re-enable with fabric cloning fix
# @pytest.mark.parametrize("num_envs, device", [(2, "cuda")])
# @pytest.mark.parametrize("task_name", setup_environment(include_play=False,factory_envs=False, multi_agent=False))
# @pytest.mark.parametrize("task_name", setup_environment(factory_envs=False, multi_agent=False))
# def test_environments_with_stage_in_memory_and_clone_in_fabric_disabled(task_name, num_envs, device):
# # skip test if stage in memory is not supported
# if get_isaac_sim_version().major < 5:
Expand All @@ -43,7 +43,6 @@
@pytest.mark.parametrize(
"task_name",
setup_environment(
include_play=False,
multi_agent=False,
tier="core",
),
Expand Down
2 changes: 1 addition & 1 deletion source/isaaclab_tasks/test/core/test_record_video.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def setup_video_params():
return num_envs, device, video_length


@pytest.mark.parametrize("task_name", setup_environment(include_play=True, tier="core"))
@pytest.mark.parametrize("task_name", setup_environment(tier="core"))
def test_record_video(task_name, setup_video_params):
"""Run random actions agent with internal VideoRecorder capturing from the active visualizer."""
num_envs, device, video_length = setup_video_params
Expand Down
Loading
Loading