From 6adea4964f07562f6c2ebc0b23c1f1eff9b708c1 Mon Sep 17 00:00:00 2001 From: Alexis David Jacq Date: Sat, 16 Jun 2018 14:00:05 +0200 Subject: [PATCH] forgot one "isAlive" to change --- examples/pybullet/gym/pybullet_envs/gym_locomotion_envs.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/pybullet/gym/pybullet_envs/gym_locomotion_envs.py b/examples/pybullet/gym/pybullet_envs/gym_locomotion_envs.py index 68b355a13..93cd8af33 100644 --- a/examples/pybullet/gym/pybullet_envs/gym_locomotion_envs.py +++ b/examples/pybullet/gym/pybullet_envs/gym_locomotion_envs.py @@ -64,7 +64,7 @@ class WalkerBaseBulletEnv(MJCFBaseBulletEnv): state = self.robot.calc_state() # also calculates self.joints_at_limit self._alive = float(self.robot.alive_bonus(state[0]+self.robot.initial_z, self.robot.body_rpy[1])) # state[0] is body height above ground, body_rpy[1] is pitch - done = self._isAlive() + done = self._isDone() if not np.isfinite(state).all(): print("~INF~", state) done = True