fixed seeding and tests

This commit is contained in:
Fabian
2022-07-12 15:43:46 +02:00
parent 0339361656
commit d64cb614fa
10 changed files with 36 additions and 34 deletions
+1 -1
View File
@@ -7,7 +7,7 @@ import alr_envs # noqa
from alr_envs.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 not 'make_bb_env_helper' in spec.entry_point]
"alr_envs" in spec.entry_point and 'make_bb_env_helper' not in spec.entry_point]
SEED = 1
+3 -2
View File
@@ -6,7 +6,8 @@ import numpy as np
import alr_envs
from alr_envs import make
METAWORLD_IDS = []
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]
SEED = 1
@@ -58,7 +59,7 @@ class TestGymEnvironments(unittest.TestCase):
if done:
break
assert done, "Done flag is not True after end of episode."
assert done or env.spec.max_episode_steps is None, "Done flag is not True after end of episode."
observations.append(obs)
env.close()
del env