renaming to fancy_gym
This commit is contained in:
+5
-5
@@ -3,11 +3,11 @@ import unittest
|
||||
import gym
|
||||
import numpy as np
|
||||
|
||||
import alr_envs # noqa
|
||||
from alr_envs.utils.make_env_helpers import make
|
||||
import fancy_gym # noqa
|
||||
from fancy_gym.utils.make_env_helpers import make
|
||||
|
||||
CUSTOM_IDS = [spec.id for spec in gym.envs.registry.all() if
|
||||
"alr_envs" in spec.entry_point and 'make_bb_env_helper' not in spec.entry_point]
|
||||
"fancy_gym" in spec.entry_point and 'make_bb_env_helper' not in spec.entry_point]
|
||||
SEED = 1
|
||||
|
||||
|
||||
@@ -101,7 +101,7 @@ class TestCustomEnvironments(unittest.TestCase):
|
||||
|
||||
def test_bb_functionality(self):
|
||||
"""Tests that black box environments run without errors using random actions."""
|
||||
for traj_gen, env_ids in alr_envs.ALL_ALR_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
for traj_gen, env_ids in fancy_gym.ALL_ALR_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
with self.subTest(msg=traj_gen):
|
||||
for id in env_ids:
|
||||
with self.subTest(msg=id):
|
||||
@@ -109,7 +109,7 @@ class TestCustomEnvironments(unittest.TestCase):
|
||||
|
||||
def test_bb_determinism(self):
|
||||
"""Tests that for black box environment identical seeds produce identical trajectories."""
|
||||
for traj_gen, env_ids in alr_envs.ALL_ALR_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
for traj_gen, env_ids in fancy_gym.ALL_ALR_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
with self.subTest(msg=traj_gen):
|
||||
self._run_env_determinism(env_ids)
|
||||
|
||||
|
||||
+4
-5
@@ -2,11 +2,10 @@ import unittest
|
||||
|
||||
import gym
|
||||
import numpy as np
|
||||
|
||||
from dm_control import suite, manipulation
|
||||
|
||||
import alr_envs
|
||||
from alr_envs import make
|
||||
import fancy_gym
|
||||
from fancy_gym import make
|
||||
|
||||
SUITE_IDS = [f'dmc:{env}-{task}' for env, task in suite.ALL_TASKS if env != "lqr"]
|
||||
MANIPULATION_IDS = [f'dmc:manipulation-{task}' for task in manipulation.ALL if task.endswith('_features')]
|
||||
@@ -114,7 +113,7 @@ class TestDMCEnvironments(unittest.TestCase):
|
||||
|
||||
def test_bb_functionality(self):
|
||||
"""Tests that black box environments run without errors using random actions."""
|
||||
for traj_gen, env_ids in alr_envs.ALL_DMC_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
for traj_gen, env_ids in fancy_gym.ALL_DMC_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
with self.subTest(msg=traj_gen):
|
||||
for id in env_ids:
|
||||
with self.subTest(msg=id):
|
||||
@@ -122,7 +121,7 @@ class TestDMCEnvironments(unittest.TestCase):
|
||||
|
||||
def test_bb_determinism(self):
|
||||
"""Tests that for black box environment identical seeds produce identical trajectories."""
|
||||
for traj_gen, env_ids in alr_envs.ALL_DMC_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
for traj_gen, env_ids in fancy_gym.ALL_DMC_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
with self.subTest(msg=traj_gen):
|
||||
self._run_env_determinism(env_ids)
|
||||
|
||||
|
||||
+5
-5
@@ -3,11 +3,11 @@ import unittest
|
||||
import gym
|
||||
import numpy as np
|
||||
|
||||
import alr_envs
|
||||
from alr_envs import make
|
||||
import fancy_gym
|
||||
from fancy_gym import make
|
||||
|
||||
GYM_IDS = [spec.id for spec in gym.envs.registry.all() if
|
||||
"alr_envs" not in spec.entry_point and 'make_bb_env_helper' not in spec.entry_point]
|
||||
"fancy_gym" not in spec.entry_point and 'make_bb_env_helper' not in spec.entry_point]
|
||||
SEED = 1
|
||||
|
||||
|
||||
@@ -101,7 +101,7 @@ class TestGymEnvironments(unittest.TestCase):
|
||||
|
||||
def test_bb_functionality(self):
|
||||
"""Tests that black box environments run without errors using random actions."""
|
||||
for traj_gen, env_ids in alr_envs.ALL_GYM_MOTION_PRIMITIVE_ENVIRONMENTS.items():
|
||||
for traj_gen, env_ids in fancy_gym.ALL_GYM_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
with self.subTest(msg=traj_gen):
|
||||
for id in env_ids:
|
||||
with self.subTest(msg=id):
|
||||
@@ -109,7 +109,7 @@ class TestGymEnvironments(unittest.TestCase):
|
||||
|
||||
def test_bb_determinism(self):
|
||||
"""Tests that for black box environment identical seeds produce identical trajectories."""
|
||||
for traj_gen, env_ids in alr_envs.ALL_GYM_MOTION_PRIMITIVE_ENVIRONMENTS.items():
|
||||
for traj_gen, env_ids in fancy_gym.ALL_GYM_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
with self.subTest(msg=traj_gen):
|
||||
self._run_env_determinism(env_ids)
|
||||
|
||||
|
||||
@@ -2,11 +2,11 @@ import unittest
|
||||
|
||||
import gym
|
||||
import numpy as np
|
||||
|
||||
import alr_envs
|
||||
from alr_envs import make
|
||||
from metaworld.envs import ALL_V2_ENVIRONMENTS_GOAL_OBSERVABLE
|
||||
|
||||
import fancy_gym
|
||||
from fancy_gym import make
|
||||
|
||||
METAWORLD_IDS = [f'metaworld:{env.split("-goal-observable")[0]}' for env, _ in
|
||||
ALL_V2_ENVIRONMENTS_GOAL_OBSERVABLE.items()]
|
||||
SEED = 1
|
||||
@@ -102,7 +102,7 @@ class TestMetaWorldEnvironments(unittest.TestCase):
|
||||
|
||||
def test_bb_functionality(self):
|
||||
"""Tests that black box environments run without errors using random actions."""
|
||||
for traj_gen, env_ids in alr_envs.ALL_METAWORLD_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
for traj_gen, env_ids in fancy_gym.ALL_METAWORLD_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
with self.subTest(msg=traj_gen):
|
||||
for id in env_ids:
|
||||
with self.subTest(msg=id):
|
||||
@@ -110,7 +110,7 @@ class TestMetaWorldEnvironments(unittest.TestCase):
|
||||
|
||||
def test_bb_determinism(self):
|
||||
"""Tests that for black box environment identical seeds produce identical trajectories."""
|
||||
for traj_gen, env_ids in alr_envs.ALL_METAWORLD_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
for traj_gen, env_ids in fancy_gym.ALL_METAWORLD_MOVEMENT_PRIMITIVE_ENVIRONMENTS.items():
|
||||
with self.subTest(msg=traj_gen):
|
||||
self._run_env_determinism(env_ids)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user