Skip to content

Commit 106c646

Browse files
committed
Use unique MuJoCo XML patches in release wheels
1 parent aa53da9 commit 106c646

7 files changed

Lines changed: 5 additions & 4 deletions

File tree

envpool/mujoco/BUILD

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ package(default_visibility = ["//visibility:public"])
2323
copy_to_directory(
2424
name = "gen_mujoco_gym_xml",
2525
srcs = [
26-
"@mujoco_gym_xml",
2726
"//third_party/mujoco_gym_xml_patches:patches",
27+
"@mujoco_gym_xml",
2828
],
2929
out = "assets_gym",
3030
strip_prefix = "assets/",

envpool/mujoco/gym/hopper.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,8 @@ class HopperEnv : public Env<HopperEnvSpec>, public MujocoEnv {
7777
public:
7878
HopperEnv(const Spec& spec, int env_id)
7979
: Env<HopperEnvSpec>(spec, env_id),
80-
MujocoEnv(spec.config["base_path"_] + "/mujoco/assets_gym/hopper.xml",
80+
MujocoEnv(spec.config["base_path"_] +
81+
"/mujoco/assets_gym/hopper_envpool.xml",
8182
spec.config["frame_skip"_], spec.config["post_constraint"_],
8283
spec.config["max_episode_steps"_]),
8384
terminate_when_unhealthy_(spec.config["terminate_when_unhealthy"_]),

envpool/mujoco/gym/registration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@
9999
if task == "Walker2d" and version == "v5":
100100
extra_args.update(
101101
{
102-
"xml_file": "walker2d_v5.xml",
102+
"xml_file": "walker2d_v5_envpool.xml",
103103
"legacy_healthy_reward": False,
104104
}
105105
)

envpool/mujoco/gym/walker2d.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class Walker2dEnvFns {
3636
"ctrl_cost_weight"_.Bind(0.001), "terminate_when_unhealthy"_.Bind(true),
3737
"exclude_current_positions_from_observation"_.Bind(true),
3838
"legacy_healthy_reward"_.Bind(true),
39-
"xml_file"_.Bind(std::string("walker2d.xml")),
39+
"xml_file"_.Bind(std::string("walker2d_envpool.xml")),
4040
"forward_reward_weight"_.Bind(1.0), "healthy_reward"_.Bind(1.0),
4141
"healthy_z_min"_.Bind(0.8), "healthy_z_max"_.Bind(2.0),
4242
"healthy_angle_min"_.Bind(-1.0), "healthy_angle_max"_.Bind(1.0),
File renamed without changes.
File renamed without changes.

third_party/mujoco_gym_xml_patches/walker2d_v5.xml renamed to third_party/mujoco_gym_xml_patches/walker2d_v5_envpool.xml

File renamed without changes.

0 commit comments

Comments
 (0)