|
|
|
@ -350,9 +350,12 @@ class sprint(gym.Env):
|
|
|
|
|
direction_error = abs(self.walk_rel_orientation)
|
|
|
|
|
direction_error = min(direction_error, 10)
|
|
|
|
|
reward = robot_speed * (1 - direction_error / 10)
|
|
|
|
|
if np.linalg.norm(r.loc_torso_position[:2] - self.walk_rel_target,ord='fro') < 1:
|
|
|
|
|
reward += 50
|
|
|
|
|
|
|
|
|
|
if self.player.behavior.is_ready("Get_Up"):
|
|
|
|
|
self.terminal = True
|
|
|
|
|
elif w.time_local_ms - self.reset_time > 50000:
|
|
|
|
|
elif w.time_local_ms - self.reset_time > 40000:
|
|
|
|
|
self.terminal = True
|
|
|
|
|
elif r.loc_torso_position[0] > 14.5:
|
|
|
|
|
self.terminal = True
|
|
|
|
|