# Use TD3 to Play Pendulum-v1¶

PyTorch version

In [1]:

    %matplotlib inline

    import sys
    import logging
    import itertools
    import copy

    import numpy as np
    np.random.seed(0)
    import pandas as pd
    import gym
    import matplotlib.pyplot as plt
    import torch
    torch.manual_seed(0)
    import torch.nn as nn
    import torch.optim as optim

    logging.basicConfig(level=logging.INFO,
            format='%(asctime)s [%(levelname)s] %(message)s',
            stream=sys.stdout, datefmt='%H:%M:%S')

In [2]:

    env = gym.make('Pendulum-v1')
    for key in vars(env.spec):
        logging.info('%s: %s', key, vars(env.spec)[key])
    for key in vars(env.unwrapped):
        logging.info('%s: %s', key, vars(env.unwrapped)[key])

    00:00:00 [INFO] id: Pendulum-v1
    00:00:00 [INFO] entry_point: gym.envs.classic_control:PendulumEnv
    00:00:00 [INFO] reward_threshold: None
    00:00:00 [INFO] nondeterministic: False
    00:00:00 [INFO] max_episode_steps: 200
    00:00:00 [INFO] order_enforce: True
    00:00:00 [INFO] _kwargs: {}
    00:00:00 [INFO] _env_name: Pendulum
    00:00:00 [INFO] max_speed: 8
    00:00:00 [INFO] max_torque: 2.0
    00:00:00 [INFO] dt: 0.05
    00:00:00 [INFO] g: 10.0
    00:00:00 [INFO] m: 1.0
    00:00:00 [INFO] l: 1.0
    00:00:00 [INFO] viewer: None
    00:00:00 [INFO] action_space: Box([-2.], [2.], (1,), float32)
    00:00:00 [INFO] observation_space: Box([-1. -1. -8.], [1. 1. 8.], (3,), float32)
    00:00:00 [INFO] np_random: RandomState(MT19937)
    00:00:00 [INFO] spec: EnvSpec(Pendulum-v1)

In [3]:

    class DQNReplayer:
        def __init__(self, capacity):
            self.memory = pd.DataFrame(index=range(capacity),
                    columns=['observation', 'action', 'reward',
                    'next_observation', 'terminated'])
            self.i = 0
            self.count = 0
            self.capacity = capacity

        def store(self, *args):
            self.memory.loc[self.i] = np.asarray(args, dtype=object)
            self.i = (self.i + 1) % self.capacity
            self.count = min(self.count + 1, self.capacity)

        def sample(self, size):
            indices = np.random.choice(self.count, size=size)
            return (np.stack(self.memory.loc[indices, field]) for field in
                    self.memory.columns)

In [4]:

    class OrnsteinUhlenbeckProcess:
        def __init__(self, x0):
            self.x = x0

        def __call__(self, mu=0., sigma=1., theta=.15, dt=.01):
            n = np.random.normal(size=self.x.shape)
            self.x += (theta * (mu - self.x) * dt + sigma * np.sqrt(dt) * n)
            return self.x

In [5]:

    class TD3Agent:
        def __init__(self, env):
            state_dim = env.observation_space.shape[0]
            self.action_dim = env.action_space.shape[0]
            self.action_low = env.action_space.low[0]
            self.action_high = env.action_space.high[0]

            self.gamma = 0.99

            self.replayer = DQNReplayer(20000)

            self.actor_evaluate_net = self.build_net(
                    input_size=state_dim, hidden_sizes=[32, 64],
                    output_size=self.action_dim)
            self.actor_optimizer = optim.Adam(self.actor_evaluate_net.parameters(),
                    lr=0.001)
            self.actor_target_net = copy.deepcopy(self.actor_evaluate_net)

            self.critic0_evaluate_net = self.build_net(
                    input_size=state_dim+self.action_dim, hidden_sizes=[64, 128])
            self.critic0_optimizer = optim.Adam(self.critic0_evaluate_net.parameters(),
                    lr=0.001)
            self.critic0_loss = nn.MSELoss()
            self.critic0_target_net = copy.deepcopy(self.critic0_evaluate_net)

            self.critic1_evaluate_net = self.build_net(
                    input_size=state_dim+self.action_dim, hidden_sizes=[64, 128])
            self.critic1_optimizer = optim.Adam(self.critic1_evaluate_net.parameters(),
                    lr=0.001)
            self.critic1_loss = nn.MSELoss()
            self.critic1_target_net = copy.deepcopy(self.critic1_evaluate_net)

        def build_net(self, input_size, hidden_sizes, output_size=1,
                output_activator=None):
            layers = []
            for input_size, output_size in zip(
                    [input_size,] + hidden_sizes, hidden_sizes + [output_size,]):
                layers.append(nn.Linear(input_size, output_size))
                layers.append(nn.ReLU())
            layers = layers[:-1]
            if output_activator:
                layers.append(output_activator)
            net = nn.Sequential(*layers)
            return net

        def reset(self, mode=None):
            self.mode = mode
            if self.mode == 'train':
                self.trajectory = []
                self.noise = OrnsteinUhlenbeckProcess(np.zeros((self.action_dim,)))

        def step(self, observation, reward, terminated):
            state_tensor = torch.as_tensor(observation, dtype=torch.float).unsqueeze(0)
            action_tensor = self.actor_evaluate_net(state_tensor)
            action = action_tensor.detach().numpy()[0]

            if self.mode == 'train':
                # noisy action
                noise = self.noise(sigma=0.1)
                action = (action + noise).clip(self.action_low, self.action_high)

                self.trajectory += [observation, reward, terminated, action]
                if len(self.trajectory) >= 8:
                    state, _, _, act, next_state, reward, terminated, _ = \
                            self.trajectory[-8:]
                    self.replayer.store(state, act, reward, next_state, terminated)

                if self.replayer.count >= 3000:
                    self.learn()
            return action

        def close(self):
            pass

        def update_net(self, target_net, evaluate_net, learning_rate=0.005):
            for target_param, evaluate_param in zip(
                    target_net.parameters(), evaluate_net.parameters()):
                target_param.data.copy_(learning_rate * evaluate_param.data
                        + (1 - learning_rate) * target_param.data)

        def learn(self):
            # replay
            states, actions, rewards, next_states, terminateds = \
                    self.replayer.sample(64)
            state_tensor = torch.as_tensor(states, dtype=torch.float)
            action_tensor = torch.as_tensor(actions, dtype=torch.long)
            reward_tensor = torch.as_tensor(rewards, dtype=torch.float)
            next_state_tensor = torch.as_tensor(next_states, dtype=torch.float)
            terminated_tensor = torch.as_tensor(terminateds, dtype=torch.float)

            # update critic
            next_action_tensor = self.actor_target_net(next_state_tensor)
            noise_tensor = (0.2 * torch.randn_like(action_tensor, dtype=torch.float))
            noisy_next_action_tensor = (next_action_tensor + noise_tensor
                    ).clamp(self.action_low, self.action_high)
            next_state_action_tensor = torch.cat([next_state_tensor,
                    noisy_next_action_tensor], 1)
            next_q0_tensor = self.critic0_target_net(next_state_action_tensor
                    ).squeeze(1)
            next_q1_tensor = self.critic1_target_net(next_state_action_tensor
                    ).squeeze(1)
            next_q_tensor = torch.min(next_q0_tensor, next_q1_tensor)
            critic_target_tensor = reward_tensor + (1. - terminated_tensor) * \
                    self.gamma * next_q_tensor
            critic_target_tensor = critic_target_tensor.detach()

            state_action_tensor = torch.cat([state_tensor, action_tensor], 1)
            critic_pred0_tensor = self.critic0_evaluate_net(
                    state_action_tensor).squeeze(1)
            critic0_loss_tensor = self.critic0_loss(critic_pred0_tensor,
                    critic_target_tensor)
            self.critic0_optimizer.zero_grad()
            critic0_loss_tensor.backward()
            self.critic0_optimizer.step()

            critic_pred1_tensor = self.critic1_evaluate_net(
                    state_action_tensor).squeeze(1)
            critic1_loss_tensor = self.critic1_loss(critic_pred1_tensor,
                    critic_target_tensor)
            self.critic1_optimizer.zero_grad()
            critic1_loss_tensor.backward()
            self.critic1_optimizer.step()

            # update actor
            pred_action_tensor = self.actor_evaluate_net(state_tensor)
            pred_action_tensor = pred_action_tensor.clamp(self.action_low,
                    self.action_high)
            pred_state_action_tensor = torch.cat([state_tensor, pred_action_tensor], 1)
            critic_pred_tensor = self.critic0_evaluate_net(pred_state_action_tensor)
            actor_loss_tensor = -critic_pred_tensor.mean()
            self.actor_optimizer.zero_grad()
            actor_loss_tensor.backward()
            self.actor_optimizer.step()

            self.update_net(self.critic0_target_net, self.critic0_evaluate_net)
            self.update_net(self.critic1_target_net, self.critic1_evaluate_net)
            self.update_net(self.actor_target_net, self.actor_evaluate_net)

    agent = TD3Agent(env)

In [6]:

    def play_episode(env, agent, seed=None, mode=None, render=False):
        observation, _ = env.reset(seed=seed)
        reward, terminated, truncated = 0., False, False
        agent.reset(mode=mode)
        episode_reward, elapsed_steps = 0., 0
        while True:
            action = agent.step(observation, reward, terminated)
            if render:
                env.render()
            if terminated or truncated:
                break
            observation, reward, terminated, truncated, _ = env.step(action)
            episode_reward += reward
            elapsed_steps += 1
        agent.close()
        return episode_reward, elapsed_steps

    logging.info('==== train ====')
    episode_rewards = []
    for episode in itertools.count():
        episode_reward, elapsed_steps = play_episode(env, agent, seed=episode,
                mode='train')
        episode_rewards.append(episode_reward)
        logging.info('train episode %d: reward = %.2f, steps = %d',
                episode, episode_reward, elapsed_steps)
        if np.mean(episode_rewards[-10:]) > -120:
            break
    plt.plot(episode_rewards)

    logging.info('==== test ====')
    episode_rewards = []
    for episode in range(100):
        episode_reward, elapsed_steps = play_episode(env, agent)
        episode_rewards.append(episode_reward)
        logging.info('test episode %d: reward = %.2f, steps = %d',
                episode, episode_reward, elapsed_steps)
    logging.info('average episode reward = %.2f ± %.2f',
            np.mean(episode_rewards), np.std(episode_rewards))

    22:50:06 [INFO] ==== train ====
    22:50:06 [INFO] train episode 0: reward = -1721.57, steps = 200
    22:50:06 [INFO] train episode 1: reward = -1070.98, steps = 200
    22:50:06 [INFO] train episode 2: reward = -1577.55, steps = 200
    22:50:06 [INFO] train episode 3: reward = -1060.81, steps = 200
    22:50:07 [INFO] train episode 4: reward = -1743.80, steps = 200
    22:50:07 [INFO] train episode 5: reward = -1762.58, steps = 200
    22:50:07 [INFO] train episode 6: reward = -951.33, steps = 200
    22:50:07 [INFO] train episode 7: reward = -1765.45, steps = 200
    22:50:07 [INFO] train episode 8: reward = -903.09, steps = 200
    22:50:07 [INFO] train episode 9: reward = -1765.03, steps = 200
    22:50:08 [INFO] train episode 10: reward = -1318.38, steps = 200
    22:50:08 [INFO] train episode 11: reward = -983.89, steps = 200
    22:50:08 [INFO] train episode 12: reward = -1515.06, steps = 200
    22:50:08 [INFO] train episode 13: reward = -1287.58, steps = 200
    22:50:08 [INFO] train episode 14: reward = -860.10, steps = 200
    22:50:32 [INFO] train episode 15: reward = -1504.97, steps = 200
    22:50:56 [INFO] train episode 16: reward = -1044.90, steps = 200
    22:51:21 [INFO] train episode 17: reward = -1386.82, steps = 200
    22:51:45 [INFO] train episode 18: reward = -1213.84, steps = 200
    22:52:10 [INFO] train episode 19: reward = -986.98, steps = 200
    22:52:35 [INFO] train episode 20: reward = -1322.80, steps = 200
    22:53:00 [INFO] train episode 21: reward = -1610.61, steps = 200
    22:53:25 [INFO] train episode 22: reward = -1593.37, steps = 200
    22:53:52 [INFO] train episode 23: reward = -1299.74, steps = 200
    22:54:19 [INFO] train episode 24: reward = -930.12, steps = 200
    22:54:46 [INFO] train episode 25: reward = -1632.12, steps = 200
    22:55:11 [INFO] train episode 26: reward = -1203.33, steps = 200
    22:55:36 [INFO] train episode 27: reward = -982.27, steps = 200
    22:56:00 [INFO] train episode 28: reward = -948.41, steps = 200
    22:56:25 [INFO] train episode 29: reward = -1649.39, steps = 200
    22:56:50 [INFO] train episode 30: reward = -1100.71, steps = 200
    22:57:15 [INFO] train episode 31: reward = -1114.19, steps = 200
    22:57:40 [INFO] train episode 32: reward = -1047.40, steps = 200
    22:58:05 [INFO] train episode 33: reward = -999.32, steps = 200
    22:58:29 [INFO] train episode 34: reward = -1104.40, steps = 200
    22:58:55 [INFO] train episode 35: reward = -1028.04, steps = 200
    22:59:20 [INFO] train episode 36: reward = -1766.86, steps = 200
    22:59:45 [INFO] train episode 37: reward = -1178.15, steps = 200
    23:00:13 [INFO] train episode 38: reward = -961.91, steps = 200
    23:00:46 [INFO] train episode 39: reward = -1148.73, steps = 200
    23:01:17 [INFO] train episode 40: reward = -1765.17, steps = 200
    23:01:50 [INFO] train episode 41: reward = -1606.13, steps = 200
    23:02:16 [INFO] train episode 42: reward = -1164.91, steps = 200
    23:02:42 [INFO] train episode 43: reward = -1044.43, steps = 200
    23:03:12 [INFO] train episode 44: reward = -1202.69, steps = 200
    23:03:42 [INFO] train episode 45: reward = -1178.19, steps = 200
    23:04:07 [INFO] train episode 46: reward = -878.43, steps = 200
    23:04:34 [INFO] train episode 47: reward = -773.48, steps = 200
    23:05:03 [INFO] train episode 48: reward = -925.66, steps = 200
    23:05:29 [INFO] train episode 49: reward = -912.90, steps = 200
    23:05:56 [INFO] train episode 50: reward = -1660.76, steps = 200
    23:06:23 [INFO] train episode 51: reward = -760.19, steps = 200
    23:06:50 [INFO] train episode 52: reward = -904.53, steps = 200
    23:07:16 [INFO] train episode 53: reward = -723.88, steps = 200
    23:07:42 [INFO] train episode 54: reward = -893.00, steps = 200
    23:08:07 [INFO] train episode 55: reward = -1139.41, steps = 200
    23:08:33 [INFO] train episode 56: reward = -1039.83, steps = 200
    23:09:00 [INFO] train episode 57: reward = -1011.66, steps = 200
    23:09:26 [INFO] train episode 58: reward = -713.38, steps = 200
    23:09:54 [INFO] train episode 59: reward = -1010.66, steps = 200
    23:10:23 [INFO] train episode 60: reward = -898.30, steps = 200
    23:10:51 [INFO] train episode 61: reward = -883.27, steps = 200
    23:11:21 [INFO] train episode 62: reward = -792.54, steps = 200
    23:11:56 [INFO] train episode 63: reward = -754.38, steps = 200
    23:12:39 [INFO] train episode 64: reward = -883.61, steps = 200
    23:13:24 [INFO] train episode 65: reward = -898.71, steps = 200
    23:14:12 [INFO] train episode 66: reward = -908.78, steps = 200
    23:14:58 [INFO] train episode 67: reward = -891.53, steps = 200
    23:15:43 [INFO] train episode 68: reward = -992.78, steps = 200
    23:16:30 [INFO] train episode 69: reward = -895.59, steps = 200
    23:17:16 [INFO] train episode 70: reward = -904.98, steps = 200
    23:18:01 [INFO] train episode 71: reward = -1001.45, steps = 200
    23:18:46 [INFO] train episode 72: reward = -1126.34, steps = 200
    23:19:31 [INFO] train episode 73: reward = -1043.43, steps = 200
    23:20:17 [INFO] train episode 74: reward = -1067.01, steps = 200
    23:21:04 [INFO] train episode 75: reward = -1042.23, steps = 200
    23:21:49 [INFO] train episode 76: reward = -1050.97, steps = 200
    23:22:35 [INFO] train episode 77: reward = -1127.45, steps = 200
    23:23:21 [INFO] train episode 78: reward = -1145.52, steps = 200
    23:24:10 [INFO] train episode 79: reward = -1035.29, steps = 200
    23:24:55 [INFO] train episode 80: reward = -1131.83, steps = 200
    23:25:41 [INFO] train episode 81: reward = -1049.22, steps = 200
    23:26:30 [INFO] train episode 82: reward = -964.45, steps = 200
    23:27:15 [INFO] train episode 83: reward = -890.96, steps = 200
    23:28:01 [INFO] train episode 84: reward = -828.35, steps = 200
    23:28:47 [INFO] train episode 85: reward = -700.21, steps = 200
    23:29:33 [INFO] train episode 86: reward = -839.80, steps = 200
    23:30:20 [INFO] train episode 87: reward = -747.70, steps = 200
    23:31:09 [INFO] train episode 88: reward = -747.97, steps = 200
    23:31:54 [INFO] train episode 89: reward = -752.49, steps = 200
    23:32:40 [INFO] train episode 90: reward = -746.77, steps = 200
    23:33:25 [INFO] train episode 91: reward = -861.00, steps = 200
    23:34:10 [INFO] train episode 92: reward = -780.87, steps = 200
    23:34:56 [INFO] train episode 93: reward = -639.99, steps = 200
    23:35:41 [INFO] train episode 94: reward = -641.45, steps = 200
    23:36:28 [INFO] train episode 95: reward = -817.88, steps = 200
    23:37:15 [INFO] train episode 96: reward = -629.48, steps = 200
    23:38:02 [INFO] train episode 97: reward = -622.91, steps = 200
    23:38:51 [INFO] train episode 98: reward = -640.05, steps = 200
    23:39:37 [INFO] train episode 99: reward = -604.30, steps = 200
    23:40:24 [INFO] train episode 100: reward = -774.47, steps = 200
    23:41:10 [INFO] train episode 101: reward = -494.49, steps = 200
    23:41:55 [INFO] train episode 102: reward = -884.44, steps = 200
    23:42:48 [INFO] train episode 103: reward = -635.08, steps = 200
    23:43:43 [INFO] train episode 104: reward = -882.61, steps = 200
    23:44:33 [INFO] train episode 105: reward = -383.83, steps = 200
    23:45:18 [INFO] train episode 106: reward = -755.98, steps = 200
    23:46:09 [INFO] train episode 107: reward = -877.50, steps = 200
    23:46:57 [INFO] train episode 108: reward = -509.54, steps = 200
    23:47:55 [INFO] train episode 109: reward = -1031.94, steps = 200
    23:48:49 [INFO] train episode 110: reward = -759.50, steps = 200
    23:49:39 [INFO] train episode 111: reward = -752.53, steps = 200
    23:50:31 [INFO] train episode 112: reward = -957.64, steps = 200
    23:51:19 [INFO] train episode 113: reward = -882.54, steps = 200
    23:52:10 [INFO] train episode 114: reward = -870.90, steps = 200
    23:52:59 [INFO] train episode 115: reward = -982.60, steps = 200
    23:53:51 [INFO] train episode 116: reward = -963.98, steps = 200
    23:54:38 [INFO] train episode 117: reward = -867.98, steps = 200
    23:55:24 [INFO] train episode 118: reward = -868.38, steps = 200
    23:56:09 [INFO] train episode 119: reward = -769.28, steps = 200
    23:56:54 [INFO] train episode 120: reward = -922.79, steps = 200
    23:57:40 [INFO] train episode 121: reward = -847.18, steps = 200
    23:58:26 [INFO] train episode 122: reward = -866.54, steps = 200
    23:59:12 [INFO] train episode 123: reward = -904.55, steps = 200
    23:59:57 [INFO] train episode 124: reward = -513.19, steps = 200
    00:00:43 [INFO] train episode 125: reward = -721.57, steps = 200
    00:01:29 [INFO] train episode 126: reward = -638.88, steps = 200
    00:02:15 [INFO] train episode 127: reward = -522.03, steps = 200
    00:03:01 [INFO] train episode 128: reward = -516.54, steps = 200
    00:03:47 [INFO] train episode 129: reward = -614.31, steps = 200
    00:04:33 [INFO] train episode 130: reward = -510.68, steps = 200
    00:05:18 [INFO] train episode 131: reward = -627.74, steps = 200
    00:06:04 [INFO] train episode 132: reward = -484.04, steps = 200
    00:06:46 [INFO] train episode 133: reward = -498.52, steps = 200
    00:07:32 [INFO] train episode 134: reward = -622.09, steps = 200
    00:08:18 [INFO] train episode 135: reward = -673.45, steps = 200
    00:09:04 [INFO] train episode 136: reward = -419.64, steps = 200
    00:09:49 [INFO] train episode 137: reward = -598.43, steps = 200
    00:10:35 [INFO] train episode 138: reward = -383.04, steps = 200
    00:11:20 [INFO] train episode 139: reward = -493.48, steps = 200
    00:12:06 [INFO] train episode 140: reward = -134.65, steps = 200
    00:12:51 [INFO] train episode 141: reward = -368.43, steps = 200
    00:13:37 [INFO] train episode 142: reward = -551.87, steps = 200
    00:14:23 [INFO] train episode 143: reward = -131.40, steps = 200
    00:15:08 [INFO] train episode 144: reward = -262.17, steps = 200
    00:15:53 [INFO] train episode 145: reward = -403.52, steps = 200
    00:16:39 [INFO] train episode 146: reward = -375.08, steps = 200
    00:17:23 [INFO] train episode 147: reward = -506.14, steps = 200
    00:18:09 [INFO] train episode 148: reward = -512.21, steps = 200
    00:18:53 [INFO] train episode 149: reward = -716.76, steps = 200
    00:19:39 [INFO] train episode 150: reward = -722.97, steps = 200
    00:20:24 [INFO] train episode 151: reward = -623.30, steps = 200
    00:21:10 [INFO] train episode 152: reward = -298.58, steps = 200
    00:21:54 [INFO] train episode 153: reward = -498.90, steps = 200
    00:22:40 [INFO] train episode 154: reward = -506.79, steps = 200
    00:23:25 [INFO] train episode 155: reward = -627.91, steps = 200
    00:24:10 [INFO] train episode 156: reward = -273.54, steps = 200
    00:24:55 [INFO] train episode 157: reward = -514.32, steps = 200
    00:25:40 [INFO] train episode 158: reward = -265.99, steps = 200
    00:26:27 [INFO] train episode 159: reward = -140.16, steps = 200
    00:27:15 [INFO] train episode 160: reward = -366.77, steps = 200
    00:28:00 [INFO] train episode 161: reward = -135.96, steps = 200
    00:28:45 [INFO] train episode 162: reward = -449.60, steps = 200
    00:29:31 [INFO] train episode 163: reward = -257.36, steps = 200
    00:30:16 [INFO] train episode 164: reward = -263.04, steps = 200
    00:31:01 [INFO] train episode 165: reward = -144.86, steps = 200
    00:31:47 [INFO] train episode 166: reward = -384.65, steps = 200
    00:32:37 [INFO] train episode 167: reward = -709.58, steps = 200
    00:33:23 [INFO] train episode 168: reward = -504.85, steps = 200
    00:34:07 [INFO] train episode 169: reward = -422.78, steps = 200
    00:34:52 [INFO] train episode 170: reward = -810.01, steps = 200
    00:35:35 [INFO] train episode 171: reward = -564.94, steps = 200
    00:36:20 [INFO] train episode 172: reward = -388.60, steps = 200
    00:37:08 [INFO] train episode 173: reward = -668.61, steps = 200
    00:37:54 [INFO] train episode 174: reward = -501.38, steps = 200
    00:38:39 [INFO] train episode 175: reward = -463.29, steps = 200
    00:39:24 [INFO] train episode 176: reward = -406.66, steps = 200
    00:40:06 [INFO] train episode 177: reward = -604.76, steps = 200
    00:40:51 [INFO] train episode 178: reward = -253.91, steps = 200
    00:41:36 [INFO] train episode 179: reward = -486.96, steps = 200
    00:42:21 [INFO] train episode 180: reward = -576.04, steps = 200
    00:43:06 [INFO] train episode 181: reward = -375.20, steps = 200
    00:43:51 [INFO] train episode 182: reward = -493.18, steps = 200
    00:44:36 [INFO] train episode 183: reward = -373.14, steps = 200
    00:45:21 [INFO] train episode 184: reward = -234.01, steps = 200
    00:46:06 [INFO] train episode 185: reward = -127.60, steps = 200
    00:46:51 [INFO] train episode 186: reward = -253.05, steps = 200
    00:47:35 [INFO] train episode 187: reward = -7.27, steps = 200
    00:48:19 [INFO] train episode 188: reward = -361.74, steps = 200
    00:49:04 [INFO] train episode 189: reward = -508.00, steps = 200
    00:49:49 [INFO] train episode 190: reward = -246.49, steps = 200
    00:50:35 [INFO] train episode 191: reward = -484.12, steps = 200
    00:51:20 [INFO] train episode 192: reward = -371.06, steps = 200
    00:52:05 [INFO] train episode 193: reward = -575.35, steps = 200
    00:52:50 [INFO] train episode 194: reward = -255.27, steps = 200
    00:53:35 [INFO] train episode 195: reward = -371.99, steps = 200
    00:54:19 [INFO] train episode 196: reward = -372.93, steps = 200
    00:55:04 [INFO] train episode 197: reward = -363.40, steps = 200
    00:55:49 [INFO] train episode 198: reward = -501.59, steps = 200
    00:56:34 [INFO] train episode 199: reward = -129.10, steps = 200
    00:57:19 [INFO] train episode 200: reward = -503.00, steps = 200
    00:57:54 [INFO] train episode 201: reward = -120.43, steps = 200
    00:58:30 [INFO] train episode 202: reward = -254.81, steps = 200
    00:59:15 [INFO] train episode 203: reward = -131.72, steps = 200
    00:59:58 [INFO] train episode 204: reward = -126.23, steps = 200
    01:00:43 [INFO] train episode 205: reward = -125.94, steps = 200
    01:01:28 [INFO] train episode 206: reward = -125.51, steps = 200
    01:02:13 [INFO] train episode 207: reward = -255.84, steps = 200
    01:02:58 [INFO] train episode 208: reward = -246.80, steps = 200
    01:03:42 [INFO] train episode 209: reward = -3.75, steps = 200
    01:04:26 [INFO] train episode 210: reward = -124.18, steps = 200
    01:05:11 [INFO] train episode 211: reward = -374.76, steps = 200
    01:05:55 [INFO] train episode 212: reward = -137.36, steps = 200
    01:06:40 [INFO] train episode 213: reward = -3.13, steps = 200
    01:07:25 [INFO] train episode 214: reward = -509.80, steps = 200
    01:08:11 [INFO] train episode 215: reward = -132.43, steps = 200
    01:08:56 [INFO] train episode 216: reward = -132.30, steps = 200
    01:09:41 [INFO] train episode 217: reward = -123.27, steps = 200
    01:10:26 [INFO] train episode 218: reward = -248.48, steps = 200
    01:11:11 [INFO] train episode 219: reward = -254.86, steps = 200
    01:11:55 [INFO] train episode 220: reward = -123.96, steps = 200
    01:12:40 [INFO] train episode 221: reward = -125.79, steps = 200
    01:13:25 [INFO] train episode 222: reward = -3.26, steps = 200
    01:14:10 [INFO] train episode 223: reward = -555.67, steps = 200
    01:14:55 [INFO] train episode 224: reward = -487.66, steps = 200
    01:15:40 [INFO] train episode 225: reward = -633.67, steps = 200
    01:16:25 [INFO] train episode 226: reward = -382.08, steps = 200
    01:17:09 [INFO] train episode 227: reward = -498.68, steps = 200
    01:17:54 [INFO] train episode 228: reward = -248.48, steps = 200
    01:18:38 [INFO] train episode 229: reward = -261.38, steps = 200
    01:19:22 [INFO] train episode 230: reward = -373.96, steps = 200
    01:20:08 [INFO] train episode 231: reward = -627.17, steps = 200
    01:20:53 [INFO] train episode 232: reward = -760.25, steps = 200
    01:21:37 [INFO] train episode 233: reward = -138.81, steps = 200
    01:22:22 [INFO] train episode 234: reward = -253.40, steps = 200
    01:23:08 [INFO] train episode 235: reward = -351.31, steps = 200
    01:23:51 [INFO] train episode 236: reward = -126.64, steps = 200
    01:24:37 [INFO] train episode 237: reward = -130.42, steps = 200
    01:25:21 [INFO] train episode 238: reward = -375.13, steps = 200
    01:26:06 [INFO] train episode 239: reward = -371.86, steps = 200
    01:26:54 [INFO] train episode 240: reward = -129.06, steps = 200
    01:27:40 [INFO] train episode 241: reward = -341.52, steps = 200
    01:28:25 [INFO] train episode 242: reward = -131.11, steps = 200
    01:29:10 [INFO] train episode 243: reward = -259.53, steps = 200
    01:29:56 [INFO] train episode 244: reward = -384.46, steps = 200
    01:30:41 [INFO] train episode 245: reward = -140.34, steps = 200
    01:31:27 [INFO] train episode 246: reward = -265.71, steps = 200
    01:32:12 [INFO] train episode 247: reward = -239.26, steps = 200
    01:32:57 [INFO] train episode 248: reward = -317.49, steps = 200
    01:33:42 [INFO] train episode 249: reward = -129.42, steps = 200
    01:34:27 [INFO] train episode 250: reward = -133.52, steps = 200
    01:35:12 [INFO] train episode 251: reward = -249.69, steps = 200
    01:35:57 [INFO] train episode 252: reward = -134.03, steps = 200
    01:36:42 [INFO] train episode 253: reward = -293.11, steps = 200
    01:37:28 [INFO] train episode 254: reward = -128.80, steps = 200
    01:38:13 [INFO] train episode 255: reward = -240.41, steps = 200
    01:38:57 [INFO] train episode 256: reward = -120.32, steps = 200
    01:39:42 [INFO] train episode 257: reward = -134.86, steps = 200
    01:40:27 [INFO] train episode 258: reward = -133.42, steps = 200
    01:41:12 [INFO] train episode 259: reward = -248.89, steps = 200
    01:41:57 [INFO] train episode 260: reward = -131.94, steps = 200
    01:42:43 [INFO] train episode 261: reward = -393.44, steps = 200
    01:43:27 [INFO] train episode 262: reward = -129.26, steps = 200
    01:44:13 [INFO] train episode 263: reward = -7.18, steps = 200
    01:44:58 [INFO] train episode 264: reward = -251.55, steps = 200
    01:45:42 [INFO] train episode 265: reward = -245.81, steps = 200
    01:46:27 [INFO] train episode 266: reward = -247.89, steps = 200
    01:47:12 [INFO] train episode 267: reward = -131.22, steps = 200
    01:47:56 [INFO] train episode 268: reward = -134.16, steps = 200
    01:48:41 [INFO] train episode 269: reward = -137.25, steps = 200
    01:49:25 [INFO] train episode 270: reward = -356.23, steps = 200
    01:50:10 [INFO] train episode 271: reward = -8.03, steps = 200
    01:50:54 [INFO] train episode 272: reward = -137.97, steps = 200
    01:51:40 [INFO] train episode 273: reward = -122.40, steps = 200
    01:52:26 [INFO] train episode 274: reward = -252.92, steps = 200
    01:53:11 [INFO] train episode 275: reward = -137.42, steps = 200
    01:53:56 [INFO] train episode 276: reward = -122.92, steps = 200
    01:54:41 [INFO] train episode 277: reward = -255.63, steps = 200
    01:55:27 [INFO] train episode 278: reward = -648.33, steps = 200
    01:56:11 [INFO] train episode 279: reward = -124.46, steps = 200
    01:56:57 [INFO] train episode 280: reward = -136.56, steps = 200
    01:57:42 [INFO] train episode 281: reward = -259.56, steps = 200
    01:58:27 [INFO] train episode 282: reward = -390.69, steps = 200
    01:59:11 [INFO] train episode 283: reward = -247.74, steps = 200
    01:59:56 [INFO] train episode 284: reward = -128.01, steps = 200
    02:00:41 [INFO] train episode 285: reward = -142.94, steps = 200
    02:01:26 [INFO] train episode 286: reward = -133.63, steps = 200
    02:02:10 [INFO] train episode 287: reward = -364.54, steps = 200
    02:02:55 [INFO] train episode 288: reward = -140.83, steps = 200
    02:03:39 [INFO] train episode 289: reward = -132.56, steps = 200
    02:04:23 [INFO] train episode 290: reward = -132.94, steps = 200
    02:05:08 [INFO] train episode 291: reward = -350.31, steps = 200
    02:05:53 [INFO] train episode 292: reward = -620.37, steps = 200
    02:06:38 [INFO] train episode 293: reward = -10.93, steps = 200
    02:07:23 [INFO] train episode 294: reward = -388.36, steps = 200
    02:08:08 [INFO] train episode 295: reward = -383.58, steps = 200
    02:08:53 [INFO] train episode 296: reward = -26.43, steps = 200
    02:09:38 [INFO] train episode 297: reward = -380.80, steps = 200
    02:10:24 [INFO] train episode 298: reward = -380.96, steps = 200
    02:11:08 [INFO] train episode 299: reward = -131.45, steps = 200
    02:11:53 [INFO] train episode 300: reward = -133.48, steps = 200
    02:12:39 [INFO] train episode 301: reward = -379.10, steps = 200
    02:13:24 [INFO] train episode 302: reward = -254.04, steps = 200
    02:14:09 [INFO] train episode 303: reward = -139.14, steps = 200
    02:14:53 [INFO] train episode 304: reward = -256.20, steps = 200
    02:15:38 [INFO] train episode 305: reward = -129.71, steps = 200
    02:16:23 [INFO] train episode 306: reward = -138.65, steps = 200
    02:17:08 [INFO] train episode 307: reward = -11.28, steps = 200
    02:17:52 [INFO] train episode 308: reward = -363.82, steps = 200
    02:18:38 [INFO] train episode 309: reward = -133.72, steps = 200
    02:19:22 [INFO] train episode 310: reward = -386.97, steps = 200
    02:20:07 [INFO] train episode 311: reward = -129.97, steps = 200
    02:20:53 [INFO] train episode 312: reward = -238.23, steps = 200
    02:21:37 [INFO] train episode 313: reward = -263.25, steps = 200
    02:22:23 [INFO] train episode 314: reward = -252.38, steps = 200
    02:23:08 [INFO] train episode 315: reward = -141.11, steps = 200
    02:23:54 [INFO] train episode 316: reward = -131.52, steps = 200
    02:24:39 [INFO] train episode 317: reward = -141.00, steps = 200
    02:25:24 [INFO] train episode 318: reward = -144.32, steps = 200
    02:26:09 [INFO] train episode 319: reward = -354.82, steps = 200
    02:26:56 [INFO] train episode 320: reward = -146.45, steps = 200
    02:27:41 [INFO] train episode 321: reward = -142.70, steps = 200
    02:28:26 [INFO] train episode 322: reward = -149.18, steps = 200
    02:29:10 [INFO] train episode 323: reward = -260.30, steps = 200
    02:29:55 [INFO] train episode 324: reward = -146.20, steps = 200
    02:30:40 [INFO] train episode 325: reward = -147.51, steps = 200
    02:31:25 [INFO] train episode 326: reward = -351.62, steps = 200
    02:32:10 [INFO] train episode 327: reward = -26.76, steps = 200
    02:32:55 [INFO] train episode 328: reward = -152.73, steps = 200
    02:33:39 [INFO] train episode 329: reward = -277.68, steps = 200
    02:34:24 [INFO] train episode 330: reward = -272.10, steps = 200
    02:35:08 [INFO] train episode 331: reward = -511.88, steps = 200
    02:35:53 [INFO] train episode 332: reward = -505.30, steps = 200
    02:36:38 [INFO] train episode 333: reward = -377.27, steps = 200
    02:37:23 [INFO] train episode 334: reward = -124.82, steps = 200
    02:38:09 [INFO] train episode 335: reward = -509.91, steps = 200
    02:38:54 [INFO] train episode 336: reward = -500.62, steps = 200
    02:39:27 [INFO] train episode 337: reward = -378.70, steps = 200
    02:40:11 [INFO] train episode 338: reward = -501.04, steps = 200
    02:40:56 [INFO] train episode 339: reward = -388.74, steps = 200
    02:41:41 [INFO] train episode 340: reward = -484.26, steps = 200
    02:42:15 [INFO] train episode 341: reward = -386.19, steps = 200
    02:43:00 [INFO] train episode 342: reward = -486.55, steps = 200
    02:43:45 [INFO] train episode 343: reward = -488.01, steps = 200
    02:44:29 [INFO] train episode 344: reward = -250.64, steps = 200
    02:45:14 [INFO] train episode 345: reward = -387.91, steps = 200
    02:45:58 [INFO] train episode 346: reward = -510.38, steps = 200
    02:46:42 [INFO] train episode 347: reward = -483.42, steps = 200
    02:47:27 [INFO] train episode 348: reward = -488.33, steps = 200
    02:48:11 [INFO] train episode 349: reward = -365.64, steps = 200
    02:48:56 [INFO] train episode 350: reward = -263.37, steps = 200
    02:49:41 [INFO] train episode 351: reward = -506.30, steps = 200
    02:50:26 [INFO] train episode 352: reward = -384.13, steps = 200
    02:51:10 [INFO] train episode 353: reward = -503.64, steps = 200
    02:51:55 [INFO] train episode 354: reward = -378.24, steps = 200
    02:52:41 [INFO] train episode 355: reward = -372.56, steps = 200
    02:53:26 [INFO] train episode 356: reward = -464.91, steps = 200
    02:54:12 [INFO] train episode 357: reward = -334.28, steps = 200
    02:54:57 [INFO] train episode 358: reward = -138.82, steps = 200
    02:55:42 [INFO] train episode 359: reward = -383.96, steps = 200
    02:56:24 [INFO] train episode 360: reward = -491.77, steps = 200
    02:57:00 [INFO] train episode 361: reward = -145.44, steps = 200
    02:57:36 [INFO] train episode 362: reward = -172.86, steps = 200
    02:58:12 [INFO] train episode 363: reward = -373.13, steps = 200
    02:58:48 [INFO] train episode 364: reward = -263.49, steps = 200
    02:59:23 [INFO] train episode 365: reward = -362.18, steps = 200
    02:59:59 [INFO] train episode 366: reward = -262.13, steps = 200
    03:00:35 [INFO] train episode 367: reward = -145.10, steps = 200
    03:01:11 [INFO] train episode 368: reward = -268.55, steps = 200
    03:01:47 [INFO] train episode 369: reward = -250.44, steps = 200
    03:02:23 [INFO] train episode 370: reward = -258.48, steps = 200
    03:02:59 [INFO] train episode 371: reward = -139.40, steps = 200
    03:03:35 [INFO] train episode 372: reward = -361.79, steps = 200
    03:04:11 [INFO] train episode 373: reward = -152.58, steps = 200
    03:04:47 [INFO] train episode 374: reward = -256.90, steps = 200
    03:05:23 [INFO] train episode 375: reward = -252.20, steps = 200
    03:05:59 [INFO] train episode 376: reward = -139.85, steps = 200
    03:06:35 [INFO] train episode 377: reward = -469.02, steps = 200
    03:07:11 [INFO] train episode 378: reward = -135.77, steps = 200
    03:07:48 [INFO] train episode 379: reward = -246.54, steps = 200
    03:08:23 [INFO] train episode 380: reward = -253.41, steps = 200
    03:09:00 [INFO] train episode 381: reward = -395.97, steps = 200
    03:09:36 [INFO] train episode 382: reward = -263.93, steps = 200
    03:10:12 [INFO] train episode 383: reward = -391.88, steps = 200
    03:10:48 [INFO] train episode 384: reward = -389.35, steps = 200
    03:11:24 [INFO] train episode 385: reward = -369.63, steps = 200
    03:12:00 [INFO] train episode 386: reward = -257.44, steps = 200
    03:12:36 [INFO] train episode 387: reward = -413.40, steps = 200
    03:13:12 [INFO] train episode 388: reward = -379.60, steps = 200
    03:13:48 [INFO] train episode 389: reward = -265.46, steps = 200
    03:14:23 [INFO] train episode 390: reward = -369.10, steps = 200
    03:14:59 [INFO] train episode 391: reward = -5.30, steps = 200
    03:15:35 [INFO] train episode 392: reward = -256.47, steps = 200
    03:16:11 [INFO] train episode 393: reward = -241.87, steps = 200
    03:16:46 [INFO] train episode 394: reward = -384.62, steps = 200
    03:17:23 [INFO] train episode 395: reward = -129.81, steps = 200
    03:17:58 [INFO] train episode 396: reward = -248.67, steps = 200
    03:18:33 [INFO] train episode 397: reward = -244.89, steps = 200
    03:19:09 [INFO] train episode 398: reward = -124.78, steps = 200
    03:19:44 [INFO] train episode 399: reward = -133.50, steps = 200
    03:20:19 [INFO] train episode 400: reward = -135.10, steps = 200
    03:20:53 [INFO] train episode 401: reward = -142.30, steps = 200
    03:21:28 [INFO] train episode 402: reward = -133.58, steps = 200
    03:22:02 [INFO] train episode 403: reward = -9.07, steps = 200
    03:22:37 [INFO] train episode 404: reward = -233.33, steps = 200
    03:23:11 [INFO] train episode 405: reward = -130.43, steps = 200
    03:23:47 [INFO] train episode 406: reward = -248.22, steps = 200
    03:24:21 [INFO] train episode 407: reward = -8.88, steps = 200
    03:24:55 [INFO] train episode 408: reward = -125.48, steps = 200
    03:25:30 [INFO] train episode 409: reward = -122.92, steps = 200
    03:26:04 [INFO] train episode 410: reward = -135.57, steps = 200
    03:26:39 [INFO] train episode 411: reward = -126.39, steps = 200
    03:27:16 [INFO] train episode 412: reward = -131.60, steps = 200
    03:27:51 [INFO] train episode 413: reward = -259.66, steps = 200
    03:28:26 [INFO] train episode 414: reward = -133.98, steps = 200
    03:29:00 [INFO] train episode 415: reward = -146.23, steps = 200
    03:29:35 [INFO] train episode 416: reward = -274.51, steps = 200
    03:30:10 [INFO] train episode 417: reward = -393.90, steps = 200
    03:30:45 [INFO] train episode 418: reward = -143.77, steps = 200
    03:31:19 [INFO] train episode 419: reward = -254.26, steps = 200
    03:31:54 [INFO] train episode 420: reward = -147.34, steps = 200
    03:32:29 [INFO] train episode 421: reward = -386.88, steps = 200
    03:33:02 [INFO] train episode 422: reward = -393.22, steps = 200
    03:33:37 [INFO] train episode 423: reward = -375.19, steps = 200
    03:34:11 [INFO] train episode 424: reward = -509.10, steps = 200
    03:34:44 [INFO] train episode 425: reward = -387.57, steps = 200
    03:35:19 [INFO] train episode 426: reward = -511.59, steps = 200
    03:35:53 [INFO] train episode 427: reward = -388.49, steps = 200
    03:36:28 [INFO] train episode 428: reward = -15.63, steps = 200
    03:37:02 [INFO] train episode 429: reward = -513.50, steps = 200
    03:37:37 [INFO] train episode 430: reward = -389.41, steps = 200
    03:38:12 [INFO] train episode 431: reward = -618.31, steps = 200
    03:38:46 [INFO] train episode 432: reward = -391.02, steps = 200
    03:39:21 [INFO] train episode 433: reward = -401.49, steps = 200
    03:39:55 [INFO] train episode 434: reward = -150.33, steps = 200
    03:40:30 [INFO] train episode 435: reward = -268.64, steps = 200
    03:41:05 [INFO] train episode 436: reward = -386.93, steps = 200
    03:41:39 [INFO] train episode 437: reward = -274.03, steps = 200
    03:42:14 [INFO] train episode 438: reward = -127.68, steps = 200
    03:42:48 [INFO] train episode 439: reward = -237.95, steps = 200
    03:43:23 [INFO] train episode 440: reward = -132.51, steps = 200
    03:43:57 [INFO] train episode 441: reward = -143.46, steps = 200
    03:44:31 [INFO] train episode 442: reward = -239.78, steps = 200
    03:45:05 [INFO] train episode 443: reward = -139.46, steps = 200
    03:45:39 [INFO] train episode 444: reward = -247.07, steps = 200
    03:46:14 [INFO] train episode 445: reward = -131.12, steps = 200
    03:46:48 [INFO] train episode 446: reward = -251.54, steps = 200
    03:47:23 [INFO] train episode 447: reward = -135.20, steps = 200
    03:47:57 [INFO] train episode 448: reward = -237.85, steps = 200
    03:48:31 [INFO] train episode 449: reward = -132.34, steps = 200
    03:49:05 [INFO] train episode 450: reward = -261.28, steps = 200
    03:49:39 [INFO] train episode 451: reward = -142.68, steps = 200
    03:50:14 [INFO] train episode 452: reward = -141.20, steps = 200
    03:50:48 [INFO] train episode 453: reward = -22.50, steps = 200
    03:51:22 [INFO] train episode 454: reward = -143.55, steps = 200
    03:51:57 [INFO] train episode 455: reward = -386.95, steps = 200
    03:52:32 [INFO] train episode 456: reward = -377.70, steps = 200
    03:53:07 [INFO] train episode 457: reward = -367.26, steps = 200
    03:53:41 [INFO] train episode 458: reward = -406.48, steps = 200
    03:54:16 [INFO] train episode 459: reward = -270.94, steps = 200
    03:54:51 [INFO] train episode 460: reward = -396.44, steps = 200
    03:55:25 [INFO] train episode 461: reward = -392.85, steps = 200
    03:56:00 [INFO] train episode 462: reward = -260.69, steps = 200
    03:56:35 [INFO] train episode 463: reward = -270.38, steps = 200
    03:57:10 [INFO] train episode 464: reward = -521.54, steps = 200
    03:57:44 [INFO] train episode 465: reward = -150.34, steps = 200
    03:58:19 [INFO] train episode 466: reward = -398.00, steps = 200
    03:58:53 [INFO] train episode 467: reward = -398.03, steps = 200
    03:59:28 [INFO] train episode 468: reward = -561.75, steps = 200
    04:00:03 [INFO] train episode 469: reward = -520.42, steps = 200
    04:00:37 [INFO] train episode 470: reward = -619.00, steps = 200
    04:01:12 [INFO] train episode 471: reward = -377.04, steps = 200
    04:01:46 [INFO] train episode 472: reward = -387.21, steps = 200
    04:02:20 [INFO] train episode 473: reward = -135.25, steps = 200
    04:02:54 [INFO] train episode 474: reward = -137.30, steps = 200
    04:03:28 [INFO] train episode 475: reward = -26.36, steps = 200
    04:04:02 [INFO] train episode 476: reward = -362.67, steps = 200
    04:04:35 [INFO] train episode 477: reward = -147.22, steps = 200
    04:05:08 [INFO] train episode 478: reward = -265.20, steps = 200
    04:05:42 [INFO] train episode 479: reward = -256.98, steps = 200
    04:06:16 [INFO] train episode 480: reward = -253.82, steps = 200
    04:06:50 [INFO] train episode 481: reward = -142.87, steps = 200
    04:07:24 [INFO] train episode 482: reward = -263.40, steps = 200
    04:07:58 [INFO] train episode 483: reward = -369.22, steps = 200
    04:08:32 [INFO] train episode 484: reward = -376.75, steps = 200
    04:09:07 [INFO] train episode 485: reward = -137.94, steps = 200
    04:09:45 [INFO] train episode 486: reward = -138.91, steps = 200
    04:10:24 [INFO] train episode 487: reward = -248.26, steps = 200
    04:11:00 [INFO] train episode 488: reward = -374.20, steps = 200
    04:11:33 [INFO] train episode 489: reward = -139.60, steps = 200
    04:12:07 [INFO] train episode 490: reward = -131.70, steps = 200
    04:12:41 [INFO] train episode 491: reward = -373.46, steps = 200
    04:13:14 [INFO] train episode 492: reward = -135.96, steps = 200
    04:13:48 [INFO] train episode 493: reward = -134.39, steps = 200
    04:14:23 [INFO] train episode 494: reward = -271.40, steps = 200
    04:14:56 [INFO] train episode 495: reward = -141.92, steps = 200
    04:15:31 [INFO] train episode 496: reward = -138.07, steps = 200
    04:16:05 [INFO] train episode 497: reward = -136.79, steps = 200
    04:16:39 [INFO] train episode 498: reward = -125.25, steps = 200
    04:17:12 [INFO] train episode 499: reward = -139.96, steps = 200
    04:17:46 [INFO] train episode 500: reward = -117.19, steps = 200
    04:18:20 [INFO] train episode 501: reward = -246.38, steps = 200
    04:18:54 [INFO] train episode 502: reward = -237.78, steps = 200
    04:19:20 [INFO] train episode 503: reward = -256.88, steps = 200
    04:19:46 [INFO] train episode 504: reward = -124.74, steps = 200
    04:20:13 [INFO] train episode 505: reward = -124.80, steps = 200
    04:20:40 [INFO] train episode 506: reward = -135.13, steps = 200
    04:21:06 [INFO] train episode 507: reward = -135.72, steps = 200
    04:21:32 [INFO] train episode 508: reward = -383.88, steps = 200
    04:21:58 [INFO] train episode 509: reward = -135.57, steps = 200
    04:22:24 [INFO] train episode 510: reward = -133.27, steps = 200
    04:22:50 [INFO] train episode 511: reward = -130.36, steps = 200
    04:23:17 [INFO] train episode 512: reward = -238.47, steps = 200
    04:23:43 [INFO] train episode 513: reward = -265.58, steps = 200
    04:24:09 [INFO] train episode 514: reward = -154.38, steps = 200
    04:24:36 [INFO] train episode 515: reward = -128.59, steps = 200
    04:25:02 [INFO] train episode 516: reward = -31.77, steps = 200
    04:25:28 [INFO] train episode 517: reward = -142.36, steps = 200
    04:25:54 [INFO] train episode 518: reward = -241.07, steps = 200
    04:26:20 [INFO] train episode 519: reward = -129.69, steps = 200
    04:26:48 [INFO] train episode 520: reward = -129.90, steps = 200
    04:27:15 [INFO] train episode 521: reward = -129.24, steps = 200
    04:27:41 [INFO] train episode 522: reward = -10.95, steps = 200
    04:28:07 [INFO] train episode 523: reward = -252.28, steps = 200
    04:28:33 [INFO] train episode 524: reward = -10.58, steps = 200
    04:28:59 [INFO] train episode 525: reward = -252.32, steps = 200
    04:29:25 [INFO] train episode 526: reward = -249.32, steps = 200
    04:29:51 [INFO] train episode 527: reward = -129.62, steps = 200
    04:30:17 [INFO] train episode 528: reward = -133.24, steps = 200
    04:30:43 [INFO] train episode 529: reward = -246.56, steps = 200
    04:31:09 [INFO] train episode 530: reward = -360.84, steps = 200
    04:31:34 [INFO] train episode 531: reward = -134.28, steps = 200
    04:31:57 [INFO] train episode 532: reward = -243.18, steps = 200
    04:32:19 [INFO] train episode 533: reward = -246.08, steps = 200
    04:32:41 [INFO] train episode 534: reward = -143.80, steps = 200
    04:33:03 [INFO] train episode 535: reward = -348.01, steps = 200
    04:33:25 [INFO] train episode 536: reward = -138.30, steps = 200
    04:33:47 [INFO] train episode 537: reward = -146.33, steps = 200
    04:34:10 [INFO] train episode 538: reward = -152.73, steps = 200
    04:34:32 [INFO] train episode 539: reward = -150.42, steps = 200
    04:34:54 [INFO] train episode 540: reward = -140.84, steps = 200
    04:35:16 [INFO] train episode 541: reward = -250.79, steps = 200
    04:35:37 [INFO] train episode 542: reward = -260.76, steps = 200
    04:35:58 [INFO] train episode 543: reward = -261.84, steps = 200
    04:36:20 [INFO] train episode 544: reward = -137.73, steps = 200
    04:36:42 [INFO] train episode 545: reward = -150.29, steps = 200
    04:37:01 [INFO] train episode 546: reward = -147.02, steps = 200
    04:37:20 [INFO] train episode 547: reward = -144.03, steps = 200
    04:37:39 [INFO] train episode 548: reward = -147.71, steps = 200
    04:37:58 [INFO] train episode 549: reward = -155.13, steps = 200
    04:38:16 [INFO] train episode 550: reward = -143.84, steps = 200
    04:38:35 [INFO] train episode 551: reward = -369.86, steps = 200
    04:38:54 [INFO] train episode 552: reward = -29.50, steps = 200
    04:39:13 [INFO] train episode 553: reward = -264.57, steps = 200
    04:39:31 [INFO] train episode 554: reward = -265.22, steps = 200
    04:39:50 [INFO] train episode 555: reward = -148.16, steps = 200
    04:40:09 [INFO] train episode 556: reward = -157.11, steps = 200
    04:40:28 [INFO] train episode 557: reward = -279.21, steps = 200
    04:40:47 [INFO] train episode 558: reward = -369.89, steps = 200
    04:41:05 [INFO] train episode 559: reward = -30.47, steps = 200
    04:41:24 [INFO] train episode 560: reward = -266.86, steps = 200
    04:41:42 [INFO] train episode 561: reward = -152.73, steps = 200
    04:42:01 [INFO] train episode 562: reward = -272.90, steps = 200
    04:42:20 [INFO] train episode 563: reward = -288.95, steps = 200
    04:42:39 [INFO] train episode 564: reward = -146.60, steps = 200
    04:42:57 [INFO] train episode 565: reward = -155.58, steps = 200
    04:43:16 [INFO] train episode 566: reward = -393.99, steps = 200
    04:43:35 [INFO] train episode 567: reward = -145.00, steps = 200
    04:43:54 [INFO] train episode 568: reward = -271.42, steps = 200
    04:44:13 [INFO] train episode 569: reward = -150.45, steps = 200
    04:44:32 [INFO] train episode 570: reward = -372.80, steps = 200
    04:44:50 [INFO] train episode 571: reward = -381.20, steps = 200
    04:45:09 [INFO] train episode 572: reward = -146.33, steps = 200
    04:45:28 [INFO] train episode 573: reward = -148.41, steps = 200
    04:45:47 [INFO] train episode 574: reward = -268.54, steps = 200
    04:46:05 [INFO] train episode 575: reward = -261.68, steps = 200
    04:46:24 [INFO] train episode 576: reward = -152.88, steps = 200
    04:46:43 [INFO] train episode 577: reward = -246.33, steps = 200
    04:47:02 [INFO] train episode 578: reward = -146.65, steps = 200
    04:47:21 [INFO] train episode 579: reward = -145.24, steps = 200
    04:47:40 [INFO] train episode 580: reward = -247.96, steps = 200
    04:47:59 [INFO] train episode 581: reward = -372.28, steps = 200
    04:48:18 [INFO] train episode 582: reward = -355.20, steps = 200
    04:48:37 [INFO] train episode 583: reward = -256.57, steps = 200
    04:48:56 [INFO] train episode 584: reward = -135.31, steps = 200
    04:49:14 [INFO] train episode 585: reward = -30.75, steps = 200
    04:49:33 [INFO] train episode 586: reward = -148.51, steps = 200
    04:49:52 [INFO] train episode 587: reward = -22.21, steps = 200
    04:50:08 [INFO] train episode 588: reward = -483.79, steps = 200
    04:50:23 [INFO] train episode 589: reward = -27.13, steps = 200
    04:50:39 [INFO] train episode 590: reward = -625.40, steps = 200
    04:50:54 [INFO] train episode 591: reward = -267.43, steps = 200
    04:51:10 [INFO] train episode 592: reward = -148.58, steps = 200
    04:51:26 [INFO] train episode 593: reward = -572.71, steps = 200
    04:51:41 [INFO] train episode 594: reward = -137.14, steps = 200
    04:51:56 [INFO] train episode 595: reward = -139.26, steps = 200
    04:52:12 [INFO] train episode 596: reward = -143.63, steps = 200
    04:52:28 [INFO] train episode 597: reward = -160.92, steps = 200
    04:52:43 [INFO] train episode 598: reward = -259.13, steps = 200
    04:52:59 [INFO] train episode 599: reward = -370.46, steps = 200
    04:53:14 [INFO] train episode 600: reward = -17.95, steps = 200
    04:53:29 [INFO] train episode 601: reward = -131.81, steps = 200
    04:53:45 [INFO] train episode 602: reward = -318.74, steps = 200
    04:54:00 [INFO] train episode 603: reward = -251.85, steps = 200
    04:54:16 [INFO] train episode 604: reward = -276.33, steps = 200
    04:54:31 [INFO] train episode 605: reward = -144.22, steps = 200
    04:54:46 [INFO] train episode 606: reward = -399.04, steps = 200
    04:55:00 [INFO] train episode 607: reward = -148.95, steps = 200
    04:55:15 [INFO] train episode 608: reward = -273.41, steps = 200
    04:55:29 [INFO] train episode 609: reward = -497.73, steps = 200
    04:55:44 [INFO] train episode 610: reward = -511.02, steps = 200
    04:55:58 [INFO] train episode 611: reward = -22.77, steps = 200
    04:56:13 [INFO] train episode 612: reward = -264.08, steps = 200
    04:56:27 [INFO] train episode 613: reward = -256.93, steps = 200
    04:56:42 [INFO] train episode 614: reward = -392.95, steps = 200
    04:56:56 [INFO] train episode 615: reward = -389.96, steps = 200
    04:57:11 [INFO] train episode 616: reward = -258.54, steps = 200
    04:57:26 [INFO] train episode 617: reward = -188.62, steps = 200
    04:57:41 [INFO] train episode 618: reward = -249.07, steps = 200
    04:57:55 [INFO] train episode 619: reward = -253.72, steps = 200
    04:58:10 [INFO] train episode 620: reward = -379.30, steps = 200
    04:58:25 [INFO] train episode 621: reward = -136.72, steps = 200
    04:58:39 [INFO] train episode 622: reward = -271.42, steps = 200
    04:58:54 [INFO] train episode 623: reward = -500.82, steps = 200
    04:59:09 [INFO] train episode 624: reward = -365.35, steps = 200
    04:59:23 [INFO] train episode 625: reward = -379.10, steps = 200
    04:59:36 [INFO] train episode 626: reward = -20.71, steps = 200
    04:59:45 [INFO] train episode 627: reward = -237.67, steps = 200
    04:59:59 [INFO] train episode 628: reward = -152.22, steps = 200
    05:00:05 [INFO] train episode 629: reward = -464.92, steps = 200
    05:00:16 [INFO] train episode 630: reward = -146.03, steps = 200
    05:00:25 [INFO] train episode 631: reward = -142.56, steps = 200
    05:00:32 [INFO] train episode 632: reward = -140.50, steps = 200
    05:00:45 [INFO] train episode 633: reward = -23.94, steps = 200
    05:01:00 [INFO] train episode 634: reward = -19.75, steps = 200
    05:01:14 [INFO] train episode 635: reward = -268.09, steps = 200
    05:01:29 [INFO] train episode 636: reward = -134.34, steps = 200
    05:01:43 [INFO] train episode 637: reward = -134.32, steps = 200
    05:01:57 [INFO] train episode 638: reward = -137.16, steps = 200
    05:02:12 [INFO] train episode 639: reward = -258.70, steps = 200
    05:02:27 [INFO] train episode 640: reward = -139.23, steps = 200
    05:02:41 [INFO] train episode 641: reward = -140.13, steps = 200
    05:02:55 [INFO] train episode 642: reward = -247.09, steps = 200
    05:03:10 [INFO] train episode 643: reward = -267.13, steps = 200
    05:03:22 [INFO] train episode 644: reward = -258.63, steps = 200
    05:03:31 [INFO] train episode 645: reward = -380.09, steps = 200
    05:03:45 [INFO] train episode 646: reward = -260.87, steps = 200
    05:04:00 [INFO] train episode 647: reward = -264.98, steps = 200
    05:04:14 [INFO] train episode 648: reward = -130.97, steps = 200
    05:04:29 [INFO] train episode 649: reward = -253.48, steps = 200
    05:04:43 [INFO] train episode 650: reward = -624.01, steps = 200
    05:04:57 [INFO] train episode 651: reward = -491.16, steps = 200
    05:05:12 [INFO] train episode 652: reward = -568.33, steps = 200
    05:05:26 [INFO] train episode 653: reward = -132.46, steps = 200
    05:05:40 [INFO] train episode 654: reward = -263.41, steps = 200
    05:05:47 [INFO] train episode 655: reward = -262.41, steps = 200
    05:06:02 [INFO] train episode 656: reward = -503.54, steps = 200
    05:06:16 [INFO] train episode 657: reward = -490.96, steps = 200
    05:06:31 [INFO] train episode 658: reward = -385.64, steps = 200
    05:06:46 [INFO] train episode 659: reward = -16.94, steps = 200
    05:07:00 [INFO] train episode 660: reward = -387.14, steps = 200
    05:07:10 [INFO] train episode 661: reward = -391.91, steps = 200
    05:07:22 [INFO] train episode 662: reward = -378.95, steps = 200
    05:07:37 [INFO] train episode 663: reward = -382.88, steps = 200
    05:07:44 [INFO] train episode 664: reward = -269.38, steps = 200
    05:07:50 [INFO] train episode 665: reward = -248.68, steps = 200
    05:08:02 [INFO] train episode 666: reward = -257.76, steps = 200
    05:08:09 [INFO] train episode 667: reward = -343.24, steps = 200
    05:08:23 [INFO] train episode 668: reward = -266.97, steps = 200
    05:08:38 [INFO] train episode 669: reward = -147.28, steps = 200
    05:08:52 [INFO] train episode 670: reward = -373.44, steps = 200
    05:09:01 [INFO] train episode 671: reward = -369.80, steps = 200
    05:09:12 [INFO] train episode 672: reward = -146.29, steps = 200
    05:09:26 [INFO] train episode 673: reward = -277.42, steps = 200
    05:09:41 [INFO] train episode 674: reward = -371.51, steps = 200
    05:09:50 [INFO] train episode 675: reward = -257.71, steps = 200
    05:09:56 [INFO] train episode 676: reward = -695.70, steps = 200
    05:10:07 [INFO] train episode 677: reward = -267.22, steps = 200
    05:10:15 [INFO] train episode 678: reward = -141.26, steps = 200
    05:10:30 [INFO] train episode 679: reward = -330.30, steps = 200
    05:10:44 [INFO] train episode 680: reward = -139.12, steps = 200
    05:10:59 [INFO] train episode 681: reward = -391.35, steps = 200
    05:11:13 [INFO] train episode 682: reward = -376.18, steps = 200
    05:11:28 [INFO] train episode 683: reward = -147.17, steps = 200
    05:11:42 [INFO] train episode 684: reward = -145.56, steps = 200
    05:11:50 [INFO] train episode 685: reward = -149.14, steps = 200
    05:12:04 [INFO] train episode 686: reward = -21.33, steps = 200
    05:12:18 [INFO] train episode 687: reward = -262.64, steps = 200
    05:12:33 [INFO] train episode 688: reward = -499.90, steps = 200
    05:12:47 [INFO] train episode 689: reward = -257.49, steps = 200
    05:13:02 [INFO] train episode 690: reward = -337.39, steps = 200
    05:13:17 [INFO] train episode 691: reward = -379.15, steps = 200
    05:13:31 [INFO] train episode 692: reward = -258.72, steps = 200
    05:13:46 [INFO] train episode 693: reward = -370.76, steps = 200
    05:13:52 [INFO] train episode 694: reward = -494.34, steps = 200
    05:14:07 [INFO] train episode 695: reward = -501.50, steps = 200
    05:14:21 [INFO] train episode 696: reward = -390.46, steps = 200
    05:14:36 [INFO] train episode 697: reward = -27.81, steps = 200
    05:14:44 [INFO] train episode 698: reward = -246.19, steps = 200
    05:14:58 [INFO] train episode 699: reward = -485.25, steps = 200
    05:15:13 [INFO] train episode 700: reward = -606.27, steps = 200
    05:15:27 [INFO] train episode 701: reward = -136.10, steps = 200
    05:15:37 [INFO] train episode 702: reward = -272.39, steps = 200
    05:15:46 [INFO] train episode 703: reward = -264.44, steps = 200
    05:16:01 [INFO] train episode 704: reward = -483.69, steps = 200
    05:16:11 [INFO] train episode 705: reward = -377.25, steps = 200
    05:16:23 [INFO] train episode 706: reward = -587.57, steps = 200
    05:16:38 [INFO] train episode 707: reward = -378.68, steps = 200
    05:16:52 [INFO] train episode 708: reward = -256.20, steps = 200
    05:17:03 [INFO] train episode 709: reward = -140.29, steps = 200
    05:17:13 [INFO] train episode 710: reward = -266.18, steps = 200
    05:17:28 [INFO] train episode 711: reward = -252.68, steps = 200
    05:17:42 [INFO] train episode 712: reward = -362.65, steps = 200
    05:17:52 [INFO] train episode 713: reward = -20.84, steps = 200
    05:18:06 [INFO] train episode 714: reward = -257.77, steps = 200
    05:18:19 [INFO] train episode 715: reward = -253.80, steps = 200
    05:18:28 [INFO] train episode 716: reward = -147.25, steps = 200
    05:18:42 [INFO] train episode 717: reward = -149.85, steps = 200
    05:18:57 [INFO] train episode 718: reward = -21.55, steps = 200
    05:19:11 [INFO] train episode 719: reward = -256.47, steps = 200
    05:19:26 [INFO] train episode 720: reward = -126.24, steps = 200
    05:19:40 [INFO] train episode 721: reward = -137.32, steps = 200
    05:19:54 [INFO] train episode 722: reward = -134.54, steps = 200
    05:20:09 [INFO] train episode 723: reward = -141.33, steps = 200
    05:20:24 [INFO] train episode 724: reward = -258.30, steps = 200
    05:20:39 [INFO] train episode 725: reward = -262.27, steps = 200
    05:20:54 [INFO] train episode 726: reward = -128.37, steps = 200
    05:21:08 [INFO] train episode 727: reward = -265.61, steps = 200
    05:21:23 [INFO] train episode 728: reward = -243.92, steps = 200
    05:21:37 [INFO] train episode 729: reward = -137.17, steps = 200
    05:21:52 [INFO] train episode 730: reward = -487.09, steps = 200
    05:22:07 [INFO] train episode 731: reward = -144.12, steps = 200
    05:22:22 [INFO] train episode 732: reward = -127.64, steps = 200
    05:22:36 [INFO] train episode 733: reward = -265.59, steps = 200
    05:22:51 [INFO] train episode 734: reward = -12.00, steps = 200
    05:23:05 [INFO] train episode 735: reward = -130.40, steps = 200
    05:23:20 [INFO] train episode 736: reward = -129.79, steps = 200
    05:23:34 [INFO] train episode 737: reward = -130.46, steps = 200
    05:23:49 [INFO] train episode 738: reward = -134.46, steps = 200
    05:24:04 [INFO] train episode 739: reward = -132.38, steps = 200
    05:24:18 [INFO] train episode 740: reward = -142.86, steps = 200
    05:24:33 [INFO] train episode 741: reward = -129.09, steps = 200
    05:24:47 [INFO] train episode 742: reward = -248.97, steps = 200
    05:25:02 [INFO] train episode 743: reward = -129.60, steps = 200
    05:25:12 [INFO] train episode 744: reward = -130.07, steps = 200
    05:25:22 [INFO] train episode 745: reward = -128.66, steps = 200
    05:25:37 [INFO] train episode 746: reward = -131.91, steps = 200
    05:25:51 [INFO] train episode 747: reward = -128.17, steps = 200
    05:26:06 [INFO] train episode 748: reward = -131.47, steps = 200
    05:26:21 [INFO] train episode 749: reward = -130.54, steps = 200
    05:26:35 [INFO] train episode 750: reward = -9.30, steps = 200
    05:26:45 [INFO] train episode 751: reward = -140.80, steps = 200
    05:26:55 [INFO] train episode 752: reward = -128.94, steps = 200
    05:26:55 [INFO] ==== test ====
    05:26:55 [INFO] test episode 0: reward = -9.61, steps = 200
    05:26:55 [INFO] test episode 1: reward = -9.75, steps = 200
    05:26:55 [INFO] test episode 2: reward = -252.07, steps = 200
    05:26:55 [INFO] test episode 3: reward = -135.83, steps = 200
    05:26:56 [INFO] test episode 4: reward = -12.33, steps = 200
    05:26:56 [INFO] test episode 5: reward = -244.85, steps = 200
    05:26:56 [INFO] test episode 6: reward = -369.31, steps = 200
    05:26:56 [INFO] test episode 7: reward = -136.45, steps = 200
    05:26:56 [INFO] test episode 8: reward = -135.23, steps = 200
    05:26:56 [INFO] test episode 9: reward = -9.71, steps = 200
    05:26:56 [INFO] test episode 10: reward = -9.52, steps = 200
    05:26:56 [INFO] test episode 11: reward = -11.22, steps = 200
    05:26:56 [INFO] test episode 12: reward = -131.48, steps = 200
    05:26:57 [INFO] test episode 13: reward = -370.97, steps = 200
    05:26:57 [INFO] test episode 14: reward = -254.68, steps = 200
    05:26:57 [INFO] test episode 15: reward = -134.99, steps = 200
    05:26:57 [INFO] test episode 16: reward = -367.24, steps = 200
    05:26:57 [INFO] test episode 17: reward = -257.25, steps = 200
    05:26:57 [INFO] test episode 18: reward = -251.54, steps = 200
    05:26:57 [INFO] test episode 19: reward = -254.37, steps = 200
    05:26:57 [INFO] test episode 20: reward = -10.54, steps = 200
    05:26:57 [INFO] test episode 21: reward = -365.44, steps = 200
    05:26:57 [INFO] test episode 22: reward = -254.77, steps = 200
    05:26:58 [INFO] test episode 23: reward = -137.39, steps = 200
    05:26:58 [INFO] test episode 24: reward = -135.34, steps = 200
    05:26:58 [INFO] test episode 25: reward = -436.01, steps = 200
    05:26:58 [INFO] test episode 26: reward = -130.01, steps = 200
    05:26:58 [INFO] test episode 27: reward = -136.92, steps = 200
    05:26:58 [INFO] test episode 28: reward = -252.89, steps = 200
    05:26:58 [INFO] test episode 29: reward = -131.79, steps = 200
    05:26:58 [INFO] test episode 30: reward = -134.19, steps = 200
    05:26:58 [INFO] test episode 31: reward = -368.75, steps = 200
    05:26:59 [INFO] test episode 32: reward = -138.49, steps = 200
    05:26:59 [INFO] test episode 33: reward = -319.54, steps = 200
    05:26:59 [INFO] test episode 34: reward = -256.56, steps = 200
    05:26:59 [INFO] test episode 35: reward = -339.64, steps = 200
    05:26:59 [INFO] test episode 36: reward = -244.61, steps = 200
    05:26:59 [INFO] test episode 37: reward = -10.47, steps = 200
    05:26:59 [INFO] test episode 38: reward = -137.76, steps = 200
    05:26:59 [INFO] test episode 39: reward = -242.82, steps = 200
    05:26:59 [INFO] test episode 40: reward = -361.32, steps = 200
    05:27:00 [INFO] test episode 41: reward = -248.25, steps = 200
    05:27:00 [INFO] test episode 42: reward = -129.70, steps = 200
    05:27:00 [INFO] test episode 43: reward = -253.74, steps = 200
    05:27:00 [INFO] test episode 44: reward = -253.95, steps = 200
    05:27:00 [INFO] test episode 45: reward = -250.36, steps = 200
    05:27:00 [INFO] test episode 46: reward = -130.20, steps = 200
    05:27:00 [INFO] test episode 47: reward = -292.78, steps = 200
    05:27:00 [INFO] test episode 48: reward = -128.97, steps = 200
    05:27:00 [INFO] test episode 49: reward = -248.38, steps = 200
    05:27:00 [INFO] test episode 50: reward = -9.78, steps = 200
    05:27:01 [INFO] test episode 51: reward = -360.73, steps = 200
    05:27:01 [INFO] test episode 52: reward = -130.29, steps = 200
    05:27:01 [INFO] test episode 53: reward = -258.35, steps = 200
    05:27:01 [INFO] test episode 54: reward = -251.22, steps = 200
    05:27:01 [INFO] test episode 55: reward = -136.61, steps = 200
    05:27:01 [INFO] test episode 56: reward = -131.08, steps = 200
    05:27:01 [INFO] test episode 57: reward = -481.58, steps = 200
    05:27:01 [INFO] test episode 58: reward = -252.20, steps = 200
    05:27:01 [INFO] test episode 59: reward = -376.63, steps = 200
    05:27:02 [INFO] test episode 60: reward = -245.14, steps = 200
    05:27:02 [INFO] test episode 61: reward = -132.08, steps = 200
    05:27:02 [INFO] test episode 62: reward = -252.34, steps = 200
    05:27:02 [INFO] test episode 63: reward = -369.04, steps = 200
    05:27:02 [INFO] test episode 64: reward = -132.32, steps = 200
    05:27:02 [INFO] test episode 65: reward = -132.45, steps = 200
    05:27:02 [INFO] test episode 66: reward = -131.34, steps = 200
    05:27:02 [INFO] test episode 67: reward = -347.01, steps = 200
    05:27:02 [INFO] test episode 68: reward = -10.80, steps = 200
    05:27:03 [INFO] test episode 69: reward = -135.18, steps = 200
    05:27:03 [INFO] test episode 70: reward = -130.36, steps = 200
    05:27:03 [INFO] test episode 71: reward = -139.63, steps = 200
    05:27:03 [INFO] test episode 72: reward = -132.52, steps = 200
    05:27:03 [INFO] test episode 73: reward = -126.73, steps = 200
    05:27:03 [INFO] test episode 74: reward = -132.41, steps = 200
    05:27:03 [INFO] test episode 75: reward = -10.50, steps = 200
    05:27:03 [INFO] test episode 76: reward = -357.46, steps = 200
    05:27:03 [INFO] test episode 77: reward = -506.79, steps = 200
    05:27:03 [INFO] test episode 78: reward = -136.58, steps = 200
    05:27:04 [INFO] test episode 79: reward = -363.59, steps = 200
    05:27:04 [INFO] test episode 80: reward = -254.00, steps = 200
    05:27:04 [INFO] test episode 81: reward = -247.59, steps = 200
    05:27:04 [INFO] test episode 82: reward = -138.31, steps = 200
    05:27:04 [INFO] test episode 83: reward = -11.14, steps = 200
    05:27:04 [INFO] test episode 84: reward = -254.55, steps = 200
    05:27:04 [INFO] test episode 85: reward = -253.99, steps = 200
    05:27:04 [INFO] test episode 86: reward = -339.10, steps = 200
    05:27:04 [INFO] test episode 87: reward = -365.86, steps = 200
    05:27:05 [INFO] test episode 88: reward = -370.71, steps = 200
    05:27:05 [INFO] test episode 89: reward = -256.71, steps = 200
    05:27:05 [INFO] test episode 90: reward = -367.21, steps = 200
    05:27:05 [INFO] test episode 91: reward = -131.47, steps = 200
    05:27:05 [INFO] test episode 92: reward = -252.01, steps = 200
    05:27:05 [INFO] test episode 93: reward = -11.49, steps = 200
    05:27:05 [INFO] test episode 94: reward = -252.88, steps = 200
    05:27:05 [INFO] test episode 95: reward = -130.58, steps = 200
    05:27:05 [INFO] test episode 96: reward = -255.21, steps = 200
    05:27:05 [INFO] test episode 97: reward = -255.73, steps = 200
    05:27:06 [INFO] test episode 98: reward = -9.77, steps = 200
    05:27:06 [INFO] test episode 99: reward = -370.92, steps = 200
    05:27:06 [INFO] average episode reward = -206.82 ± 120.74

In [7]:

    env.close()