diff --git a/minerl/herobraine/hero/handlers/agent/observations/lifestats.py b/minerl/herobraine/hero/handlers/agent/observations/lifestats.py index 9cd400fb..ce6a773c 100644 --- a/minerl/herobraine/hero/handlers/agent/observations/lifestats.py +++ b/minerl/herobraine/hero/handlers/agent/observations/lifestats.py @@ -59,8 +59,8 @@ class _IsAliveObservation(LifeStatsObservation): def __init__(self): keys = ['is_alive'] super().__init__(hero_keys=keys, univ_keys=keys, - space=spaces.Box(low=False, high=True, shape=(), dtype=bool), - default_if_missing=True) + space=spaces.Box(low=0, high=1, shape=(), dtype=bool), + default_if_missing=1) class _LifeObservation(LifeStatsObservation): diff --git a/minerl/herobraine/hero/spaces.py b/minerl/herobraine/hero/spaces.py index d4318407..7448da37 100644 --- a/minerl/herobraine/hero/spaces.py +++ b/minerl/herobraine/hero/spaces.py @@ -203,7 +203,6 @@ class Discrete(gym.spaces.Discrete, MineRLSpace): def __init__(self, *args, **kwargs): super(Discrete, self).__init__(*args, **kwargs) self.eye = np.eye(self.n, dtype=np.float32) - self.shape = () def no_op(self, batch_shape=()): if len(batch_shape) == 0: diff --git a/requirements.txt b/requirements.txt index 04d88808..3d1eba0e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,4 +1,4 @@ -gym @ git+https://github.com/minerllabs/gym@minerl-fix +gym>=0.19.0,<=0.23.1 opencv-python>=4.1.0.25 setuptools>=49.2.0 tqdm>=4.32.2