Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Open In Colab   Open in Kaggle

Macrocircuits

Macrocircuits: Leveraging neural architectural priors and modularity in embodied agents

By Neuromatch Academy

Content creators: Divyansha Lachi, Kseniia Shilova

Content reviewers: Eva Dyer, Hannah Choi

Production editors: Konstantine Tsafatinos, Ella Batty, Spiros Chavlis, Samuele Bolotta, Hlib Solodzhuk


Background

This project explores how we can build a biologically inspired artificial neural network (ANN) architecture, derived from the C. Elegans motor circuit, for the control of a simulated Swimmer agent. Traditional motor control ANNs often rely on generic, fully connected multilayer perceptrons (MLPs), which demand extensive training data, offer limited transferability, and possess complex internal dynamics that challenge interpretability. The project aims to understand how the biologically motivated ANN, which is shaped by evolution to be highly structured and sparse, could help to solve these problems and provide advantages in the domain of motor control. We will train MLPs using algorithms such as PPO, DDPG, and ES, and compare their performance in terms of rewards and sample efficiency with our bio-inspired ANN. The project also includes visualizing the C. Elegans connectome and building the network using this circuitry. We will conduct various ablation analyses by removing sign and weight-sharing constraints, and altering environmental parameters like the swimmer’s length or viscosity. These investigations aim to understand how architecture and modularity impact performance and learning across different environments. Finally, the project aims at building an agent that is robust to environmental variations, navigating towards specific targets, and enhancing our understanding of bio-inspired motor control.

Relevant references:

This notebook uses code from the following GitHub repository: ncap by Nikhil X. Bhattasali and Anthony M. Zador and Tatiana A. Engel.

Infrastructure note: This notebook contains GPU install guide as well as CPU ones for different OS.

Install and import feedback gadget

Source

Project Background

Youtube
Bilibili

Project slides

If you want to download the slides: https://osf.io/download/cz93b/
Loading...

Project Template

Source
Loading...

Tutorial links

This particular project connects a couple of distinct ideas explored throughout the course. Firstly, the innate ability to learn a certain set of actions quickly is the main topic of Tutorial 4 for W2D4 on biological meta-learning. The focus comes with the observation that the brain is not of a generic architecture but is a highly structured and optimized hierarchy of modules, the importance of which is highlighted in Tutorial 3 for W2D1, forming inductive bias for efficient motor control. The default model for the agent used here is already known Actor-Critic; you had the opportunity to observe in already mentioned tutorials as well as in Tutorial 3 for W1D2.


Scetion 0: Initial setup

Disclaimer: As an alternative to Google Colab, Kaggle, and local installation, we have prepared a Dockerfile with the instructions on the virtual environment setup. It will allow you to work locally with no interventions into already installed packages (you will just need to install Docker and run two commands). Grab a Dockerfile, put it in the same folder as this notebook, and follow the instructions in README file.

IF USING COLAB (recommended):

Uncomment the cell below and run it.

Installing Dependencies (Colab GPU case, uncomment if you want to use this one)

Source
---------------------------------------------------------------------------
FileNotFoundError                         Traceback (most recent call last)
Cell In[4], line 6
      4 import os
      5 import subprocess
----> 6 if subprocess.run('nvidia-smi').returncode:
      7   raise RuntimeError(
      8       'Cannot communicate with GPU. '
      9       'Make sure you are using a GPU Colab runtime. '
     10       'Go to the Runtime menu and select Choose runtime type.')
     12 # Add an ICD config so that glvnd can pick up the Nvidia EGL driver.
     13 # This is usually installed as part of an Nvidia driver package, but the Colab
     14 # kernel doesn't install its driver via APT, and as a result the ICD is missing.
     15 # (https://github.com/NVIDIA/libglvnd/blob/master/src/EGL/icd_enumeration.md)

File /opt/hostedtoolcache/Python/3.10.22/x64/lib/python3.10/subprocess.py:503, in run(input, capture_output, timeout, check, *popenargs, **kwargs)
    500     kwargs['stdout'] = PIPE
    501     kwargs['stderr'] = PIPE
--> 503 with Popen(*popenargs, **kwargs) as process:
    504     try:
    505         stdout, stderr = process.communicate(input, timeout=timeout)

File /opt/hostedtoolcache/Python/3.10.22/x64/lib/python3.10/subprocess.py:971, in Popen.__init__(self, args, bufsize, executable, stdin, stdout, stderr, preexec_fn, close_fds, shell, cwd, env, universal_newlines, startupinfo, creationflags, restore_signals, start_new_session, pass_fds, user, group, extra_groups, encoding, errors, text, umask, pipesize)
    967         if self.text_mode:
    968             self.stderr = io.TextIOWrapper(self.stderr,
    969                     encoding=encoding, errors=errors)
--> 971     self._execute_child(args, executable, preexec_fn, close_fds,
    972                         pass_fds, cwd, env,
    973                         startupinfo, creationflags, shell,
    974                         p2cread, p2cwrite,
    975                         c2pread, c2pwrite,
    976                         errread, errwrite,
    977                         restore_signals,
    978                         gid, gids, uid, umask,
    979                         start_new_session)
    980 except:
    981     # Cleanup if the child failed starting.
    982     for f in filter(None, (self.stdin, self.stdout, self.stderr)):

File /opt/hostedtoolcache/Python/3.10.22/x64/lib/python3.10/subprocess.py:1863, in Popen._execute_child(self, args, executable, preexec_fn, close_fds, pass_fds, cwd, env, startupinfo, creationflags, shell, p2cread, p2cwrite, c2pread, c2pwrite, errread, errwrite, restore_signals, gid, gids, uid, umask, start_new_session)
   1861     if errno_num != 0:
   1862         err_msg = os.strerror(errno_num)
-> 1863     raise child_exception_type(errno_num, err_msg, err_filename)
   1864 raise child_exception_type(err_msg)

FileNotFoundError: [Errno 2] No such file or directory: 'nvidia-smi'

IF USING KAGGLE (recommended):

Uncomment the cell below and run it.

Installing Dependencies (Kaggle GPU case, uncomment if you want to use this one)

Source

IF RUNNING LOCALLY

Uncomment the relevant lines of code depending on your OS.

Installing Dependencies (CPU case, comment if you want to use GPU one)

Source

Imports and Utility Functions

Importing Libraries

Source

Utility code for displaying videos

Source

In this notebook we will explore the major components essential for this project.

  • Understanding the DeepMind Control Suite Swimmer Agent: We will begin by exploring the swimmer agent provided by the DeepMind Control Suite. This section includes a detailed exploration of the agent’s API, task customization capabilities, and how to adapt the environment to fit our experimental needs.

  • Training Models Using Various Reinforcement Learning Algorithms: Next, we move on to learn how can we train models for the agents we created. We will be using Tonic_RL library to train our model. We will first train a standard MLP model using the Proximal Policy Optimization (PPO) algorithm.

  • Training the NCAP model: Finally we will define the NCAP model from Neural Circuit Architectural Priors for Embodied Control paper. We will train it using PPO and compare it against the MLP model we trained before.


Section 1: Exploring the DeepMind Swimmer

1.1 Create a basic swim task for the swimmer environment

First, we’ll initialize a basic swimmer agent consisting of 6 links. Each agent requires a defined task and its corresponding reward function. In this instance, we’ve designed a swim forward task that involves the agent swimming forward in any direction.

The environment is flexible, allowing for modifications to introduce additional tasks such as “swim only in the x-direction” or “move towards a ball.”

1.2 Vizualizing an agent that takes random actions in the environment

Let’s visualize the environment by executing a sequence of random actions on a swimmer agent. This involves applying random actions over a series of steps and compiling the rendered frames into a video to visualize the agent’s behavior.

/tmp/ipykernel_7666/4073379236.py:65: MatplotlibDeprecationWarning: Auto-close()ing of figures upon backend switching is deprecated since 3.8 and will be removed two minor releases later.  To suppress this warning, explicitly call plt.close('all') first.
  matplotlib.use(orig_backend)  # Switch back to the original backend.
Loading...

1.3 Swimmer Agent API

The observation space consists of 25 total dimensions, combining joint positions and body velocities, while the action space involves 5 dimensions representing normalized joint forces.

Observation Space: 4k - 1 total (k = 6 →\rightarrow 23)

  • k - 1: joint positions qi∈[−π,π]q_i \in [-\pi, \pi] (joints)

  • 3k: link linear velocities vxi,vyi∈Rvx_i, vy_i \in \mathbb{R} and rotational velocity wzi∈Rwz_i \in \mathbb{R} (body_velocities)

OrderedDict([('joints', Array(shape=(5,), dtype=dtype('float64'), name='joints')), ('body_velocities', Array(shape=(18,), dtype=dtype('float64'), name='body_velocities'))])

Action Space: k - 1 total (k = 6 →\rightarrow 5)

  • k - 1: joint normalized force q¨i∈[−1,1]\ddot{q}_i \in [-1, 1]

BoundedArray(shape=(5,), dtype=dtype('float64'), name=None, minimum=[-1. -1. -1. -1. -1.], maximum=[1. 1. 1. 1. 1.])

1.4 Example of simple modification to the agent

Let’s make a new swimmer agent with 12 links instead of 6, introducing complexity. Additionally, we have the flexibility to adjust various other parameters.

/tmp/ipykernel_7666/4073379236.py:65: MatplotlibDeprecationWarning: Auto-close()ing of figures upon backend switching is deprecated since 3.8 and will be removed two minor releases later.  To suppress this warning, explicitly call plt.close('all') first.
  matplotlib.use(orig_backend)  # Switch back to the original backend.
Loading...

We can visualize this longer agent using our previously defined test_dm_control function.

❓

Using the API provided by Deepmind we can create any kind of changes to the agent and the environment.

Try to make the following changes to make yourself more familiar with the swimmer.

  • Adding a target (like a ball) to this environment at some x distance away from the agent.

  • Increasing the viscosity of the environment.

Have a look at the following links to see what kind of assets you will need to modify to make these changes.


Section 2: Training models on the swim task

To train the agents we defined in the previous section, we will utilize standard reinforcement learning (RL) algorithms. For the purposes of this tutorial, we will employ the tonic_rl library, which provides a robust framework for training RL agents. Throughout most of this project, you will primarily be modifying the environment or the model architecture. Therefore, I suggest treating these algorithms as a “black box” for now. Simply put, you input an untrained model, and the algorithm processes and returns a well-trained model. This approach allows us to focus on the impact of different architectures and environmental settings without delving deeply into the algorithmic complexities at this stage.

Download and install tonic library for training agents

Source

Section 2.1 Defining the train function

First we defined a general training function to train any agent on any given environment with a variety of available algorithms. Given below are some of the parameter definitions of the function. You’ll likely want to adjust these parameters to customize the training process for an agent in a specific environment using your chosen algorithm from the tonic library:

  • Header: Python code required to run before training begins, primarily for importing essential libraries or modules.

  • Agent: The agent that will undergo training; refer to section 3.2 and 4.2 for definitions of MLP and NCAP respectively.

  • Environment: The training environment for the agent. Ensure it is registered with the DeepMind Control Suite as detailed in section 2.

  • Name: The experiment’s name, which will be utilized for log and model saving purposes.

  • Trainer: The trainer instance selected for use. It allows the configuration of the training steps, model saving frequency, and other training-related parameters.

Gym has been unmaintained since 2022 and does not support NumPy 2.0 amongst other critical functionality.
Please upgrade to Gymnasium, the maintained drop-in replacement of Gym, or contact the authors of your software and request that they upgrade.
Users of this version of Gym should be able to simply replace 'import gym' with 'import gymnasium as gym' in the vast majority of cases.
See the migration guide at https://gymnasium.farama.org/introduction/migration_guide/ for additional information.

Section 2.2 Training MLP model on swim task

Now we are going to define a function for creating an actor-critic model suitable for Proximal Policy Optimization (PPO) using a Multi-Layer Perceptron (MLP) architecture.

Next we call the train function which initiates the training process for the provided agent using the Tonic library. It specifies the components necessary for training, including the model, environment, and training parameters:

Agent: A Proximal Policy Optimization (PPO) agent with a custom Multi-Layer Perceptron (MLP) model architecture, configured with 256 units in each of two layers for both the actor and the critic.

Environment: The training environment is set to “swimmer-swim” from the Control Suite, a benchmark suite for continuous control tasks.

Name: The experiment is named ‘mlp_256’, which is useful for identifying logs and saved models associated with this training run.

Trainer: Specifies the training configuration, including the total number of steps (5e5) and the frequency of saving the model (1e5 steps).

Note: The model will checkpoint every ‘save_steps’ amount of training steps*

⏳

The model can take some time to train so feel free to skip the training for now. We have provided the pretrained model for you to play with. Move on to the next section to vizualize a agent with the pretrained model.

Uncomment the cell below if you want to perform the training.

/opt/hostedtoolcache/Python/3.10.22/x64/lib/python3.10/site-packages/gym/spaces/box.py:127: UserWarning: WARN: Box bound precision lowered by casting to float32
  logger.warn(f"Box bound precision lowered by casting to {self.dtype}")
Config file saved to data/local/experiments/tonic/swimmer-swim/mlp_256/config.yaml
          Time left:  epoch 0:01:01  total 0:25:35          
          Time left:  epoch 0:00:13  total 0:05:49          
          Time left:  epoch 0:00:13  total 0:05:52          
          Time left:  epoch 0:00:13  total 0:05:47          
          Time left:  epoch 0:00:12  total 0:05:43          
          Time left:  epoch 0:00:12  total 0:05:40          
          Time left:  epoch 0:00:12  total 0:05:38          
          Time left:  epoch 0:00:12  total 0:05:39          
          Time left:  epoch 0:00:11  total 0:05:37          
          Time left:  epoch 0:00:11  total 0:05:37          
          Time left:  epoch 0:00:11  total 0:05:36          
          Time left:  epoch 0:00:11  total 0:05:36          
          Time left:  epoch 0:00:10  total 0:05:36          
          Time left:  epoch 0:00:20  total 0:11:04          
          Time left:  epoch 0:00:19  total 0:10:40          
          Time left:  epoch 0:00:18  total 0:10:19          
          Time left:  epoch 0:00:17  total 0:10:01          
          Time left:  epoch 0:00:16  total 0:09:45          
          Time left:  epoch 0:00:16  total 0:09:31          
          Time left:  epoch 0:00:15  total 0:09:18          
          Time left:  epoch 0:00:14  total 0:09:07          
          Time left:  epoch 0:00:14  total 0:08:56          
          Time left:  epoch 0:00:13  total 0:08:47          
          Time left:  epoch 0:00:12  total 0:08:38          
          Time left:  epoch 0:00:12  total 0:08:30          
          Time left:  epoch 0:00:14  total 0:09:50          
          Time left:  epoch 0:00:13  total 0:09:40          
          Time left:  epoch 0:00:12  total 0:09:30          
          Time left:  epoch 0:00:12  total 0:09:21          
          Time left:  epoch 0:00:11  total 0:09:13          
          Time left:  epoch 0:00:11  total 0:09:05          
          Time left:  epoch 0:00:10  total 0:08:58          
          Time left:  epoch 0:00:10  total 0:08:52          
          Time left:  epoch 0:00:09  total 0:08:45          
          Time left:  epoch 0:00:09  total 0:08:39          
          Time left:  epoch 0:00:08  total 0:08:34          
          Time left:  epoch 0:00:08  total 0:08:28          
          Time left:  epoch 0:00:08  total 0:09:21          
          Time left:  epoch 0:00:08  total 0:09:15          
          Time left:  epoch 0:00:07  total 0:09:09          
          Time left:  epoch 0:00:07  total 0:09:03          
          Time left:  epoch 0:00:07  total 0:08:57          
          Time left:  epoch 0:00:06  total 0:08:52          
          Time left:  epoch 0:00:06  total 0:08:47          
          Time left:  epoch 0:00:05  total 0:08:42          
          Time left:  epoch 0:00:05  total 0:08:38          
          Time left:  epoch 0:00:04  total 0:08:33          
          Time left:  epoch 0:00:04  total 0:08:29          
          Time left:  epoch 0:00:04  total 0:08:25          
          Time left:  epoch 0:00:03  total 0:08:21          
          Time left:  epoch 0:00:03  total 0:09:00          
          Time left:  epoch 0:00:03  total 0:08:55          
          Time left:  epoch 0:00:02  total 0:08:51          
          Time left:  epoch 0:00:02  total 0:08:47          
          Time left:  epoch 0:00:02  total 0:08:43          
          Time left:  epoch 0:00:01  total 0:08:39          
          Time left:  epoch 0:00:01  total 0:08:35          
          Time left:  epoch 0:00:01  total 0:08:31          
          Time left:  epoch 0:00:00  total 0:08:28          
          Time left:  epoch 0:00:00  total 0:08:24          
          Time left:  epoch 0:00:00  total 0:08:21          

actor                                                       
  clip fraction                                        0.134
  entropy                                               1.05
  iterations                                            23.2
  kl                                                    0.01
  loss                                               -0.0156
  std                                                  0.694
  stop                                                0.0323
critic                                                      
  iterations                                              80
  loss                                                  2.47
  v                                                     4.62
test                                                        
  action                                                    
    max                                                 2.95
    mean                                             -0.0298
    min                                                -2.68
    size                                               5,000
    std                                                0.717
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  232
    mean                                                 200
    min                                                  172
    size                                                   5
    std                                                 19.3
train                                                       
  action                                                    
    max                                                 2.88
    mean                                             -0.0393
    min                                                -3.37
    size                                              20,000
    std                                                0.704
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  215
    mean                                                 131
    min                                                 79.1
    size                                                  20
    std                                                 41.5
  episodes                                                20
  epoch seconds                                         23.7
  epoch steps                                          2e+04
  epochs                                                   1
  seconds                                               23.7
  steps                                                2e+04
  steps per second                                       845
  worker steps                                         2e+04

Logging data to data/local/experiments/tonic/swimmer-swim/mlp_256/log.csv
          Time left:  epoch 0:00:23  total 0:09:29          
          Time left:  epoch 0:00:23  total 0:09:24          
          Time left:  epoch 0:00:24  total 0:09:55          
          Time left:  epoch 0:00:23  total 0:09:50          
          Time left:  epoch 0:00:22  total 0:09:45          
          Time left:  epoch 0:00:22  total 0:09:41          
          Time left:  epoch 0:00:21  total 0:09:37          
          Time left:  epoch 0:00:21  total 0:09:32          
          Time left:  epoch 0:00:20  total 0:09:28          
          Time left:  epoch 0:00:20  total 0:09:24          
          Time left:  epoch 0:00:19  total 0:09:21          
          Time left:  epoch 0:00:19  total 0:09:17          
          Time left:  epoch 0:00:18  total 0:09:13          
          Time left:  epoch 0:00:18  total 0:09:09          
          Time left:  epoch 0:00:18  total 0:09:35          
          Time left:  epoch 0:00:18  total 0:09:31          
          Time left:  epoch 0:00:17  total 0:09:28          
          Time left:  epoch 0:00:17  total 0:09:24          
          Time left:  epoch 0:00:16  total 0:09:21          
          Time left:  epoch 0:00:16  total 0:09:17          
          Time left:  epoch 0:00:15  total 0:09:14          
          Time left:  epoch 0:00:15  total 0:09:10          
          Time left:  epoch 0:00:14  total 0:09:07          
          Time left:  epoch 0:00:14  total 0:09:04          
          Time left:  epoch 0:00:13  total 0:09:01          
          Time left:  epoch 0:00:13  total 0:08:58          
          Time left:  epoch 0:00:12  total 0:08:55          
          Time left:  epoch 0:00:13  total 0:09:19          
          Time left:  epoch 0:00:12  total 0:09:16          
          Time left:  epoch 0:00:12  total 0:09:13          
          Time left:  epoch 0:00:11  total 0:09:10          
          Time left:  epoch 0:00:11  total 0:09:07          
          Time left:  epoch 0:00:10  total 0:09:04          
          Time left:  epoch 0:00:10  total 0:09:01          
          Time left:  epoch 0:00:09  total 0:08:59          
          Time left:  epoch 0:00:09  total 0:08:56          
          Time left:  epoch 0:00:09  total 0:08:53          
          Time left:  epoch 0:00:08  total 0:08:51          
          Time left:  epoch 0:00:08  total 0:08:48          
          Time left:  epoch 0:00:08  total 0:09:07          
          Time left:  epoch 0:00:07  total 0:09:04          
          Time left:  epoch 0:00:07  total 0:09:02          
          Time left:  epoch 0:00:06  total 0:08:59          
          Time left:  epoch 0:00:06  total 0:08:56          
          Time left:  epoch 0:00:06  total 0:08:54          
          Time left:  epoch 0:00:05  total 0:08:51          
          Time left:  epoch 0:00:05  total 0:08:49          
          Time left:  epoch 0:00:04  total 0:08:47          
          Time left:  epoch 0:00:04  total 0:08:44          
          Time left:  epoch 0:00:04  total 0:08:42          
          Time left:  epoch 0:00:03  total 0:08:40          
          Time left:  epoch 0:00:03  total 0:08:56          
          Time left:  epoch 0:00:03  total 0:08:54          
          Time left:  epoch 0:00:02  total 0:08:51          
          Time left:  epoch 0:00:02  total 0:08:49          
          Time left:  epoch 0:00:01  total 0:08:47          
          Time left:  epoch 0:00:01  total 0:08:45          
          Time left:  epoch 0:00:01  total 0:08:42          
          Time left:  epoch 0:00:00  total 0:08:40          
          Time left:  epoch 0:00:00  total 0:08:38          
          Time left:  epoch 0:00:00  total 0:08:36          

actor                                                       
  clip fraction                                       0.0921
  entropy                                               1.05
  iterations                                             4.2
  kl                                                 0.00738
  loss                                              -0.00643
  std                                                  0.693
  stop                                                 0.238
critic                                                      
  iterations                                              80
  loss                                                  2.83
  v                                                     19.7
test                                                        
  action                                                    
    max                                                 3.31
    mean                                           -0.000308
    min                                                -3.31
    size                                               5,000
    std                                                0.816
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  435
    mean                                                 423
    min                                                  408
    size                                                   5
    std                                                 9.48
train                                                       
  action                                                    
    max                                                 3.61
    mean                                             -0.0114
    min                                                -3.19
    size                                              20,000
    std                                                0.769
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  427
    mean                                                 330
    min                                                  211
    size                                                  20
    std                                                 70.5
  episodes                                                40
  epoch seconds                                           24
  epoch steps                                          2e+04
  epochs                                                   2
  seconds                                               47.7
  steps                                                4e+04
  steps per second                                       834
  worker steps                                         4e+04

          Time left:  epoch 0:00:23  total 0:09:09          
          Time left:  epoch 0:00:23  total 0:09:06          
          Time left:  epoch 0:00:22  total 0:09:04          
          Time left:  epoch 0:00:23  total 0:09:34          
          Time left:  epoch 0:00:23  total 0:09:31          
          Time left:  epoch 0:00:22  total 0:09:28          
          Time left:  epoch 0:00:22  total 0:09:26          
          Time left:  epoch 0:00:21  total 0:09:24          
          Time left:  epoch 0:00:21  total 0:09:21          
          Time left:  epoch 0:00:20  total 0:09:19          
          Time left:  epoch 0:00:20  total 0:09:16          
          Time left:  epoch 0:00:19  total 0:09:14          
          Time left:  epoch 0:00:19  total 0:09:12          
          Time left:  epoch 0:00:18  total 0:09:10          
          Time left:  epoch 0:00:18  total 0:09:07          
          Time left:  epoch 0:00:17  total 0:09:05          
          Time left:  epoch 0:00:18  total 0:09:18          
          Time left:  epoch 0:00:17  total 0:09:15          
          Time left:  epoch 0:00:17  total 0:09:13          
          Time left:  epoch 0:00:16  total 0:09:11          
          Time left:  epoch 0:00:16  total 0:09:09          
          Time left:  epoch 0:00:15  total 0:09:07          
          Time left:  epoch 0:00:15  total 0:09:05          
          Time left:  epoch 0:00:14  total 0:09:03          
          Time left:  epoch 0:00:14  total 0:09:01          
          Time left:  epoch 0:00:13  total 0:08:58          
          Time left:  epoch 0:00:13  total 0:08:57          
          Time left:  epoch 0:00:13  total 0:08:55          
          Time left:  epoch 0:00:12  total 0:09:07          
          Time left:  epoch 0:00:12  total 0:09:04          
          Time left:  epoch 0:00:12  total 0:09:02          
          Time left:  epoch 0:00:11  total 0:09:00          
          Time left:  epoch 0:00:11  total 0:08:59          
          Time left:  epoch 0:00:10  total 0:08:57          
          Time left:  epoch 0:00:10  total 0:08:55          
          Time left:  epoch 0:00:09  total 0:08:53          
          Time left:  epoch 0:00:09  total 0:08:51          
          Time left:  epoch 0:00:09  total 0:08:49          
          Time left:  epoch 0:00:08  total 0:08:47          
          Time left:  epoch 0:00:08  total 0:08:46          
          Time left:  epoch 0:00:08  total 0:08:57          
          Time left:  epoch 0:00:07  total 0:08:55          
          Time left:  epoch 0:00:07  total 0:08:53          
          Time left:  epoch 0:00:06  total 0:08:51          
          Time left:  epoch 0:00:06  total 0:08:49          
          Time left:  epoch 0:00:05  total 0:08:48          
          Time left:  epoch 0:00:05  total 0:08:46          
          Time left:  epoch 0:00:05  total 0:08:44          
          Time left:  epoch 0:00:04  total 0:08:42          
          Time left:  epoch 0:00:04  total 0:08:41          
          Time left:  epoch 0:00:03  total 0:08:39          
          Time left:  epoch 0:00:03  total 0:08:37          
          Time left:  epoch 0:00:03  total 0:08:36          
          Time left:  epoch 0:00:02  total 0:08:46          
          Time left:  epoch 0:00:02  total 0:08:44          
          Time left:  epoch 0:00:01  total 0:08:42          
          Time left:  epoch 0:00:01  total 0:08:41          
          Time left:  epoch 0:00:01  total 0:08:39          
          Time left:  epoch 0:00:00  total 0:08:37          
          Time left:  epoch 0:00:00  total 0:08:36          
          Time left:  epoch 0:00:00  total 0:08:34          

actor                                                       
  clip fraction                                        0.158
  entropy                                               1.04
  iterations                                            19.6
  kl                                                 0.00946
  loss                                               -0.0177
  std                                                  0.687
  stop                                                0.0408
critic                                                      
  iterations                                              80
  loss                                                  2.75
  v                                                     39.3
test                                                        
  action                                                    
    max                                                  3.5
    mean                                             0.00382
    min                                                -3.29
    size                                               5,000
    std                                                0.886
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  619
    mean                                                 599
    min                                                  585
    size                                                   5
    std                                                   12
train                                                       
  action                                                    
    max                                                 3.23
    mean                                             -0.0038
    min                                                -3.41
    size                                              20,000
    std                                                0.849
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  605
    mean                                                 523
    min                                                  437
    size                                                  20
    std                                                 51.5
  episodes                                                60
  epoch seconds                                         25.2
  epoch steps                                          2e+04
  epochs                                                   3
  seconds                                               72.9
  steps                                                6e+04
  steps per second                                       794
  worker steps                                         6e+04

          Time left:  epoch 0:00:24  total 0:08:55          
          Time left:  epoch 0:00:23  total 0:08:53          
          Time left:  epoch 0:00:23  total 0:08:51          
          Time left:  epoch 0:00:22  total 0:08:50          
          Time left:  epoch 0:00:22  total 0:08:48          
          Time left:  epoch 0:00:22  total 0:08:57          
          Time left:  epoch 0:00:22  total 0:08:56          
          Time left:  epoch 0:00:21  total 0:08:54          
          Time left:  epoch 0:00:21  total 0:08:52          
          Time left:  epoch 0:00:20  total 0:08:51          
          Time left:  epoch 0:00:20  total 0:08:49          
          Time left:  epoch 0:00:19  total 0:08:47          
          Time left:  epoch 0:00:19  total 0:08:46          
          Time left:  epoch 0:00:18  total 0:08:44          
          Time left:  epoch 0:00:18  total 0:08:42          
          Time left:  epoch 0:00:17  total 0:08:41          
          Time left:  epoch 0:00:17  total 0:08:39          
          Time left:  epoch 0:00:17  total 0:08:48          
          Time left:  epoch 0:00:16  total 0:08:46          
          Time left:  epoch 0:00:16  total 0:08:45          
          Time left:  epoch 0:00:16  total 0:08:43          
          Time left:  epoch 0:00:15  total 0:08:42          
          Time left:  epoch 0:00:15  total 0:08:40          
          Time left:  epoch 0:00:14  total 0:08:38          
          Time left:  epoch 0:00:14  total 0:08:37          
          Time left:  epoch 0:00:13  total 0:08:35          
          Time left:  epoch 0:00:13  total 0:08:34          
          Time left:  epoch 0:00:13  total 0:08:32          
          Time left:  epoch 0:00:12  total 0:08:32          
          Time left:  epoch 0:00:12  total 0:08:40          
          Time left:  epoch 0:00:12  total 0:08:38          
          Time left:  epoch 0:00:11  total 0:08:37          
          Time left:  epoch 0:00:11  total 0:08:35          
          Time left:  epoch 0:00:10  total 0:08:34          
          Time left:  epoch 0:00:10  total 0:08:32          
          Time left:  epoch 0:00:09  total 0:08:31          
          Time left:  epoch 0:00:09  total 0:08:30          
          Time left:  epoch 0:00:09  total 0:08:28          
          Time left:  epoch 0:00:08  total 0:08:27          
          Time left:  epoch 0:00:08  total 0:08:25          
          Time left:  epoch 0:00:07  total 0:08:24          
          Time left:  epoch 0:00:07  total 0:08:23          
          Time left:  epoch 0:00:07  total 0:08:30          
          Time left:  epoch 0:00:06  total 0:08:29          
          Time left:  epoch 0:00:06  total 0:08:27          
          Time left:  epoch 0:00:05  total 0:08:26          
          Time left:  epoch 0:00:05  total 0:08:24          
          Time left:  epoch 0:00:05  total 0:08:23          
          Time left:  epoch 0:00:04  total 0:08:22          
          Time left:  epoch 0:00:04  total 0:08:20          
          Time left:  epoch 0:00:03  total 0:08:19          
          Time left:  epoch 0:00:03  total 0:08:18          
          Time left:  epoch 0:00:03  total 0:08:16          
          Time left:  epoch 0:00:02  total 0:08:15          
          Time left:  epoch 0:00:02  total 0:08:22          
          Time left:  epoch 0:00:01  total 0:08:21          
          Time left:  epoch 0:00:01  total 0:08:20          
          Time left:  epoch 0:00:01  total 0:08:18          
          Time left:  epoch 0:00:00  total 0:08:17          
          Time left:  epoch 0:00:00  total 0:08:16          
          Time left:  epoch 0:00:00  total 0:08:14          

actor                                                       
  clip fraction                                        0.101
  entropy                                               1.03
  iterations                                             5.6
  kl                                                 0.00751
  loss                                              -0.00515
  std                                                  0.681
  stop                                                 0.179
critic                                                      
  iterations                                              80
  loss                                                  2.48
  v                                                     56.4
test                                                        
  action                                                    
    max                                                 3.32
    mean                                             -0.0209
    min                                                -3.46
    size                                               5,000
    std                                                0.941
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  715
    mean                                                 697
    min                                                  671
    size                                                   5
    std                                                 14.7
train                                                       
  action                                                    
    max                                                 3.83
    mean                                             -0.0113
    min                                                -3.32
    size                                              20,000
    std                                                0.921
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  717
    mean                                                 657
    min                                                  596
    size                                                  20
    std                                                 32.2
  episodes                                                80
  epoch seconds                                           24
  epoch steps                                          2e+04
  epochs                                                   4
  seconds                                                 97
  steps                                                8e+04
  steps per second                                       833
  worker steps                                         8e+04

          Time left:  epoch 0:00:24  total 0:08:29          
          Time left:  epoch 0:00:23  total 0:08:28          
          Time left:  epoch 0:00:23  total 0:08:26          
          Time left:  epoch 0:00:22  total 0:08:25          
          Time left:  epoch 0:00:22  total 0:08:24          
          Time left:  epoch 0:00:22  total 0:08:22          
          Time left:  epoch 0:00:21  total 0:08:29          
          Time left:  epoch 0:00:21  total 0:08:28          
          Time left:  epoch 0:00:21  total 0:08:26          
          Time left:  epoch 0:00:20  total 0:08:25          
          Time left:  epoch 0:00:20  total 0:08:24          
          Time left:  epoch 0:00:19  total 0:08:22          
          Time left:  epoch 0:00:19  total 0:08:21          
          Time left:  epoch 0:00:18  total 0:08:20          
          Time left:  epoch 0:00:18  total 0:08:18          
          Time left:  epoch 0:00:17  total 0:08:17          
          Time left:  epoch 0:00:17  total 0:08:16          
          Time left:  epoch 0:00:17  total 0:08:15          
          Time left:  epoch 0:00:16  total 0:08:13          
          Time left:  epoch 0:00:16  total 0:08:19          
          Time left:  epoch 0:00:16  total 0:08:18          
          Time left:  epoch 0:00:15  total 0:08:17          
          Time left:  epoch 0:00:15  total 0:08:16          
          Time left:  epoch 0:00:14  total 0:08:14          
          Time left:  epoch 0:00:14  total 0:08:13          
          Time left:  epoch 0:00:13  total 0:08:12          
          Time left:  epoch 0:00:13  total 0:08:11          
          Time left:  epoch 0:00:13  total 0:08:09          
          Time left:  epoch 0:00:12  total 0:08:08          
          Time left:  epoch 0:00:12  total 0:08:07          
          Time left:  epoch 0:00:11  total 0:08:06          
          Time left:  epoch 0:00:11  total 0:08:12          
          Time left:  epoch 0:00:11  total 0:08:11          
          Time left:  epoch 0:00:10  total 0:08:10          
          Time left:  epoch 0:00:10  total 0:08:09          
          Time left:  epoch 0:00:09  total 0:08:07          
          Time left:  epoch 0:00:09  total 0:08:06          
          Time left:  epoch 0:00:09  total 0:08:05          
          Time left:  epoch 0:00:08  total 0:08:04          
          Time left:  epoch 0:00:08  total 0:08:03          
          Time left:  epoch 0:00:07  total 0:08:02          
          Time left:  epoch 0:00:07  total 0:08:01          
          Time left:  epoch 0:00:07  total 0:07:59          
          Time left:  epoch 0:00:06  total 0:08:05          
          Time left:  epoch 0:00:06  total 0:08:04          
          Time left:  epoch 0:00:05  total 0:08:03          
          Time left:  epoch 0:00:05  total 0:08:02          
          Time left:  epoch 0:00:05  total 0:08:01          
          Time left:  epoch 0:00:04  total 0:08:00          
          Time left:  epoch 0:00:04  total 0:07:59          
          Time left:  epoch 0:00:03  total 0:07:58          
          Time left:  epoch 0:00:03  total 0:07:56          
          Time left:  epoch 0:00:03  total 0:07:55          
          Time left:  epoch 0:00:02  total 0:07:54          
          Time left:  epoch 0:00:02  total 0:07:53          
          Time left:  epoch 0:00:02  total 0:08:04          
          Time left:  epoch 0:00:01  total 0:08:03          
          Time left:  epoch 0:00:01  total 0:08:02          
          Time left:  epoch 0:00:00  total 0:08:01          
          Time left:  epoch 0:00:00  total 0:08:00          
          Time left:  epoch 0:00:00  total 0:07:59          

actor                                                       
  clip fraction                                        0.101
  entropy                                               1.02
  iterations                                            22.6
  kl                                                 0.00724
  loss                                               -0.0148
  std                                                  0.672
  stop                                                0.0354
critic                                                      
  iterations                                              80
  loss                                                  2.44
  v                                                     67.6
test                                                        
  action                                                    
    max                                                 3.21
    mean                                            -0.00641
    min                                                 -3.7
    size                                               5,000
    std                                                    1
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  789
    mean                                                 776
    min                                                  765
    size                                                   5
    std                                                 10.3
train                                                       
  action                                                    
    max                                                  3.5
    mean                                             -0.0194
    min                                                -3.46
    size                                              20,000
    std                                                0.974
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  773
    mean                                                 728
    min                                                  664
    size                                                  20
    std                                                 32.1
  episodes                                               100
  epoch seconds                                         25.5
  epoch steps                                          2e+04
  epochs                                                   5
  seconds                                                123
  steps                                                1e+05
  steps per second                                       784
  worker steps                                         1e+05


Saving weights to data/local/experiments/tonic/swimmer-swim/mlp_256/checkpoints/step_100000.pt
          Time left:  epoch 0:00:24  total 0:08:10          
          Time left:  epoch 0:00:24  total 0:08:09          
          Time left:  epoch 0:00:23  total 0:08:08          
          Time left:  epoch 0:00:23  total 0:08:07          
          Time left:  epoch 0:00:22  total 0:08:05          
          Time left:  epoch 0:00:22  total 0:08:04          
          Time left:  epoch 0:00:21  total 0:08:03          
          Time left:  epoch 0:00:21  total 0:08:02          
          Time left:  epoch 0:00:21  total 0:08:13          
          Time left:  epoch 0:00:21  total 0:08:11          
          Time left:  epoch 0:00:20  total 0:08:10          
          Time left:  epoch 0:00:20  total 0:08:09          
          Time left:  epoch 0:00:19  total 0:08:08          
          Time left:  epoch 0:00:19  total 0:08:07          
          Time left:  epoch 0:00:18  total 0:08:06          
          Time left:  epoch 0:00:18  total 0:08:05          
          Time left:  epoch 0:00:17  total 0:08:03          
          Time left:  epoch 0:00:17  total 0:08:02          
          Time left:  epoch 0:00:17  total 0:08:01          
          Time left:  epoch 0:00:16  total 0:08:00          
          Time left:  epoch 0:00:16  total 0:08:10          
          Time left:  epoch 0:00:16  total 0:08:09          
          Time left:  epoch 0:00:15  total 0:08:08          
          Time left:  epoch 0:00:15  total 0:08:07          
          Time left:  epoch 0:00:14  total 0:08:06          
          Time left:  epoch 0:00:14  total 0:08:05          
          Time left:  epoch 0:00:14  total 0:08:03          
          Time left:  epoch 0:00:13  total 0:08:02          
          Time left:  epoch 0:00:13  total 0:08:01          
          Time left:  epoch 0:00:12  total 0:08:00          
          Time left:  epoch 0:00:12  total 0:07:59          
          Time left:  epoch 0:00:11  total 0:07:58          
          Time left:  epoch 0:00:11  total 0:08:02          
          Time left:  epoch 0:00:11  total 0:08:01          
          Time left:  epoch 0:00:10  total 0:08:00          
          Time left:  epoch 0:00:10  total 0:07:59          
          Time left:  epoch 0:00:09  total 0:07:58          
          Time left:  epoch 0:00:09  total 0:07:57          
          Time left:  epoch 0:00:09  total 0:07:56          
          Time left:  epoch 0:00:08  total 0:07:55          
          Time left:  epoch 0:00:08  total 0:07:54          
          Time left:  epoch 0:00:07  total 0:07:53          
          Time left:  epoch 0:00:07  total 0:07:52          
          Time left:  epoch 0:00:06  total 0:07:51          
          Time left:  epoch 0:00:06  total 0:07:50          
          Time left:  epoch 0:00:06  total 0:07:59          
          Time left:  epoch 0:00:05  total 0:07:58          
          Time left:  epoch 0:00:05  total 0:07:57          
          Time left:  epoch 0:00:04  total 0:07:56          
          Time left:  epoch 0:00:04  total 0:07:55          
          Time left:  epoch 0:00:04  total 0:07:54          
          Time left:  epoch 0:00:03  total 0:07:53          
          Time left:  epoch 0:00:03  total 0:07:52          
          Time left:  epoch 0:00:02  total 0:07:51          
          Time left:  epoch 0:00:02  total 0:07:49          
          Time left:  epoch 0:00:02  total 0:07:48          
          Time left:  epoch 0:00:01  total 0:07:47          
          Time left:  epoch 0:00:01  total 0:07:55          
          Time left:  epoch 0:00:00  total 0:07:54          
          Time left:  epoch 0:00:00  total 0:07:53          
          Time left:  epoch 0:00:00  total 0:07:52          

actor                                                       
  clip fraction                                        0.118
  entropy                                              0.987
  iterations                                            62.6
  kl                                                 0.00974
  loss                                               -0.0167
  std                                                  0.649
  stop                                               0.00639
critic                                                      
  iterations                                              80
  loss                                                  1.19
  v                                                     76.5
test                                                        
  action                                                    
    max                                                 3.24
    mean                                             -0.0153
    min                                                -3.12
    size                                               5,000
    std                                                 1.03
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  851
    mean                                                 836
    min                                                  813
    size                                                   5
    std                                                 13.9
train                                                       
  action                                                    
    max                                                 3.56
    mean                                            -0.00581
    min                                                -3.69
    size                                              20,000
    std                                                 1.01
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  836
    mean                                                 804
    min                                                  769
    size                                                  20
    std                                                 16.4
  episodes                                               120
  epoch seconds                                         29.3
  epoch steps                                          2e+04
  epochs                                                   6
  seconds                                                152
  steps                                              1.2e+05
  steps per second                                       683
  worker steps                                       1.2e+05

          Time left:  epoch 0:00:25  total 0:08:01          
          Time left:  epoch 0:00:24  total 0:08:00          
          Time left:  epoch 0:00:24  total 0:07:59          
          Time left:  epoch 0:00:23  total 0:07:58          
          Time left:  epoch 0:00:23  total 0:07:57          
          Time left:  epoch 0:00:23  total 0:07:56          
          Time left:  epoch 0:00:22  total 0:07:55          
          Time left:  epoch 0:00:22  total 0:07:54          
          Time left:  epoch 0:00:21  total 0:07:53          
          Time left:  epoch 0:00:21  total 0:08:01          
          Time left:  epoch 0:00:21  total 0:08:00          
          Time left:  epoch 0:00:20  total 0:07:59          
          Time left:  epoch 0:00:20  total 0:07:58          
          Time left:  epoch 0:00:19  total 0:07:57          
          Time left:  epoch 0:00:19  total 0:07:56          
          Time left:  epoch 0:00:19  total 0:07:55          
          Time left:  epoch 0:00:18  total 0:07:54          
          Time left:  epoch 0:00:18  total 0:07:53          
          Time left:  epoch 0:00:17  total 0:07:51          
          Time left:  epoch 0:00:17  total 0:07:50          
          Time left:  epoch 0:00:16  total 0:07:49          
          Time left:  epoch 0:00:16  total 0:07:53          
          Time left:  epoch 0:00:16  total 0:07:52          
          Time left:  epoch 0:00:15  total 0:07:51          
          Time left:  epoch 0:00:15  total 0:07:50          
          Time left:  epoch 0:00:14  total 0:07:49          
          Time left:  epoch 0:00:14  total 0:07:48          
          Time left:  epoch 0:00:13  total 0:07:47          
          Time left:  epoch 0:00:13  total 0:07:46          
          Time left:  epoch 0:00:12  total 0:07:45          
          Time left:  epoch 0:00:12  total 0:07:44          
          Time left:  epoch 0:00:12  total 0:07:43          
          Time left:  epoch 0:00:11  total 0:07:42          
          Time left:  epoch 0:00:11  total 0:07:41          
          Time left:  epoch 0:00:11  total 0:07:48          
          Time left:  epoch 0:00:10  total 0:07:47          
          Time left:  epoch 0:00:10  total 0:07:46          
          Time left:  epoch 0:00:09  total 0:07:45          
          Time left:  epoch 0:00:09  total 0:07:44          
          Time left:  epoch 0:00:08  total 0:07:43          
          Time left:  epoch 0:00:08  total 0:07:42          
          Time left:  epoch 0:00:07  total 0:07:41          
          Time left:  epoch 0:00:07  total 0:07:40          
          Time left:  epoch 0:00:07  total 0:07:39          
          Time left:  epoch 0:00:06  total 0:07:38          
          Time left:  epoch 0:00:06  total 0:07:38          
          Time left:  epoch 0:00:05  total 0:07:44          
          Time left:  epoch 0:00:05  total 0:07:43          
          Time left:  epoch 0:00:05  total 0:07:42          
          Time left:  epoch 0:00:04  total 0:07:41          
          Time left:  epoch 0:00:04  total 0:07:40          
          Time left:  epoch 0:00:03  total 0:07:39          
          Time left:  epoch 0:00:03  total 0:07:38          
          Time left:  epoch 0:00:02  total 0:07:38          
          Time left:  epoch 0:00:02  total 0:07:37          
          Time left:  epoch 0:00:02  total 0:07:36          
          Time left:  epoch 0:00:01  total 0:07:35          
          Time left:  epoch 0:00:01  total 0:07:34          
          Time left:  epoch 0:00:00  total 0:07:40          
          Time left:  epoch 0:00:00  total 0:07:39          
          Time left:  epoch 0:00:00  total 0:07:39          

actor                                                       
  clip fraction                                        0.111
  entropy                                              0.925
  iterations                                              66
  kl                                                  0.0102
  loss                                               -0.0158
  std                                                   0.61
  stop                                               0.00303
critic                                                      
  iterations                                              80
  loss                                                 0.642
  v                                                     83.6
test                                                        
  action                                                    
    max                                                 3.33
    mean                                            -0.00222
    min                                                -3.05
    size                                               5,000
    std                                                 1.02
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  894
    mean                                                 878
    min                                                  862
    size                                                   5
    std                                                 10.2
train                                                       
  action                                                    
    max                                                 3.85
    mean                                            0.000537
    min                                                -3.78
    size                                              20,000
    std                                                 1.03
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  879
    mean                                                 856
    min                                                  822
    size                                                  20
    std                                                 14.7
  episodes                                               140
  epoch seconds                                         29.2
  epoch steps                                          2e+04
  epochs                                                   7
  seconds                                                181
  steps                                              1.4e+05
  steps per second                                       684
  worker steps                                       1.4e+05

          Time left:  epoch 0:00:25  total 0:07:46          
          Time left:  epoch 0:00:25  total 0:07:45          
          Time left:  epoch 0:00:24  total 0:07:44          
          Time left:  epoch 0:00:24  total 0:07:43          
          Time left:  epoch 0:00:24  total 0:07:42          
          Time left:  epoch 0:00:23  total 0:07:41          
          Time left:  epoch 0:00:23  total 0:07:40          
          Time left:  epoch 0:00:22  total 0:07:39          
          Time left:  epoch 0:00:22  total 0:07:38          
          Time left:  epoch 0:00:21  total 0:07:37          
          Time left:  epoch 0:00:21  total 0:07:36          
          Time left:  epoch 0:00:21  total 0:07:42          
          Time left:  epoch 0:00:20  total 0:07:41          
          Time left:  epoch 0:00:20  total 0:07:40          
          Time left:  epoch 0:00:19  total 0:07:39          
          Time left:  epoch 0:00:19  total 0:07:39          
          Time left:  epoch 0:00:18  total 0:07:38          
          Time left:  epoch 0:00:18  total 0:07:37          
          Time left:  epoch 0:00:18  total 0:07:36          
          Time left:  epoch 0:00:17  total 0:07:35          
          Time left:  epoch 0:00:17  total 0:07:34          
          Time left:  epoch 0:00:16  total 0:07:33          
          Time left:  epoch 0:00:16  total 0:07:32          
          Time left:  epoch 0:00:16  total 0:07:38          
          Time left:  epoch 0:00:15  total 0:07:37          
          Time left:  epoch 0:00:15  total 0:07:36          
          Time left:  epoch 0:00:14  total 0:07:35          
          Time left:  epoch 0:00:14  total 0:07:34          
          Time left:  epoch 0:00:13  total 0:07:33          
          Time left:  epoch 0:00:13  total 0:07:32          
          Time left:  epoch 0:00:12  total 0:07:31          
          Time left:  epoch 0:00:12  total 0:07:30          
          Time left:  epoch 0:00:12  total 0:07:29          
          Time left:  epoch 0:00:11  total 0:07:29          
          Time left:  epoch 0:00:11  total 0:07:28          
          Time left:  epoch 0:00:10  total 0:07:31          
          Time left:  epoch 0:00:10  total 0:07:30          
          Time left:  epoch 0:00:09  total 0:07:29          
          Time left:  epoch 0:00:09  total 0:07:28          
          Time left:  epoch 0:00:09  total 0:07:27          
          Time left:  epoch 0:00:08  total 0:07:26          
          Time left:  epoch 0:00:08  total 0:07:26          
          Time left:  epoch 0:00:07  total 0:07:25          
          Time left:  epoch 0:00:07  total 0:07:24          
          Time left:  epoch 0:00:06  total 0:07:23          
          Time left:  epoch 0:00:06  total 0:07:22          
          Time left:  epoch 0:00:05  total 0:07:21          
          Time left:  epoch 0:00:05  total 0:07:26          
          Time left:  epoch 0:00:05  total 0:07:26          
          Time left:  epoch 0:00:04  total 0:07:25          
          Time left:  epoch 0:00:04  total 0:07:24          
          Time left:  epoch 0:00:03  total 0:07:23          
          Time left:  epoch 0:00:03  total 0:07:22          
          Time left:  epoch 0:00:03  total 0:07:21          
          Time left:  epoch 0:00:02  total 0:07:20          
          Time left:  epoch 0:00:02  total 0:07:19          
          Time left:  epoch 0:00:01  total 0:07:18          
          Time left:  epoch 0:00:01  total 0:07:18          
          Time left:  epoch 0:00:00  total 0:07:17          
          Time left:  epoch 0:00:00  total 0:07:16          
          Time left:  epoch 0:00:00  total 0:07:21          

actor                                                       
  clip fraction                                        0.104
  entropy                                              0.842
  iterations                                              69
  kl                                                 0.00932
  loss                                                -0.016
  std                                                  0.562
  stop                                                0.0029
critic                                                      
  iterations                                              80
  loss                                                 0.345
  v                                                     88.2
test                                                        
  action                                                    
    max                                                 3.07
    mean                                            -0.00108
    min                                                -2.85
    size                                               5,000
    std                                                 1.02
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  917
    mean                                                 911
    min                                                  902
    size                                                   5
    std                                                 5.87
train                                                       
  action                                                    
    max                                                 3.44
    mean                                            -0.00147
    min                                                -3.26
    size                                              20,000
    std                                                 1.02
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  904
    mean                                                 890
    min                                                  872
    size                                                  20
    std                                                 10.3
  episodes                                               160
  epoch seconds                                         29.2
  epoch steps                                          2e+04
  epochs                                                   8
  seconds                                                210
  steps                                              1.6e+05
  steps per second                                       685
  worker steps                                       1.6e+05

          Time left:  epoch 0:00:26  total 0:07:27          
          Time left:  epoch 0:00:25  total 0:07:26          
          Time left:  epoch 0:00:25  total 0:07:25          
          Time left:  epoch 0:00:24  total 0:07:24          
          Time left:  epoch 0:00:24  total 0:07:23          
          Time left:  epoch 0:00:23  total 0:07:22          
          Time left:  epoch 0:00:23  total 0:07:21          
          Time left:  epoch 0:00:23  total 0:07:21          
          Time left:  epoch 0:00:22  total 0:07:20          
          Time left:  epoch 0:00:22  total 0:07:19          
          Time left:  epoch 0:00:21  total 0:07:18          
          Time left:  epoch 0:00:21  total 0:07:17          
          Time left:  epoch 0:00:21  total 0:07:24          
          Time left:  epoch 0:00:20  total 0:07:23          
          Time left:  epoch 0:00:20  total 0:07:23          
          Time left:  epoch 0:00:19  total 0:07:22          
          Time left:  epoch 0:00:19  total 0:07:21          
          Time left:  epoch 0:00:18  total 0:07:20          
          Time left:  epoch 0:00:18  total 0:07:19          
          Time left:  epoch 0:00:17  total 0:07:18          
          Time left:  epoch 0:00:17  total 0:07:17          
          Time left:  epoch 0:00:17  total 0:07:16          
          Time left:  epoch 0:00:16  total 0:07:16          
          Time left:  epoch 0:00:16  total 0:07:15          
          Time left:  epoch 0:00:15  total 0:07:21          
          Time left:  epoch 0:00:15  total 0:07:20          
          Time left:  epoch 0:00:15  total 0:07:19          
          Time left:  epoch 0:00:14  total 0:07:18          
          Time left:  epoch 0:00:14  total 0:07:17          
          Time left:  epoch 0:00:13  total 0:07:17          
          Time left:  epoch 0:00:13  total 0:07:16          
          Time left:  epoch 0:00:12  total 0:07:15          
          Time left:  epoch 0:00:12  total 0:07:14          
          Time left:  epoch 0:00:11  total 0:07:13          
          Time left:  epoch 0:00:11  total 0:07:12          
          Time left:  epoch 0:00:10  total 0:07:11          
          Time left:  epoch 0:00:10  total 0:07:11          
          Time left:  epoch 0:00:10  total 0:07:16          
          Time left:  epoch 0:00:09  total 0:07:16          
          Time left:  epoch 0:00:09  total 0:07:15          
          Time left:  epoch 0:00:08  total 0:07:14          
          Time left:  epoch 0:00:08  total 0:07:13          
          Time left:  epoch 0:00:07  total 0:07:12          
          Time left:  epoch 0:00:07  total 0:07:11          
          Time left:  epoch 0:00:07  total 0:07:10          
          Time left:  epoch 0:00:06  total 0:07:10          
          Time left:  epoch 0:00:06  total 0:07:09          
          Time left:  epoch 0:00:05  total 0:07:08          
          Time left:  epoch 0:00:05  total 0:07:07          
          Time left:  epoch 0:00:04  total 0:07:13          
          Time left:  epoch 0:00:04  total 0:07:12          
          Time left:  epoch 0:00:04  total 0:07:11          
          Time left:  epoch 0:00:03  total 0:07:10          
          Time left:  epoch 0:00:03  total 0:07:09          
          Time left:  epoch 0:00:02  total 0:07:08          
          Time left:  epoch 0:00:02  total 0:07:07          
          Time left:  epoch 0:00:01  total 0:07:07          
          Time left:  epoch 0:00:01  total 0:07:06          
          Time left:  epoch 0:00:00  total 0:07:05          
          Time left:  epoch 0:00:00  total 0:07:04          
          Time left:  epoch 0:00:00  total 0:07:03          

actor                                                       
  clip fraction                                        0.104
  entropy                                              0.772
  iterations                                              80
  kl                                                  0.0102
  loss                                               -0.0184
  std                                                  0.524
  stop                                                     0
critic                                                      
  iterations                                              80
  loss                                                  0.22
  v                                                     90.9
test                                                        
  action                                                    
    max                                                 3.15
    mean                                            -0.00248
    min                                                -2.79
    size                                               5,000
    std                                                 1.01
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  923
    mean                                                 918
    min                                                  908
    size                                                   5
    std                                                 5.92
train                                                       
  action                                                    
    max                                                 3.13
    mean                                            -0.00392
    min                                                   -3
    size                                              20,000
    std                                                 1.02
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  924
    mean                                                 911
    min                                                  876
    size                                                  20
    std                                                 10.6
  episodes                                               180
  epoch seconds                                         30.7
  epoch steps                                          2e+04
  epochs                                                   9
  seconds                                                241
  steps                                              1.8e+05
  steps per second                                       652
  worker steps                                       1.8e+05

          Time left:  epoch 0:00:26  total 0:07:08          
          Time left:  epoch 0:00:26  total 0:07:13          
          Time left:  epoch 0:00:26  total 0:07:13          
          Time left:  epoch 0:00:25  total 0:07:12          
          Time left:  epoch 0:00:25  total 0:07:11          
          Time left:  epoch 0:00:24  total 0:07:10          
          Time left:  epoch 0:00:24  total 0:07:09          
          Time left:  epoch 0:00:23  total 0:07:08          
          Time left:  epoch 0:00:23  total 0:07:07          
          Time left:  epoch 0:00:22  total 0:07:07          
          Time left:  epoch 0:00:22  total 0:07:06          
          Time left:  epoch 0:00:21  total 0:07:05          
          Time left:  epoch 0:00:21  total 0:07:04          
          Time left:  epoch 0:00:21  total 0:07:09          
          Time left:  epoch 0:00:20  total 0:07:08          
          Time left:  epoch 0:00:20  total 0:07:08          
          Time left:  epoch 0:00:19  total 0:07:07          
          Time left:  epoch 0:00:19  total 0:07:06          
          Time left:  epoch 0:00:18  total 0:07:05          
          Time left:  epoch 0:00:18  total 0:07:04          
          Time left:  epoch 0:00:18  total 0:07:03          
          Time left:  epoch 0:00:17  total 0:07:03          
          Time left:  epoch 0:00:17  total 0:07:02          
          Time left:  epoch 0:00:16  total 0:07:01          
          Time left:  epoch 0:00:16  total 0:07:00          
          Time left:  epoch 0:00:15  total 0:06:59          
          Time left:  epoch 0:00:15  total 0:07:02          
          Time left:  epoch 0:00:14  total 0:07:01          
          Time left:  epoch 0:00:14  total 0:07:00          
          Time left:  epoch 0:00:13  total 0:06:59          
          Time left:  epoch 0:00:13  total 0:06:59          
          Time left:  epoch 0:00:13  total 0:06:58          
          Time left:  epoch 0:00:12  total 0:06:57          
          Time left:  epoch 0:00:12  total 0:06:56          
          Time left:  epoch 0:00:11  total 0:06:56          
          Time left:  epoch 0:00:11  total 0:06:55          
          Time left:  epoch 0:00:10  total 0:06:54          
          Time left:  epoch 0:00:10  total 0:06:53          
          Time left:  epoch 0:00:10  total 0:06:59          
          Time left:  epoch 0:00:09  total 0:06:58          
          Time left:  epoch 0:00:09  total 0:06:57          
          Time left:  epoch 0:00:08  total 0:06:56          
          Time left:  epoch 0:00:08  total 0:06:56          
          Time left:  epoch 0:00:07  total 0:06:55          
          Time left:  epoch 0:00:07  total 0:06:54          
          Time left:  epoch 0:00:06  total 0:06:53          
          Time left:  epoch 0:00:06  total 0:06:53          
          Time left:  epoch 0:00:05  total 0:06:52          
          Time left:  epoch 0:00:05  total 0:06:51          
          Time left:  epoch 0:00:04  total 0:06:50          
          Time left:  epoch 0:00:04  total 0:06:55          
          Time left:  epoch 0:00:04  total 0:06:54          
          Time left:  epoch 0:00:03  total 0:06:54          
          Time left:  epoch 0:00:03  total 0:06:53          
          Time left:  epoch 0:00:02  total 0:06:52          
          Time left:  epoch 0:00:02  total 0:06:51          
          Time left:  epoch 0:00:01  total 0:06:50          
          Time left:  epoch 0:00:01  total 0:06:50          
          Time left:  epoch 0:00:00  total 0:06:49          
          Time left:  epoch 0:00:00  total 0:06:48          
          Time left:  epoch 0:00:00  total 0:06:47          

actor                                                       
  clip fraction                                       0.0943
  entropy                                              0.694
  iterations                                            65.8
  kl                                                 0.00977
  loss                                               -0.0162
  std                                                  0.485
  stop                                               0.00304
critic                                                      
  iterations                                              80
  loss                                                 0.155
  v                                                       93
test                                                        
  action                                                    
    max                                                 2.72
    mean                                            -0.00187
    min                                                -2.75
    size                                               5,000
    std                                                    1
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  945
    mean                                                 931
    min                                                  920
    size                                                   5
    std                                                 8.13
train                                                       
  action                                                    
    max                                                 2.92
    mean                                            -0.00363
    min                                                -3.19
    size                                              20,000
    std                                                 1.01
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  946
    mean                                                 926
    min                                                  895
    size                                                  20
    std                                                 13.6
  episodes                                               200
  epoch seconds                                         34.5
  epoch steps                                          2e+04
  epochs                                                  10
  seconds                                                276
  steps                                                2e+05
  steps per second                                       579
  worker steps                                         2e+05


Saving weights to data/local/experiments/tonic/swimmer-swim/mlp_256/checkpoints/step_200000.pt
          Time left:  epoch 0:00:27  total 0:06:53          
          Time left:  epoch 0:00:27  total 0:06:52          
          Time left:  epoch 0:00:26  total 0:06:52          
          Time left:  epoch 0:00:26  total 0:06:58          
          Time left:  epoch 0:00:26  total 0:06:57          
          Time left:  epoch 0:00:25  total 0:06:57          
          Time left:  epoch 0:00:25  total 0:06:56          
          Time left:  epoch 0:00:24  total 0:06:55          
          Time left:  epoch 0:00:24  total 0:06:55          
          Time left:  epoch 0:00:23  total 0:06:54          
          Time left:  epoch 0:00:23  total 0:06:53          
          Time left:  epoch 0:00:22  total 0:06:52          
          Time left:  epoch 0:00:22  total 0:06:52          
          Time left:  epoch 0:00:21  total 0:06:51          
          Time left:  epoch 0:00:21  total 0:06:50          
          Time left:  epoch 0:00:21  total 0:06:56          
          Time left:  epoch 0:00:20  total 0:06:56          
          Time left:  epoch 0:00:20  total 0:06:55          
          Time left:  epoch 0:00:19  total 0:06:54          
          Time left:  epoch 0:00:19  total 0:06:54          
          Time left:  epoch 0:00:18  total 0:06:53          
          Time left:  epoch 0:00:18  total 0:06:53          
          Time left:  epoch 0:00:17  total 0:06:52          
          Time left:  epoch 0:00:17  total 0:06:51          
          Time left:  epoch 0:00:16  total 0:06:51          
          Time left:  epoch 0:00:16  total 0:06:50          
          Time left:  epoch 0:00:15  total 0:06:50          
          Time left:  epoch 0:00:15  total 0:06:55          
          Time left:  epoch 0:00:15  total 0:06:54          
          Time left:  epoch 0:00:14  total 0:06:54          
          Time left:  epoch 0:00:14  total 0:06:53          
          Time left:  epoch 0:00:13  total 0:06:53          
          Time left:  epoch 0:00:13  total 0:06:52          
          Time left:  epoch 0:00:12  total 0:06:51          
          Time left:  epoch 0:00:12  total 0:06:50          
          Time left:  epoch 0:00:11  total 0:06:50          
          Time left:  epoch 0:00:11  total 0:06:49          
          Time left:  epoch 0:00:10  total 0:06:48          
          Time left:  epoch 0:00:10  total 0:06:48          
          Time left:  epoch 0:00:10  total 0:06:53          
          Time left:  epoch 0:00:09  total 0:06:53          
          Time left:  epoch 0:00:09  total 0:06:52          
          Time left:  epoch 0:00:08  total 0:06:51          
          Time left:  epoch 0:00:08  total 0:06:51          
          Time left:  epoch 0:00:07  total 0:06:50          
          Time left:  epoch 0:00:07  total 0:06:49          
          Time left:  epoch 0:00:06  total 0:06:49          
          Time left:  epoch 0:00:06  total 0:06:48          
          Time left:  epoch 0:00:05  total 0:06:48          
          Time left:  epoch 0:00:05  total 0:06:47          
          Time left:  epoch 0:00:04  total 0:06:46          
          Time left:  epoch 0:00:04  total 0:06:46          
          Time left:  epoch 0:00:03  total 0:06:54          
          Time left:  epoch 0:00:03  total 0:06:53          
          Time left:  epoch 0:00:02  total 0:06:52          
          Time left:  epoch 0:00:02  total 0:06:52          
          Time left:  epoch 0:00:01  total 0:06:51          
          Time left:  epoch 0:00:01  total 0:06:50          
          Time left:  epoch 0:00:00  total 0:06:50          
          Time left:  epoch 0:00:00  total 0:06:49          
          Time left:  epoch 0:00:00  total 0:06:49          

actor                                                       
  clip fraction                                        0.103
  entropy                                              0.618
  iterations                                            78.8
  kl                                                 0.00918
  loss                                               -0.0155
  std                                                   0.45
  stop                                               0.00254
critic                                                      
  iterations                                              80
  loss                                                 0.104
  v                                                     94.9
test                                                        
  action                                                    
    max                                                 2.82
    mean                                             -0.0032
    min                                                -2.77
    size                                               5,000
    std                                                0.977
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  962
    mean                                                 949
    min                                                  939
    size                                                   5
    std                                                 7.34
train                                                       
  action                                                    
    max                                                 3.02
    mean                                            -0.00176
    min                                                -2.98
    size                                              20,000
    std                                                 0.99
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  960
    mean                                                 941
    min                                                  907
    size                                                  20
    std                                                 10.4
  episodes                                               220
  epoch seconds                                         50.3
  epoch steps                                          2e+04
  epochs                                                  11
  seconds                                                326
  steps                                              2.2e+05
  steps per second                                       398
  worker steps                                       2.2e+05

          Time left:  epoch 0:00:29  total 0:06:55          
          Time left:  epoch 0:00:29  total 0:06:54          
          Time left:  epoch 0:00:28  total 0:06:53          
          Time left:  epoch 0:00:28  total 0:06:53          
          Time left:  epoch 0:00:27  total 0:06:57          
          Time left:  epoch 0:00:27  total 0:06:56          
          Time left:  epoch 0:00:26  total 0:06:55          
          Time left:  epoch 0:00:26  total 0:06:55          
          Time left:  epoch 0:00:25  total 0:06:54          
          Time left:  epoch 0:00:25  total 0:06:54          
          Time left:  epoch 0:00:24  total 0:06:53          
          Time left:  epoch 0:00:24  total 0:06:53          
          Time left:  epoch 0:00:23  total 0:06:52          
          Time left:  epoch 0:00:23  total 0:06:52          
          Time left:  epoch 0:00:22  total 0:06:51          
          Time left:  epoch 0:00:22  total 0:06:50          
          Time left:  epoch 0:00:22  total 0:06:57          
          Time left:  epoch 0:00:21  total 0:06:57          
          Time left:  epoch 0:00:21  total 0:06:56          
          Time left:  epoch 0:00:20  total 0:06:55          
          Time left:  epoch 0:00:20  total 0:06:55          
          Time left:  epoch 0:00:19  total 0:06:54          
          Time left:  epoch 0:00:19  total 0:06:54          
          Time left:  epoch 0:00:18  total 0:06:53          
          Time left:  epoch 0:00:18  total 0:06:52          
          Time left:  epoch 0:00:17  total 0:06:51          
          Time left:  epoch 0:00:17  total 0:06:51          
          Time left:  epoch 0:00:16  total 0:06:50          
          Time left:  epoch 0:00:16  total 0:06:49          
          Time left:  epoch 0:00:15  total 0:06:55          
          Time left:  epoch 0:00:15  total 0:06:54          
          Time left:  epoch 0:00:14  total 0:06:54          
          Time left:  epoch 0:00:14  total 0:06:53          
          Time left:  epoch 0:00:13  total 0:06:52          
          Time left:  epoch 0:00:13  total 0:06:52          
          Time left:  epoch 0:00:12  total 0:06:51          
          Time left:  epoch 0:00:12  total 0:06:50          
          Time left:  epoch 0:00:11  total 0:06:50          
          Time left:  epoch 0:00:11  total 0:06:49          
          Time left:  epoch 0:00:10  total 0:06:48          
          Time left:  epoch 0:00:10  total 0:06:48          
          Time left:  epoch 0:00:09  total 0:06:51          
          Time left:  epoch 0:00:09  total 0:06:50          
          Time left:  epoch 0:00:08  total 0:06:49          
          Time left:  epoch 0:00:08  total 0:06:49          
          Time left:  epoch 0:00:07  total 0:06:48          
          Time left:  epoch 0:00:07  total 0:06:48          
          Time left:  epoch 0:00:06  total 0:06:47          
          Time left:  epoch 0:00:06  total 0:06:46          
          Time left:  epoch 0:00:05  total 0:06:46          
          Time left:  epoch 0:00:05  total 0:06:45          
          Time left:  epoch 0:00:04  total 0:06:44          
          Time left:  epoch 0:00:04  total 0:06:44          
          Time left:  epoch 0:00:03  total 0:06:46          
          Time left:  epoch 0:00:03  total 0:06:46          
          Time left:  epoch 0:00:02  total 0:06:45          
          Time left:  epoch 0:00:02  total 0:06:44          
          Time left:  epoch 0:00:01  total 0:06:44          
          Time left:  epoch 0:00:01  total 0:06:43          
          Time left:  epoch 0:00:00  total 0:06:42          
          Time left:  epoch 0:00:00  total 0:06:42          

actor                                                       
  clip fraction                                       0.0968
  entropy                                              0.558
  iterations                                            38.6
  kl                                                  0.0103
  loss                                               -0.0151
  std                                                  0.423
  stop                                                0.0155
critic                                                      
  iterations                                              80
  loss                                                0.0596
  v                                                       96
test                                                        
  action                                                    
    max                                                 2.71
    mean                                            -0.00367
    min                                                -2.66
    size                                               5,000
    std                                                 0.97
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  961
    mean                                                 954
    min                                                  946
    size                                                   5
    std                                                 6.18
train                                                       
  action                                                    
    max                                                 2.94
    mean                                               0.001
    min                                                -2.76
    size                                              20,000
    std                                                0.977
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  958
    mean                                                 947
    min                                                  934
    size                                                  20
    std                                                 7.11
  episodes                                               240
  epoch seconds                                         49.5
  epoch steps                                          2e+04
  epochs                                                  12
  seconds                                                376
  steps                                              2.4e+05
  steps per second                                       404
  worker steps                                       2.4e+05

          Time left:  epoch 0:00:31  total 0:06:47          
          Time left:  epoch 0:00:30  total 0:06:46          
          Time left:  epoch 0:00:30  total 0:06:45          
          Time left:  epoch 0:00:29  total 0:06:44          
          Time left:  epoch 0:00:29  total 0:06:44          
          Time left:  epoch 0:00:29  total 0:06:48          
          Time left:  epoch 0:00:28  total 0:06:48          
          Time left:  epoch 0:00:27  total 0:06:47          
          Time left:  epoch 0:00:27  total 0:06:46          
          Time left:  epoch 0:00:26  total 0:06:46          
          Time left:  epoch 0:00:26  total 0:06:45          
          Time left:  epoch 0:00:25  total 0:06:44          
          Time left:  epoch 0:00:25  total 0:06:43          
          Time left:  epoch 0:00:24  total 0:06:43          
          Time left:  epoch 0:00:24  total 0:06:42          
          Time left:  epoch 0:00:23  total 0:06:41          
          Time left:  epoch 0:00:23  total 0:06:41          
          Time left:  epoch 0:00:22  total 0:06:40          
          Time left:  epoch 0:00:22  total 0:06:46          
          Time left:  epoch 0:00:21  total 0:06:45          
          Time left:  epoch 0:00:21  total 0:06:44          
          Time left:  epoch 0:00:20  total 0:06:43          
          Time left:  epoch 0:00:20  total 0:06:43          
          Time left:  epoch 0:00:19  total 0:06:42          
          Time left:  epoch 0:00:19  total 0:06:41          
          Time left:  epoch 0:00:18  total 0:06:41          
          Time left:  epoch 0:00:18  total 0:06:40          
          Time left:  epoch 0:00:17  total 0:06:39          
          Time left:  epoch 0:00:16  total 0:06:39          
          Time left:  epoch 0:00:16  total 0:06:38          
          Time left:  epoch 0:00:16  total 0:06:46          
          Time left:  epoch 0:00:15  total 0:06:45          
          Time left:  epoch 0:00:15  total 0:06:44          
          Time left:  epoch 0:00:14  total 0:06:44          
          Time left:  epoch 0:00:14  total 0:06:43          
          Time left:  epoch 0:00:13  total 0:06:42          
          Time left:  epoch 0:00:12  total 0:06:42          
          Time left:  epoch 0:00:12  total 0:06:41          
          Time left:  epoch 0:00:11  total 0:06:40          
          Time left:  epoch 0:00:11  total 0:06:40          
          Time left:  epoch 0:00:10  total 0:06:39          
          Time left:  epoch 0:00:10  total 0:06:38          
          Time left:  epoch 0:00:09  total 0:06:43          
          Time left:  epoch 0:00:09  total 0:06:43          
          Time left:  epoch 0:00:08  total 0:06:42          
          Time left:  epoch 0:00:08  total 0:06:41          
          Time left:  epoch 0:00:07  total 0:06:40          
          Time left:  epoch 0:00:07  total 0:06:40          
          Time left:  epoch 0:00:06  total 0:06:39          
          Time left:  epoch 0:00:06  total 0:06:38          
          Time left:  epoch 0:00:05  total 0:06:38          
          Time left:  epoch 0:00:04  total 0:06:37          
          Time left:  epoch 0:00:04  total 0:06:36          
          Time left:  epoch 0:00:03  total 0:06:35          
          Time left:  epoch 0:00:03  total 0:06:35          
          Time left:  epoch 0:00:02  total 0:06:39          
          Time left:  epoch 0:00:02  total 0:06:38          
          Time left:  epoch 0:00:01  total 0:06:37          
          Time left:  epoch 0:00:01  total 0:06:37          
          Time left:  epoch 0:00:00  total 0:06:36          
          Time left:  epoch 0:00:00  total 0:06:35          

actor                                                       
  clip fraction                                       0.0981
  entropy                                              0.499
  iterations                                            74.2
  kl                                                 0.00951
  loss                                               -0.0151
  std                                                  0.399
  stop                                                0.0027
critic                                                      
  iterations                                              80
  loss                                                0.0432
  v                                                     96.8
test                                                        
  action                                                    
    max                                                  2.5
    mean                                           -0.000466
    min                                                -2.49
    size                                               5,000
    std                                                0.958
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  960
    mean                                                 952
    min                                                  941
    size                                                   5
    std                                                 6.78
train                                                       
  action                                                    
    max                                                 2.74
    mean                                            -0.00133
    min                                                -2.64
    size                                              20,000
    std                                                0.968
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  968
    mean                                                 956
    min                                                  937
    size                                                  20
    std                                                  7.9
  episodes                                               260
  epoch seconds                                         57.7
  epoch steps                                          2e+04
  epochs                                                  13
  seconds                                                433
  steps                                              2.6e+05
  steps per second                                       347
  worker steps                                       2.6e+05

          Time left:  epoch 0:00:33  total 0:06:40          
          Time left:  epoch 0:00:32  total 0:06:39          
          Time left:  epoch 0:00:32  total 0:06:38          
          Time left:  epoch 0:00:31  total 0:06:38          
          Time left:  epoch 0:00:31  total 0:06:37          
          Time left:  epoch 0:00:30  total 0:06:36          
          Time left:  epoch 0:00:29  total 0:06:35          
          Time left:  epoch 0:00:29  total 0:06:39          
          Time left:  epoch 0:00:29  total 0:06:38          
          Time left:  epoch 0:00:28  total 0:06:38          
          Time left:  epoch 0:00:27  total 0:06:37          
          Time left:  epoch 0:00:27  total 0:06:36          
          Time left:  epoch 0:00:26  total 0:06:35          
          Time left:  epoch 0:00:26  total 0:06:34          
          Time left:  epoch 0:00:25  total 0:06:34          
          Time left:  epoch 0:00:25  total 0:06:33          
          Time left:  epoch 0:00:24  total 0:06:32          
          Time left:  epoch 0:00:23  total 0:06:31          
          Time left:  epoch 0:00:23  total 0:06:31          
          Time left:  epoch 0:00:22  total 0:06:33          
          Time left:  epoch 0:00:22  total 0:06:32          
          Time left:  epoch 0:00:21  total 0:06:31          
          Time left:  epoch 0:00:21  total 0:06:31          
          Time left:  epoch 0:00:20  total 0:06:30          
          Time left:  epoch 0:00:20  total 0:06:29          
          Time left:  epoch 0:00:19  total 0:06:29          
          Time left:  epoch 0:00:19  total 0:06:28          
          Time left:  epoch 0:00:18  total 0:06:27          
          Time left:  epoch 0:00:17  total 0:06:26          
          Time left:  epoch 0:00:17  total 0:06:26          
          Time left:  epoch 0:00:16  total 0:06:25          
          Time left:  epoch 0:00:16  total 0:06:24          
          Time left:  epoch 0:00:15  total 0:06:29          
          Time left:  epoch 0:00:15  total 0:06:28          
          Time left:  epoch 0:00:14  total 0:06:27          
          Time left:  epoch 0:00:14  total 0:06:26          
          Time left:  epoch 0:00:13  total 0:06:26          
          Time left:  epoch 0:00:12  total 0:06:25          
          Time left:  epoch 0:00:12  total 0:06:24          
          Time left:  epoch 0:00:11  total 0:06:24          
          Time left:  epoch 0:00:11  total 0:06:23          
          Time left:  epoch 0:00:10  total 0:06:22          
          Time left:  epoch 0:00:10  total 0:06:21          
          Time left:  epoch 0:00:09  total 0:06:21          
          Time left:  epoch 0:00:09  total 0:06:25          
          Time left:  epoch 0:00:08  total 0:06:25          
          Time left:  epoch 0:00:07  total 0:06:24          
          Time left:  epoch 0:00:07  total 0:06:23          
          Time left:  epoch 0:00:06  total 0:06:22          
          Time left:  epoch 0:00:06  total 0:06:22          
          Time left:  epoch 0:00:05  total 0:06:21          
          Time left:  epoch 0:00:05  total 0:06:20          
          Time left:  epoch 0:00:04  total 0:06:20          
          Time left:  epoch 0:00:03  total 0:06:19          
          Time left:  epoch 0:00:03  total 0:06:18          
          Time left:  epoch 0:00:02  total 0:06:17          
          Time left:  epoch 0:00:02  total 0:06:20          
          Time left:  epoch 0:00:01  total 0:06:19          
          Time left:  epoch 0:00:01  total 0:06:18          
          Time left:  epoch 0:00:00  total 0:06:18          
          Time left:  epoch 0:00:00  total 0:06:17          

actor                                                       
  clip fraction                                        0.101
  entropy                                              0.435
  iterations                                            45.8
  kl                                                  0.0109
  loss                                               -0.0156
  std                                                  0.374
  stop                                                0.0131
critic                                                      
  iterations                                              80
  loss                                                0.0446
  v                                                     97.4
test                                                        
  action                                                    
    max                                                  2.2
    mean                                            -0.00362
    min                                                -2.32
    size                                               5,000
    std                                                0.955
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  974
    mean                                                 963
    min                                                  951
    size                                                   5
    std                                                 7.56
train                                                       
  action                                                    
    max                                                 2.62
    mean                                            -0.00142
    min                                                -2.46
    size                                              20,000
    std                                                0.959
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  979
    mean                                                 960
    min                                                  944
    size                                                  20
    std                                                 8.81
  episodes                                               280
  epoch seconds                                         51.6
  epoch steps                                          2e+04
  epochs                                                  14
  seconds                                                485
  steps                                              2.8e+05
  steps per second                                       388
  worker steps                                       2.8e+05

          Time left:  epoch 0:00:34  total 0:06:21          
          Time left:  epoch 0:00:34  total 0:06:20          
          Time left:  epoch 0:00:33  total 0:06:19          
          Time left:  epoch 0:00:32  total 0:06:18          
          Time left:  epoch 0:00:32  total 0:06:18          
          Time left:  epoch 0:00:31  total 0:06:17          
          Time left:  epoch 0:00:31  total 0:06:16          
          Time left:  epoch 0:00:30  total 0:06:16          
          Time left:  epoch 0:00:30  total 0:06:18          
          Time left:  epoch 0:00:29  total 0:06:17          
          Time left:  epoch 0:00:28  total 0:06:16          
          Time left:  epoch 0:00:28  total 0:06:15          
          Time left:  epoch 0:00:27  total 0:06:15          
          Time left:  epoch 0:00:27  total 0:06:14          
          Time left:  epoch 0:00:26  total 0:06:13          
          Time left:  epoch 0:00:26  total 0:06:12          
          Time left:  epoch 0:00:25  total 0:06:12          
          Time left:  epoch 0:00:24  total 0:06:11          
          Time left:  epoch 0:00:24  total 0:06:10          
          Time left:  epoch 0:00:23  total 0:06:10          
          Time left:  epoch 0:00:23  total 0:06:09          
          Time left:  epoch 0:00:22  total 0:06:11          
          Time left:  epoch 0:00:22  total 0:06:10          
          Time left:  epoch 0:00:21  total 0:06:10          
          Time left:  epoch 0:00:20  total 0:06:09          
          Time left:  epoch 0:00:20  total 0:06:08          
          Time left:  epoch 0:00:19  total 0:06:07          
          Time left:  epoch 0:00:19  total 0:06:07          
          Time left:  epoch 0:00:18  total 0:06:06          
          Time left:  epoch 0:00:17  total 0:06:05          
          Time left:  epoch 0:00:17  total 0:06:04          
          Time left:  epoch 0:00:16  total 0:06:04          
          Time left:  epoch 0:00:16  total 0:06:03          
          Time left:  epoch 0:00:15  total 0:06:05          
          Time left:  epoch 0:00:15  total 0:06:04          
          Time left:  epoch 0:00:14  total 0:06:03          
          Time left:  epoch 0:00:13  total 0:06:03          
          Time left:  epoch 0:00:13  total 0:06:02          
          Time left:  epoch 0:00:12  total 0:06:01          
          Time left:  epoch 0:00:12  total 0:06:00          
          Time left:  epoch 0:00:11  total 0:06:00          
          Time left:  epoch 0:00:11  total 0:05:59          
          Time left:  epoch 0:00:10  total 0:05:58          
          Time left:  epoch 0:00:09  total 0:05:58          
          Time left:  epoch 0:00:09  total 0:05:57          
          Time left:  epoch 0:00:08  total 0:05:59          
          Time left:  epoch 0:00:08  total 0:05:58          
          Time left:  epoch 0:00:07  total 0:05:57          
          Time left:  epoch 0:00:07  total 0:05:57          
          Time left:  epoch 0:00:06  total 0:05:56          
          Time left:  epoch 0:00:05  total 0:05:55          
          Time left:  epoch 0:00:05  total 0:05:54          
          Time left:  epoch 0:00:04  total 0:05:54          
          Time left:  epoch 0:00:04  total 0:05:53          
          Time left:  epoch 0:00:03  total 0:05:52          
          Time left:  epoch 0:00:02  total 0:05:52          
          Time left:  epoch 0:00:02  total 0:05:51          
          Time left:  epoch 0:00:01  total 0:05:50          
          Time left:  epoch 0:00:01  total 0:05:53          
          Time left:  epoch 0:00:00  total 0:05:52          
          Time left:  epoch 0:00:00  total 0:05:51          

actor                                                       
  clip fraction                                        0.095
  entropy                                              0.408
  iterations                                             7.6
  kl                                                 0.00989
  loss                                              -0.00485
  std                                                  0.365
  stop                                                 0.132
critic                                                      
  iterations                                              80
  loss                                                0.0326
  v                                                     97.9
test                                                        
  action                                                    
    max                                                  2.5
    mean                                             0.00138
    min                                                -2.47
    size                                               5,000
    std                                                0.954
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  964
    mean                                                 962
    min                                                  960
    size                                                   5
    std                                                 1.41
train                                                       
  action                                                    
    max                                                 2.51
    mean                                             -0.0021
    min                                                -2.53
    size                                              20,000
    std                                                0.954
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  976
    mean                                                 962
    min                                                  950
    size                                                  20
    std                                                 7.18
  episodes                                               300
  epoch seconds                                         46.7
  epoch steps                                          2e+04
  epochs                                                  15
  seconds                                                532
  steps                                                3e+05
  steps per second                                       428
  worker steps                                         3e+05


Saving weights to data/local/experiments/tonic/swimmer-swim/mlp_256/checkpoints/step_300000.pt
          Time left:  epoch 0:00:35  total 0:05:54          
          Time left:  epoch 0:00:34  total 0:05:53          
          Time left:  epoch 0:00:34  total 0:05:53          
          Time left:  epoch 0:00:33  total 0:05:52          
          Time left:  epoch 0:00:33  total 0:05:51          
          Time left:  epoch 0:00:32  total 0:05:50          
          Time left:  epoch 0:00:31  total 0:05:50          
          Time left:  epoch 0:00:31  total 0:05:49          
          Time left:  epoch 0:00:30  total 0:05:48          
          Time left:  epoch 0:00:30  total 0:05:47          
          Time left:  epoch 0:00:29  total 0:05:49          
          Time left:  epoch 0:00:28  total 0:05:48          
          Time left:  epoch 0:00:28  total 0:05:47          
          Time left:  epoch 0:00:27  total 0:05:46          
          Time left:  epoch 0:00:27  total 0:05:46          
          Time left:  epoch 0:00:26  total 0:05:45          
          Time left:  epoch 0:00:25  total 0:05:44          
          Time left:  epoch 0:00:25  total 0:05:44          
          Time left:  epoch 0:00:24  total 0:05:43          
          Time left:  epoch 0:00:24  total 0:05:42          
          Time left:  epoch 0:00:23  total 0:05:41          
          Time left:  epoch 0:00:22  total 0:05:40          
          Time left:  epoch 0:00:22  total 0:05:42          
          Time left:  epoch 0:00:21  total 0:05:41          
          Time left:  epoch 0:00:21  total 0:05:40          
          Time left:  epoch 0:00:20  total 0:05:39          
          Time left:  epoch 0:00:20  total 0:05:39          
          Time left:  epoch 0:00:19  total 0:05:38          
          Time left:  epoch 0:00:18  total 0:05:37          
          Time left:  epoch 0:00:18  total 0:05:36          
          Time left:  epoch 0:00:17  total 0:05:35          
          Time left:  epoch 0:00:17  total 0:05:35          
          Time left:  epoch 0:00:16  total 0:05:34          
          Time left:  epoch 0:00:15  total 0:05:33          
          Time left:  epoch 0:00:15  total 0:05:36          
          Time left:  epoch 0:00:14  total 0:05:35          
          Time left:  epoch 0:00:14  total 0:05:35          
          Time left:  epoch 0:00:13  total 0:05:34          
          Time left:  epoch 0:00:13  total 0:05:33          
          Time left:  epoch 0:00:12  total 0:05:32          
          Time left:  epoch 0:00:11  total 0:05:32          
          Time left:  epoch 0:00:11  total 0:05:31          
          Time left:  epoch 0:00:10  total 0:05:30          
          Time left:  epoch 0:00:10  total 0:05:30          
          Time left:  epoch 0:00:09  total 0:05:29          
          Time left:  epoch 0:00:08  total 0:05:28          
          Time left:  epoch 0:00:08  total 0:05:28          
          Time left:  epoch 0:00:07  total 0:05:31          
          Time left:  epoch 0:00:07  total 0:05:30          
          Time left:  epoch 0:00:06  total 0:05:29          
          Time left:  epoch 0:00:05  total 0:05:28          
          Time left:  epoch 0:00:05  total 0:05:28          
          Time left:  epoch 0:00:04  total 0:05:27          
          Time left:  epoch 0:00:04  total 0:05:26          
          Time left:  epoch 0:00:03  total 0:05:25          
          Time left:  epoch 0:00:02  total 0:05:25          
          Time left:  epoch 0:00:02  total 0:05:24          
          Time left:  epoch 0:00:01  total 0:05:23          
          Time left:  epoch 0:00:01  total 0:05:22          
          Time left:  epoch 0:00:00  total 0:05:24          
          Time left:  epoch 0:00:00  total 0:05:23          

actor                                                       
  clip fraction                                       0.0995
  entropy                                              0.387
  iterations                                            34.6
  kl                                                 0.00908
  loss                                               -0.0151
  std                                                  0.357
  stop                                                0.0173
critic                                                      
  iterations                                              80
  loss                                                0.0317
  v                                                     98.1
test                                                        
  action                                                    
    max                                                 2.27
    mean                                              0.0039
    min                                                -2.72
    size                                               5,000
    std                                                0.951
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  972
    mean                                                 966
    min                                                  957
    size                                                   5
    std                                                 5.37
train                                                       
  action                                                    
    max                                                 2.53
    mean                                             0.00257
    min                                                -2.71
    size                                              20,000
    std                                                0.955
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  982
    mean                                                 965
    min                                                  950
    size                                                  20
    std                                                 7.04
  episodes                                               320
  epoch seconds                                         48.4
  epoch steps                                          2e+04
  epochs                                                  16
  seconds                                                580
  steps                                              3.2e+05
  steps per second                                       414
  worker steps                                       3.2e+05

          Time left:  epoch 0:00:36  total 0:05:26          
          Time left:  epoch 0:00:35  total 0:05:25          
          Time left:  epoch 0:00:35  total 0:05:24          
          Time left:  epoch 0:00:34  total 0:05:24          
          Time left:  epoch 0:00:33  total 0:05:23          
          Time left:  epoch 0:00:33  total 0:05:22          
          Time left:  epoch 0:00:32  total 0:05:21          
          Time left:  epoch 0:00:31  total 0:05:21          
          Time left:  epoch 0:00:31  total 0:05:20          
          Time left:  epoch 0:00:30  total 0:05:19          
          Time left:  epoch 0:00:30  total 0:05:19          
          Time left:  epoch 0:00:29  total 0:05:20          
          Time left:  epoch 0:00:29  total 0:05:19          
          Time left:  epoch 0:00:28  total 0:05:18          
          Time left:  epoch 0:00:27  total 0:05:18          
          Time left:  epoch 0:00:27  total 0:05:17          
          Time left:  epoch 0:00:26  total 0:05:16          
          Time left:  epoch 0:00:25  total 0:05:15          
          Time left:  epoch 0:00:25  total 0:05:15          
          Time left:  epoch 0:00:24  total 0:05:14          
          Time left:  epoch 0:00:24  total 0:05:13          
          Time left:  epoch 0:00:23  total 0:05:13          
          Time left:  epoch 0:00:22  total 0:05:12          
          Time left:  epoch 0:00:22  total 0:05:11          
          Time left:  epoch 0:00:21  total 0:05:12          
          Time left:  epoch 0:00:21  total 0:05:11          
          Time left:  epoch 0:00:20  total 0:05:11          
          Time left:  epoch 0:00:19  total 0:05:10          
          Time left:  epoch 0:00:19  total 0:05:09          
          Time left:  epoch 0:00:18  total 0:05:08          
          Time left:  epoch 0:00:18  total 0:05:08          
          Time left:  epoch 0:00:17  total 0:05:07          
          Time left:  epoch 0:00:16  total 0:05:06          
          Time left:  epoch 0:00:16  total 0:05:05          
          Time left:  epoch 0:00:15  total 0:05:05          
          Time left:  epoch 0:00:15  total 0:05:04          
          Time left:  epoch 0:00:14  total 0:05:05          
          Time left:  epoch 0:00:13  total 0:05:04          
          Time left:  epoch 0:00:13  total 0:05:04          
          Time left:  epoch 0:00:12  total 0:05:03          
          Time left:  epoch 0:00:12  total 0:05:02          
          Time left:  epoch 0:00:11  total 0:05:01          
          Time left:  epoch 0:00:10  total 0:05:01          
          Time left:  epoch 0:00:10  total 0:05:00          
          Time left:  epoch 0:00:09  total 0:04:59          
          Time left:  epoch 0:00:09  total 0:04:58          
          Time left:  epoch 0:00:08  total 0:04:58          
          Time left:  epoch 0:00:07  total 0:04:57          
          Time left:  epoch 0:00:07  total 0:04:58          
          Time left:  epoch 0:00:06  total 0:04:57          
          Time left:  epoch 0:00:06  total 0:04:57          
          Time left:  epoch 0:00:05  total 0:04:56          
          Time left:  epoch 0:00:04  total 0:04:55          
          Time left:  epoch 0:00:04  total 0:04:55          
          Time left:  epoch 0:00:03  total 0:04:54          
          Time left:  epoch 0:00:03  total 0:04:53          
          Time left:  epoch 0:00:02  total 0:04:52          
          Time left:  epoch 0:00:01  total 0:04:52          
          Time left:  epoch 0:00:01  total 0:04:51          
          Time left:  epoch 0:00:00  total 0:04:50          
          Time left:  epoch 0:00:00  total 0:04:51          

actor                                                       
  clip fraction                                        0.108
  entropy                                              0.367
  iterations                                            10.6
  kl                                                  0.0103
  loss                                              -0.00655
  std                                                   0.35
  stop                                                0.0943
critic                                                      
  iterations                                              80
  loss                                                0.0314
  v                                                     98.3
test                                                        
  action                                                    
    max                                                 2.32
    mean                                             0.00173
    min                                                -2.56
    size                                               5,000
    std                                                0.951
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  972
    mean                                                 969
    min                                                  966
    size                                                   5
    std                                                 2.45
train                                                       
  action                                                    
    max                                                 2.49
    mean                                             0.00285
    min                                                -2.33
    size                                              20,000
    std                                                0.952
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  978
    mean                                                 965
    min                                                  944
    size                                                  20
    std                                                  8.7
  episodes                                               340
  epoch seconds                                         43.7
  epoch steps                                          2e+04
  epochs                                                  17
  seconds                                                624
  steps                                              3.4e+05
  steps per second                                       457
  worker steps                                       3.4e+05

          Time left:  epoch 0:00:36  total 0:04:53          
          Time left:  epoch 0:00:36  total 0:04:53          
          Time left:  epoch 0:00:35  total 0:04:52          
          Time left:  epoch 0:00:34  total 0:04:51          
          Time left:  epoch 0:00:34  total 0:04:50          
          Time left:  epoch 0:00:33  total 0:04:50          
          Time left:  epoch 0:00:32  total 0:04:49          
          Time left:  epoch 0:00:32  total 0:04:48          
          Time left:  epoch 0:00:31  total 0:04:48          
          Time left:  epoch 0:00:31  total 0:04:47          
          Time left:  epoch 0:00:30  total 0:04:46          
          Time left:  epoch 0:00:29  total 0:04:45          
          Time left:  epoch 0:00:29  total 0:04:45          
          Time left:  epoch 0:00:28  total 0:04:46          
          Time left:  epoch 0:00:28  total 0:04:45          
          Time left:  epoch 0:00:27  total 0:04:44          
          Time left:  epoch 0:00:26  total 0:04:44          
          Time left:  epoch 0:00:26  total 0:04:43          
          Time left:  epoch 0:00:25  total 0:04:42          
          Time left:  epoch 0:00:25  total 0:04:41          
          Time left:  epoch 0:00:24  total 0:04:41          
          Time left:  epoch 0:00:23  total 0:04:40          
          Time left:  epoch 0:00:23  total 0:04:39          
          Time left:  epoch 0:00:22  total 0:04:39          
          Time left:  epoch 0:00:21  total 0:04:38          
          Time left:  epoch 0:00:21  total 0:04:38          
          Time left:  epoch 0:00:20  total 0:04:38          
          Time left:  epoch 0:00:20  total 0:04:37          
          Time left:  epoch 0:00:19  total 0:04:36          
          Time left:  epoch 0:00:18  total 0:04:36          
          Time left:  epoch 0:00:18  total 0:04:35          
          Time left:  epoch 0:00:17  total 0:04:34          
          Time left:  epoch 0:00:17  total 0:04:33          
          Time left:  epoch 0:00:16  total 0:04:33          
          Time left:  epoch 0:00:15  total 0:04:32          
          Time left:  epoch 0:00:15  total 0:04:31          
          Time left:  epoch 0:00:14  total 0:04:31          
          Time left:  epoch 0:00:14  total 0:04:32          
          Time left:  epoch 0:00:13  total 0:04:31          
          Time left:  epoch 0:00:12  total 0:04:31          
          Time left:  epoch 0:00:12  total 0:04:30          
          Time left:  epoch 0:00:11  total 0:04:29          
          Time left:  epoch 0:00:11  total 0:04:28          
          Time left:  epoch 0:00:10  total 0:04:28          
          Time left:  epoch 0:00:09  total 0:04:27          
          Time left:  epoch 0:00:09  total 0:04:26          
          Time left:  epoch 0:00:08  total 0:04:25          
          Time left:  epoch 0:00:07  total 0:04:25          
          Time left:  epoch 0:00:07  total 0:04:24          
          Time left:  epoch 0:00:06  total 0:04:23          
          Time left:  epoch 0:00:06  total 0:04:24          
          Time left:  epoch 0:00:05  total 0:04:23          
          Time left:  epoch 0:00:04  total 0:04:23          
          Time left:  epoch 0:00:04  total 0:04:22          
          Time left:  epoch 0:00:03  total 0:04:21          
          Time left:  epoch 0:00:03  total 0:04:20          
          Time left:  epoch 0:00:02  total 0:04:20          
          Time left:  epoch 0:00:01  total 0:04:19          
          Time left:  epoch 0:00:01  total 0:04:18          
          Time left:  epoch 0:00:00  total 0:04:17          
          Time left:  epoch 0:00:00  total 0:04:17          

actor                                                       
  clip fraction                                        0.103
  entropy                                              0.349
  iterations                                            36.8
  kl                                                  0.0105
  loss                                               -0.0127
  std                                                  0.344
  stop                                                0.0204
critic                                                      
  iterations                                              80
  loss                                                0.0275
  v                                                     98.4
test                                                        
  action                                                    
    max                                                 2.26
    mean                                             0.00563
    min                                                -2.37
    size                                               5,000
    std                                                0.945
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  980
    mean                                                 968
    min                                                  962
    size                                                   5
    std                                                 6.55
train                                                       
  action                                                    
    max                                                 2.34
    mean                                             0.00134
    min                                                -2.57
    size                                              20,000
    std                                                 0.95
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  982
    mean                                                 968
    min                                                  956
    size                                                  20
    std                                                 7.05
  episodes                                               360
  epoch seconds                                         40.7
  epoch steps                                          2e+04
  epochs                                                  18
  seconds                                                665
  steps                                              3.6e+05
  steps per second                                       491
  worker steps                                       3.6e+05

          Time left:  epoch 0:00:36  total 0:04:18          
          Time left:  epoch 0:00:36  total 0:04:17          
          Time left:  epoch 0:00:35  total 0:04:18          
          Time left:  epoch 0:00:35  total 0:04:17          
          Time left:  epoch 0:00:34  total 0:04:16          
          Time left:  epoch 0:00:33  total 0:04:16          
          Time left:  epoch 0:00:33  total 0:04:15          
          Time left:  epoch 0:00:32  total 0:04:14          
          Time left:  epoch 0:00:32  total 0:04:14          
          Time left:  epoch 0:00:31  total 0:04:13          
          Time left:  epoch 0:00:30  total 0:04:12          
          Time left:  epoch 0:00:30  total 0:04:11          
          Time left:  epoch 0:00:29  total 0:04:11          
          Time left:  epoch 0:00:28  total 0:04:10          
          Time left:  epoch 0:00:28  total 0:04:10          
          Time left:  epoch 0:00:27  total 0:04:10          
          Time left:  epoch 0:00:27  total 0:04:09          
          Time left:  epoch 0:00:26  total 0:04:08          
          Time left:  epoch 0:00:25  total 0:04:07          
          Time left:  epoch 0:00:25  total 0:04:07          
          Time left:  epoch 0:00:24  total 0:04:06          
          Time left:  epoch 0:00:24  total 0:04:05          
          Time left:  epoch 0:00:23  total 0:04:05          
          Time left:  epoch 0:00:22  total 0:04:04          
          Time left:  epoch 0:00:22  total 0:04:03          
          Time left:  epoch 0:00:21  total 0:04:03          
          Time left:  epoch 0:00:21  total 0:04:03          
          Time left:  epoch 0:00:20  total 0:04:02          
          Time left:  epoch 0:00:19  total 0:04:02          
          Time left:  epoch 0:00:19  total 0:04:01          
          Time left:  epoch 0:00:18  total 0:04:00          
          Time left:  epoch 0:00:17  total 0:03:59          
          Time left:  epoch 0:00:17  total 0:03:59          
          Time left:  epoch 0:00:16  total 0:03:58          
          Time left:  epoch 0:00:16  total 0:03:57          
          Time left:  epoch 0:00:15  total 0:03:57          
          Time left:  epoch 0:00:14  total 0:03:56          
          Time left:  epoch 0:00:14  total 0:03:55          
          Time left:  epoch 0:00:13  total 0:03:55          
          Time left:  epoch 0:00:13  total 0:03:56          
          Time left:  epoch 0:00:12  total 0:03:55          
          Time left:  epoch 0:00:11  total 0:03:55          
          Time left:  epoch 0:00:11  total 0:03:54          
          Time left:  epoch 0:00:10  total 0:03:53          
          Time left:  epoch 0:00:09  total 0:03:53          
          Time left:  epoch 0:00:09  total 0:03:52          
          Time left:  epoch 0:00:08  total 0:03:51          
          Time left:  epoch 0:00:08  total 0:03:50          
          Time left:  epoch 0:00:07  total 0:03:50          
          Time left:  epoch 0:00:06  total 0:03:49          
          Time left:  epoch 0:00:06  total 0:03:48          
          Time left:  epoch 0:00:05  total 0:03:48          
          Time left:  epoch 0:00:04  total 0:03:48          
          Time left:  epoch 0:00:04  total 0:03:47          
          Time left:  epoch 0:00:03  total 0:03:46          
          Time left:  epoch 0:00:03  total 0:03:46          
          Time left:  epoch 0:00:02  total 0:03:45          
          Time left:  epoch 0:00:01  total 0:03:44          
          Time left:  epoch 0:00:01  total 0:03:43          
          Time left:  epoch 0:00:00  total 0:03:43          
          Time left:  epoch 0:00:00  total 0:03:42          

actor                                                       
  clip fraction                                       0.0936
  entropy                                              0.328
  iterations                                            17.4
  kl                                                  0.0107
  loss                                               -0.0115
  std                                                  0.337
  stop                                                0.0575
critic                                                      
  iterations                                              80
  loss                                                0.0227
  v                                                     98.6
test                                                        
  action                                                    
    max                                                 2.44
    mean                                            0.000677
    min                                                -2.14
    size                                               5,000
    std                                                0.946
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  978
    mean                                                 971
    min                                                  966
    size                                                   5
    std                                                 4.74
train                                                       
  action                                                    
    max                                                 2.43
    mean                                             0.00267
    min                                                -2.52
    size                                              20,000
    std                                                0.949
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  983
    mean                                                 969
    min                                                  956
    size                                                  20
    std                                                 7.36
  episodes                                               380
  epoch seconds                                         43.7
  epoch steps                                          2e+04
  epochs                                                  19
  seconds                                                709
  steps                                              3.8e+05
  steps per second                                       458
  worker steps                                       3.8e+05

          Time left:  epoch 0:00:37  total 0:03:43          
          Time left:  epoch 0:00:36  total 0:03:43          
          Time left:  epoch 0:00:36  total 0:03:42          
          Time left:  epoch 0:00:35  total 0:03:42          
          Time left:  epoch 0:00:34  total 0:03:41          
          Time left:  epoch 0:00:34  total 0:03:40          
          Time left:  epoch 0:00:33  total 0:03:40          
          Time left:  epoch 0:00:32  total 0:03:39          
          Time left:  epoch 0:00:32  total 0:03:38          
          Time left:  epoch 0:00:31  total 0:03:37          
          Time left:  epoch 0:00:31  total 0:03:37          
          Time left:  epoch 0:00:30  total 0:03:36          
          Time left:  epoch 0:00:29  total 0:03:35          
          Time left:  epoch 0:00:29  total 0:03:34          
          Time left:  epoch 0:00:28  total 0:03:34          
          Time left:  epoch 0:00:27  total 0:03:33          
          Time left:  epoch 0:00:27  total 0:03:33          
          Time left:  epoch 0:00:26  total 0:03:32          
          Time left:  epoch 0:00:26  total 0:03:31          
          Time left:  epoch 0:00:25  total 0:03:31          
          Time left:  epoch 0:00:24  total 0:03:30          
          Time left:  epoch 0:00:24  total 0:03:29          
          Time left:  epoch 0:00:23  total 0:03:28          
          Time left:  epoch 0:00:22  total 0:03:28          
          Time left:  epoch 0:00:22  total 0:03:27          
          Time left:  epoch 0:00:21  total 0:03:26          
          Time left:  epoch 0:00:20  total 0:03:25          
          Time left:  epoch 0:00:20  total 0:03:25          
          Time left:  epoch 0:00:19  total 0:03:24          
          Time left:  epoch 0:00:19  total 0:03:24          
          Time left:  epoch 0:00:18  total 0:03:23          
          Time left:  epoch 0:00:17  total 0:03:22          
          Time left:  epoch 0:00:17  total 0:03:22          
          Time left:  epoch 0:00:16  total 0:03:21          
          Time left:  epoch 0:00:15  total 0:03:20          
          Time left:  epoch 0:00:15  total 0:03:19          
          Time left:  epoch 0:00:14  total 0:03:19          
          Time left:  epoch 0:00:14  total 0:03:18          
          Time left:  epoch 0:00:13  total 0:03:17          
          Time left:  epoch 0:00:12  total 0:03:17          
          Time left:  epoch 0:00:12  total 0:03:16          
          Time left:  epoch 0:00:11  total 0:03:15          
          Time left:  epoch 0:00:11  total 0:03:15          
          Time left:  epoch 0:00:10  total 0:03:14          
          Time left:  epoch 0:00:09  total 0:03:13          
          Time left:  epoch 0:00:09  total 0:03:13          
          Time left:  epoch 0:00:08  total 0:03:12          
          Time left:  epoch 0:00:07  total 0:03:11          
          Time left:  epoch 0:00:07  total 0:03:10          
          Time left:  epoch 0:00:06  total 0:03:10          
          Time left:  epoch 0:00:06  total 0:03:09          
          Time left:  epoch 0:00:05  total 0:03:08          
          Time left:  epoch 0:00:04  total 0:03:08          
          Time left:  epoch 0:00:04  total 0:03:08          
          Time left:  epoch 0:00:03  total 0:03:07          
          Time left:  epoch 0:00:03  total 0:03:06          
          Time left:  epoch 0:00:02  total 0:03:06          
          Time left:  epoch 0:00:01  total 0:03:05          
          Time left:  epoch 0:00:01  total 0:03:04          
          Time left:  epoch 0:00:00  total 0:03:03          
          Time left:  epoch 0:00:00  total 0:03:03          

actor                                                       
  clip fraction                                       0.0915
  entropy                                              0.308
  iterations                                              23
  kl                                                 0.00848
  loss                                               -0.0121
  std                                                   0.33
  stop                                                0.0348
critic                                                      
  iterations                                              80
  loss                                                  0.02
  v                                                     98.7
test                                                        
  action                                                    
    max                                                 2.21
    mean                                             0.00319
    min                                                -2.19
    size                                               5,000
    std                                                0.949
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  978
    mean                                                 968
    min                                                  959
    size                                                   5
    std                                                 7.44
train                                                       
  action                                                    
    max                                                 2.32
    mean                                              0.0016
    min                                                -2.35
    size                                              20,000
    std                                                0.947
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  979
    mean                                                 972
    min                                                  951
    size                                                  20
    std                                                 6.46
  episodes                                               400
  epoch seconds                                         26.5
  epoch steps                                          2e+04
  epochs                                                  20
  seconds                                                735
  steps                                                4e+05
  steps per second                                       754
  worker steps                                         4e+05


Saving weights to data/local/experiments/tonic/swimmer-swim/mlp_256/checkpoints/step_400000.pt
          Time left:  epoch 0:00:36  total 0:03:03          
          Time left:  epoch 0:00:36  total 0:03:03          
          Time left:  epoch 0:00:35  total 0:03:02          
          Time left:  epoch 0:00:34  total 0:03:01          
          Time left:  epoch 0:00:34  total 0:03:01          
          Time left:  epoch 0:00:33  total 0:03:00          
          Time left:  epoch 0:00:33  total 0:03:00          
          Time left:  epoch 0:00:32  total 0:02:59          
          Time left:  epoch 0:00:31  total 0:02:58          
          Time left:  epoch 0:00:31  total 0:02:57          
          Time left:  epoch 0:00:30  total 0:02:57          
          Time left:  epoch 0:00:29  total 0:02:56          
          Time left:  epoch 0:00:29  total 0:02:55          
          Time left:  epoch 0:00:28  total 0:02:55          
          Time left:  epoch 0:00:28  total 0:02:54          
          Time left:  epoch 0:00:27  total 0:02:53          
          Time left:  epoch 0:00:26  total 0:02:52          
          Time left:  epoch 0:00:26  total 0:02:52          
          Time left:  epoch 0:00:25  total 0:02:51          
          Time left:  epoch 0:00:24  total 0:02:51          
          Time left:  epoch 0:00:24  total 0:02:50          
          Time left:  epoch 0:00:23  total 0:02:49          
          Time left:  epoch 0:00:23  total 0:02:49          
          Time left:  epoch 0:00:22  total 0:02:48          
          Time left:  epoch 0:00:21  total 0:02:47          
          Time left:  epoch 0:00:21  total 0:02:47          
          Time left:  epoch 0:00:20  total 0:02:46          
          Time left:  epoch 0:00:20  total 0:02:45          
          Time left:  epoch 0:00:19  total 0:02:44          
          Time left:  epoch 0:00:18  total 0:02:44          
          Time left:  epoch 0:00:18  total 0:02:43          
          Time left:  epoch 0:00:17  total 0:02:43          
          Time left:  epoch 0:00:16  total 0:02:42          
          Time left:  epoch 0:00:16  total 0:02:41          
          Time left:  epoch 0:00:15  total 0:02:41          
          Time left:  epoch 0:00:15  total 0:02:40          
          Time left:  epoch 0:00:14  total 0:02:39          
          Time left:  epoch 0:00:13  total 0:02:39          
          Time left:  epoch 0:00:13  total 0:02:38          
          Time left:  epoch 0:00:12  total 0:02:37          
          Time left:  epoch 0:00:12  total 0:02:37          
          Time left:  epoch 0:00:11  total 0:02:36          
          Time left:  epoch 0:00:10  total 0:02:35          
          Time left:  epoch 0:00:10  total 0:02:35          
          Time left:  epoch 0:00:09  total 0:02:34          
          Time left:  epoch 0:00:09  total 0:02:33          
          Time left:  epoch 0:00:08  total 0:02:33          
          Time left:  epoch 0:00:07  total 0:02:32          
          Time left:  epoch 0:00:07  total 0:02:31          
          Time left:  epoch 0:00:06  total 0:02:31          
          Time left:  epoch 0:00:06  total 0:02:30          
          Time left:  epoch 0:00:05  total 0:02:29          
          Time left:  epoch 0:00:04  total 0:02:29          
          Time left:  epoch 0:00:04  total 0:02:28          
          Time left:  epoch 0:00:03  total 0:02:28          
          Time left:  epoch 0:00:03  total 0:02:27          
          Time left:  epoch 0:00:02  total 0:02:26          
          Time left:  epoch 0:00:01  total 0:02:26          
          Time left:  epoch 0:00:01  total 0:02:25          
          Time left:  epoch 0:00:00  total 0:02:24          
          Time left:  epoch 0:00:00  total 0:02:24          

actor                                                       
  clip fraction                                          0.1
  entropy                                              0.292
  iterations                                               4
  kl                                                 0.00956
  loss                                              -0.00366
  std                                                  0.325
  stop                                                  0.25
critic                                                      
  iterations                                              80
  loss                                                0.0267
  v                                                     98.8
test                                                        
  action                                                    
    max                                                 2.25
    mean                                            -0.00395
    min                                                -2.31
    size                                               5,000
    std                                                0.943
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  980
    mean                                                 978
    min                                                  973
    size                                                   5
    std                                                 2.49
train                                                       
  action                                                    
    max                                                 2.38
    mean                                            0.000622
    min                                                -2.27
    size                                              20,000
    std                                                0.945
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  984
    mean                                                 973
    min                                                  951
    size                                                  20
    std                                                 8.42
  episodes                                               420
  epoch seconds                                         23.5
  epoch steps                                          2e+04
  epochs                                                  21
  seconds                                                759
  steps                                              4.2e+05
  steps per second                                       849
  worker steps                                       4.2e+05

          Time left:  epoch 0:00:36  total 0:02:24          
          Time left:  epoch 0:00:35  total 0:02:23          
          Time left:  epoch 0:00:34  total 0:02:23          
          Time left:  epoch 0:00:34  total 0:02:22          
          Time left:  epoch 0:00:33  total 0:02:21          
          Time left:  epoch 0:00:33  total 0:02:21          
          Time left:  epoch 0:00:32  total 0:02:20          
          Time left:  epoch 0:00:31  total 0:02:20          
          Time left:  epoch 0:00:31  total 0:02:19          
          Time left:  epoch 0:00:30  total 0:02:18          
          Time left:  epoch 0:00:30  total 0:02:18          
          Time left:  epoch 0:00:29  total 0:02:17          
          Time left:  epoch 0:00:28  total 0:02:16          
          Time left:  epoch 0:00:28  total 0:02:16          
          Time left:  epoch 0:00:27  total 0:02:15          
          Time left:  epoch 0:00:26  total 0:02:14          
          Time left:  epoch 0:00:26  total 0:02:14          
          Time left:  epoch 0:00:25  total 0:02:13          
          Time left:  epoch 0:00:25  total 0:02:13          
          Time left:  epoch 0:00:24  total 0:02:12          
          Time left:  epoch 0:00:23  total 0:02:11          
          Time left:  epoch 0:00:23  total 0:02:11          
          Time left:  epoch 0:00:22  total 0:02:10          
          Time left:  epoch 0:00:22  total 0:02:09          
          Time left:  epoch 0:00:21  total 0:02:09          
          Time left:  epoch 0:00:20  total 0:02:08          
          Time left:  epoch 0:00:20  total 0:02:07          
          Time left:  epoch 0:00:19  total 0:02:07          
          Time left:  epoch 0:00:19  total 0:02:06          
          Time left:  epoch 0:00:18  total 0:02:05          
          Time left:  epoch 0:00:17  total 0:02:05          
          Time left:  epoch 0:00:17  total 0:02:04          
          Time left:  epoch 0:00:16  total 0:02:04          
          Time left:  epoch 0:00:16  total 0:02:03          
          Time left:  epoch 0:00:15  total 0:02:02          
          Time left:  epoch 0:00:14  total 0:02:02          
          Time left:  epoch 0:00:14  total 0:02:01          
          Time left:  epoch 0:00:13  total 0:02:00          
          Time left:  epoch 0:00:13  total 0:02:00          
          Time left:  epoch 0:00:12  total 0:01:59          
          Time left:  epoch 0:00:11  total 0:01:58          
          Time left:  epoch 0:00:11  total 0:01:58          
          Time left:  epoch 0:00:10  total 0:01:57          
          Time left:  epoch 0:00:10  total 0:01:57          
          Time left:  epoch 0:00:09  total 0:01:56          
          Time left:  epoch 0:00:08  total 0:01:55          
          Time left:  epoch 0:00:08  total 0:01:55          
          Time left:  epoch 0:00:07  total 0:01:54          
          Time left:  epoch 0:00:07  total 0:01:53          
          Time left:  epoch 0:00:06  total 0:01:53          
          Time left:  epoch 0:00:05  total 0:01:52          
          Time left:  epoch 0:00:05  total 0:01:52          
          Time left:  epoch 0:00:04  total 0:01:51          
          Time left:  epoch 0:00:04  total 0:01:50          
          Time left:  epoch 0:00:03  total 0:01:50          
          Time left:  epoch 0:00:02  total 0:01:49          
          Time left:  epoch 0:00:02  total 0:01:49          
          Time left:  epoch 0:00:01  total 0:01:48          
          Time left:  epoch 0:00:01  total 0:01:47          
          Time left:  epoch 0:00:00  total 0:01:47          
          Time left:  epoch 0:00:00  total 0:01:46          

actor                                                       
  clip fraction                                        0.101
  entropy                                              0.288
  iterations                                            12.2
  kl                                                    0.01
  loss                                               -0.0087
  std                                                  0.323
  stop                                                 0.082
critic                                                      
  iterations                                              80
  loss                                                0.0225
  v                                                     98.7
test                                                        
  action                                                    
    max                                                 2.21
    mean                                           -0.000277
    min                                                -2.22
    size                                               5,000
    std                                                0.943
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  979
    mean                                                 972
    min                                                  963
    size                                                   5
    std                                                  5.5
train                                                       
  action                                                    
    max                                                 2.37
    mean                                             0.00427
    min                                                -2.27
    size                                              20,000
    std                                                0.943
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  983
    mean                                                 969
    min                                                  947
    size                                                  20
    std                                                 8.57
  episodes                                               440
  epoch seconds                                         24.3
  epoch steps                                          2e+04
  epochs                                                  22
  seconds                                                783
  steps                                              4.4e+05
  steps per second                                       823
  worker steps                                       4.4e+05

          Time left:  epoch 0:00:35  total 0:01:46          
          Time left:  epoch 0:00:34  total 0:01:46          
          Time left:  epoch 0:00:34  total 0:01:45          
          Time left:  epoch 0:00:33  total 0:01:44          
          Time left:  epoch 0:00:33  total 0:01:44          
          Time left:  epoch 0:00:32  total 0:01:43          
          Time left:  epoch 0:00:31  total 0:01:42          
          Time left:  epoch 0:00:31  total 0:01:42          
          Time left:  epoch 0:00:30  total 0:01:42          
          Time left:  epoch 0:00:30  total 0:01:41          
          Time left:  epoch 0:00:29  total 0:01:40          
          Time left:  epoch 0:00:29  total 0:01:40          
          Time left:  epoch 0:00:28  total 0:01:39          
          Time left:  epoch 0:00:27  total 0:01:38          
          Time left:  epoch 0:00:27  total 0:01:38          
          Time left:  epoch 0:00:26  total 0:01:37          
          Time left:  epoch 0:00:26  total 0:01:36          
          Time left:  epoch 0:00:25  total 0:01:36          
          Time left:  epoch 0:00:24  total 0:01:35          
          Time left:  epoch 0:00:24  total 0:01:35          
          Time left:  epoch 0:00:23  total 0:01:34          
          Time left:  epoch 0:00:23  total 0:01:34          
          Time left:  epoch 0:00:22  total 0:01:33          
          Time left:  epoch 0:00:21  total 0:01:32          
          Time left:  epoch 0:00:21  total 0:01:32          
          Time left:  epoch 0:00:20  total 0:01:31          
          Time left:  epoch 0:00:20  total 0:01:30          
          Time left:  epoch 0:00:19  total 0:01:30          
          Time left:  epoch 0:00:18  total 0:01:29          
          Time left:  epoch 0:00:18  total 0:01:29          
          Time left:  epoch 0:00:17  total 0:01:28          
          Time left:  epoch 0:00:17  total 0:01:27          
          Time left:  epoch 0:00:16  total 0:01:27          
          Time left:  epoch 0:00:15  total 0:01:26          
          Time left:  epoch 0:00:15  total 0:01:26          
          Time left:  epoch 0:00:14  total 0:01:25          
          Time left:  epoch 0:00:14  total 0:01:24          
          Time left:  epoch 0:00:13  total 0:01:24          
          Time left:  epoch 0:00:12  total 0:01:23          
          Time left:  epoch 0:00:12  total 0:01:23          
          Time left:  epoch 0:00:11  total 0:01:22          
          Time left:  epoch 0:00:11  total 0:01:21          
          Time left:  epoch 0:00:10  total 0:01:21          
          Time left:  epoch 0:00:09  total 0:01:20          
          Time left:  epoch 0:00:09  total 0:01:20          
          Time left:  epoch 0:00:08  total 0:01:19          
          Time left:  epoch 0:00:08  total 0:01:18          
          Time left:  epoch 0:00:07  total 0:01:18          
          Time left:  epoch 0:00:07  total 0:01:17          
          Time left:  epoch 0:00:06  total 0:01:16          
          Time left:  epoch 0:00:05  total 0:01:16          
          Time left:  epoch 0:00:05  total 0:01:15          
          Time left:  epoch 0:00:04  total 0:01:15          
          Time left:  epoch 0:00:04  total 0:01:14          
          Time left:  epoch 0:00:03  total 0:01:13          
          Time left:  epoch 0:00:02  total 0:01:13          
          Time left:  epoch 0:00:02  total 0:01:12          
          Time left:  epoch 0:00:01  total 0:01:12          
          Time left:  epoch 0:00:01  total 0:01:11          
          Time left:  epoch 0:00:00  total 0:01:11          
          Time left:  epoch 0:00:00  total 0:01:10          

actor                                                       
  clip fraction                                        0.112
  entropy                                              0.257
  iterations                                            63.4
  kl                                                  0.0105
  loss                                               -0.0125
  std                                                  0.314
  stop                                               0.00946
critic                                                      
  iterations                                              80
  loss                                                0.0181
  v                                                     98.9
test                                                        
  action                                                    
    max                                                 2.06
    mean                                           -0.000223
    min                                                -2.18
    size                                               5,000
    std                                                0.937
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  979
    mean                                                 975
    min                                                  970
    size                                                   5
    std                                                 4.05
train                                                       
  action                                                    
    max                                                 2.29
    mean                                           -0.000193
    min                                                -2.35
    size                                              20,000
    std                                                0.939
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  985
    mean                                                 974
    min                                                  959
    size                                                  20
    std                                                 5.63
  episodes                                               460
  epoch seconds                                         29.2
  epoch steps                                          2e+04
  epochs                                                  23
  seconds                                                813
  steps                                              4.6e+05
  steps per second                                       686
  worker steps                                       4.6e+05

          Time left:  epoch 0:00:35  total 0:01:10          
          Time left:  epoch 0:00:34  total 0:01:10          
          Time left:  epoch 0:00:34  total 0:01:09          
          Time left:  epoch 0:00:33  total 0:01:08          
          Time left:  epoch 0:00:32  total 0:01:08          
          Time left:  epoch 0:00:32  total 0:01:07          
          Time left:  epoch 0:00:31  total 0:01:06          
          Time left:  epoch 0:00:31  total 0:01:06          
          Time left:  epoch 0:00:30  total 0:01:05          
          Time left:  epoch 0:00:29  total 0:01:05          
          Time left:  epoch 0:00:29  total 0:01:04          
          Time left:  epoch 0:00:28  total 0:01:03          
          Time left:  epoch 0:00:28  total 0:01:03          
          Time left:  epoch 0:00:27  total 0:01:02          
          Time left:  epoch 0:00:26  total 0:01:02          
          Time left:  epoch 0:00:26  total 0:01:01          
          Time left:  epoch 0:00:25  total 0:01:00          
          Time left:  epoch 0:00:25  total 0:01:00          
          Time left:  epoch 0:00:24  total 0:00:59          
          Time left:  epoch 0:00:23  total 0:00:59          
          Time left:  epoch 0:00:23  total 0:00:58          
          Time left:  epoch 0:00:22  total 0:00:57          
          Time left:  epoch 0:00:22  total 0:00:57          
          Time left:  epoch 0:00:21  total 0:00:56          
          Time left:  epoch 0:00:21  total 0:00:56          
          Time left:  epoch 0:00:20  total 0:00:55          
          Time left:  epoch 0:00:19  total 0:00:54          
          Time left:  epoch 0:00:19  total 0:00:54          
          Time left:  epoch 0:00:18  total 0:00:53          
          Time left:  epoch 0:00:18  total 0:00:53          
          Time left:  epoch 0:00:17  total 0:00:52          
          Time left:  epoch 0:00:16  total 0:00:51          
          Time left:  epoch 0:00:16  total 0:00:51          
          Time left:  epoch 0:00:15  total 0:00:50          
          Time left:  epoch 0:00:15  total 0:00:50          
          Time left:  epoch 0:00:14  total 0:00:49          
          Time left:  epoch 0:00:13  total 0:00:48          
          Time left:  epoch 0:00:13  total 0:00:48          
          Time left:  epoch 0:00:12  total 0:00:47          
          Time left:  epoch 0:00:12  total 0:00:47          
          Time left:  epoch 0:00:11  total 0:00:46          
          Time left:  epoch 0:00:11  total 0:00:45          
          Time left:  epoch 0:00:10  total 0:00:45          
          Time left:  epoch 0:00:09  total 0:00:44          
          Time left:  epoch 0:00:09  total 0:00:44          
          Time left:  epoch 0:00:08  total 0:00:43          
          Time left:  epoch 0:00:08  total 0:00:43          
          Time left:  epoch 0:00:07  total 0:00:42          
          Time left:  epoch 0:00:06  total 0:00:41          
          Time left:  epoch 0:00:06  total 0:00:41          
          Time left:  epoch 0:00:05  total 0:00:40          
          Time left:  epoch 0:00:05  total 0:00:40          
          Time left:  epoch 0:00:04  total 0:00:39          
          Time left:  epoch 0:00:04  total 0:00:38          
          Time left:  epoch 0:00:03  total 0:00:38          
          Time left:  epoch 0:00:02  total 0:00:37          
          Time left:  epoch 0:00:02  total 0:00:37          
          Time left:  epoch 0:00:01  total 0:00:36          
          Time left:  epoch 0:00:01  total 0:00:35          
          Time left:  epoch 0:00:00  total 0:00:35          
          Time left:  epoch 0:00:00  total 0:00:34          

actor                                                       
  clip fraction                                       0.0983
  entropy                                              0.227
  iterations                                             5.4
  kl                                                 0.00841
  loss                                              -0.00454
  std                                                  0.304
  stop                                                 0.185
critic                                                      
  iterations                                              80
  loss                                                0.0129
  v                                                       99
test                                                        
  action                                                    
    max                                                  2.1
    mean                                              0.0027
    min                                                -2.16
    size                                               5,000
    std                                                0.931
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  989
    mean                                                 975
    min                                                  968
    size                                                   5
    std                                                 7.51
train                                                       
  action                                                    
    max                                                 2.22
    mean                                            0.000265
    min                                                -2.36
    size                                              20,000
    std                                                0.935
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  985
    mean                                                 975
    min                                                  962
    size                                                  20
    std                                                 6.29
  episodes                                               480
  epoch seconds                                         23.5
  epoch steps                                          2e+04
  epochs                                                  24
  seconds                                                836
  steps                                              4.8e+05
  steps per second                                       850
  worker steps                                       4.8e+05

          Time left:  epoch 0:00:34  total 0:00:34          
          Time left:  epoch 0:00:34  total 0:00:34          
          Time left:  epoch 0:00:33  total 0:00:33          
          Time left:  epoch 0:00:33  total 0:00:33          
          Time left:  epoch 0:00:32  total 0:00:32          
          Time left:  epoch 0:00:31  total 0:00:31          
          Time left:  epoch 0:00:31  total 0:00:31          
          Time left:  epoch 0:00:30  total 0:00:30          
          Time left:  epoch 0:00:30  total 0:00:30          
          Time left:  epoch 0:00:29  total 0:00:29          
          Time left:  epoch 0:00:29  total 0:00:29          
          Time left:  epoch 0:00:28  total 0:00:28          
          Time left:  epoch 0:00:27  total 0:00:27          
          Time left:  epoch 0:00:27  total 0:00:27          
          Time left:  epoch 0:00:26  total 0:00:26          
          Time left:  epoch 0:00:26  total 0:00:26          
          Time left:  epoch 0:00:25  total 0:00:25          
          Time left:  epoch 0:00:24  total 0:00:24          
          Time left:  epoch 0:00:24  total 0:00:24          
          Time left:  epoch 0:00:23  total 0:00:23          
          Time left:  epoch 0:00:23  total 0:00:23          
          Time left:  epoch 0:00:22  total 0:00:22          
          Time left:  epoch 0:00:21  total 0:00:21          
          Time left:  epoch 0:00:21  total 0:00:21          
          Time left:  epoch 0:00:20  total 0:00:20          
          Time left:  epoch 0:00:20  total 0:00:20          
          Time left:  epoch 0:00:19  total 0:00:19          
          Time left:  epoch 0:00:19  total 0:00:19          
          Time left:  epoch 0:00:18  total 0:00:18          
          Time left:  epoch 0:00:17  total 0:00:17          
          Time left:  epoch 0:00:17  total 0:00:17          
          Time left:  epoch 0:00:16  total 0:00:16          
          Time left:  epoch 0:00:16  total 0:00:16          
          Time left:  epoch 0:00:15  total 0:00:15          
          Time left:  epoch 0:00:14  total 0:00:14          
          Time left:  epoch 0:00:14  total 0:00:14          
          Time left:  epoch 0:00:13  total 0:00:13          
          Time left:  epoch 0:00:13  total 0:00:13          
          Time left:  epoch 0:00:12  total 0:00:12          
          Time left:  epoch 0:00:12  total 0:00:12          
          Time left:  epoch 0:00:11  total 0:00:11          
          Time left:  epoch 0:00:10  total 0:00:10          
          Time left:  epoch 0:00:10  total 0:00:10          
          Time left:  epoch 0:00:09  total 0:00:09          
          Time left:  epoch 0:00:09  total 0:00:09          
          Time left:  epoch 0:00:08  total 0:00:08          
          Time left:  epoch 0:00:08  total 0:00:08          
          Time left:  epoch 0:00:07  total 0:00:07          
          Time left:  epoch 0:00:06  total 0:00:06          
          Time left:  epoch 0:00:06  total 0:00:06          
          Time left:  epoch 0:00:05  total 0:00:05          
          Time left:  epoch 0:00:05  total 0:00:05          
          Time left:  epoch 0:00:04  total 0:00:04          
          Time left:  epoch 0:00:04  total 0:00:04          
          Time left:  epoch 0:00:03  total 0:00:03          
          Time left:  epoch 0:00:02  total 0:00:02          
          Time left:  epoch 0:00:02  total 0:00:02          
          Time left:  epoch 0:00:01  total 0:00:01          
          Time left:  epoch 0:00:01  total 0:00:01          
          Time left:  epoch 0:00:00  total 0:00:00          
             Time left:  epoch 0:00:00  total               

actor                                                       
  clip fraction                                       0.0987
  entropy                                              0.218
  iterations                                            18.8
  kl                                                 0.00944
  loss                                               -0.0136
  std                                                  0.302
  stop                                                0.0426
critic                                                      
  iterations                                              80
  loss                                                 0.016
  v                                                     99.1
test                                                        
  action                                                    
    max                                                  2.1
    mean                                            0.000264
    min                                                -2.25
    size                                               5,000
    std                                                0.932
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  981
    mean                                                 974
    min                                                  966
    size                                                   5
    std                                                 5.83
train                                                       
  action                                                    
    max                                                 2.23
    mean                                              0.0027
    min                                                -2.28
    size                                              20,000
    std                                                0.934
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  988
    mean                                                 977
    min                                                  964
    size                                                  20
    std                                                 7.27
  episodes                                               500
  epoch seconds                                         25.1
  epoch steps                                          2e+04
  epochs                                                  25
  seconds                                                861
  steps                                                5e+05
  steps per second                                       797
  worker steps                                         5e+05


Saving weights to data/local/experiments/tonic/swimmer-swim/mlp_256/checkpoints/step_500000.pt

❓

Try playing with the parameters of the trainer and the MLP model and see how it affects the performance.

  • How do the actor and the critic model size affect the performance.

  • Consider increasing the number of steps in trainer to train the model for longer.

  • Explore Tonic library to see what algorithms we can use to train our agents. (D4PG is usually faster than PPO)

Section 2.3 Function to run any model on the environment and generate video

One of the most fun things about these environments is their visualization. We don’t want to just look at the reward to know how good our model is we want to see how well the agent swims. This is particularly important to avoid “reward hacking,” where an agent learns to exploit the reward system in ways that are unintended and potentially detrimental to the desired outcomes. Moreover visualizing the agent also help us understand where the model is going wrong.

Here we have defined a function that will generate the videos of the agent using the input model. The function requires path to the checkpoint folder and the environment you wanna run the trained model on.

Let’s visualize the agent with a pretrained MLP model. Once you have your pretrained model, you can replace the experiment path to visualize the agent with your model.

⏳

/opt/hostedtoolcache/Python/3.10.22/x64/lib/python3.10/site-packages/gym/spaces/box.py:127: UserWarning: WARN: Box bound precision lowered by casting to float32
  logger.warn(f"Box bound precision lowered by casting to {self.dtype}")

Loading weights from data/local/experiments/tonic/swimmer-swim/pretrained_mlp_ppo/checkpoints/step_10000000.pt
Reward for the run:  985.4583222642541
/tmp/ipykernel_7666/4073379236.py:65: MatplotlibDeprecationWarning: Auto-close()ing of figures upon backend switching is deprecated since 3.8 and will be removed two minor releases later.  To suppress this warning, explicitly call plt.close('all') first.
  matplotlib.use(orig_backend)  # Switch back to the original backend.
Loading...

❓

Try testing the model on a modification of the enviroment it was trained on.

  • Train on basic swim task and test on a environment with higher viscosity.

  • Can we train on the basic 6 link swimmer and test on a larger 12 link swimmer?

  • Train the model for a bit on the modified environment and see how quickly the model can adapt to the new environment.


Section 3: NCAP

Now that we are familiar with how to train standard models on the swimmer agent let’s take a look at NCAP a model that was inspired from the C. elegans motor circuit. Our hope with using such models is that they would already have really good priors which should lead to much better transfer, faster learning curves and possibly really good innate performance (zero shot performance).

Check out NCAP paper to learn more about the model.

Paper Illustration

Source
Loading...

3.1 NCAP classes

Now we are going to define SwimmerModule (NCAP model) and SwimmerActor (wrapper around NCAP model to make it compatible with tonic) classes.

Section 3.1.1 Defining the constraints

Can you think of more kinds of weight initializations and constraints that might be useful for the swimmer agent?

Section 3.1.2: Defining the SwimmerModule

The SwimmerModule class represents the neural network module inspired by the C. elegans neural circuitry, designed for controlling a robotic swimmer with specific architectural priors, such as proprioception and oscillatory movement patterns.

Section 3.1.3: Defining the SwimmerActor wrapper

The SwimmerActor class acts as a wrapper around the SwimmerModule, managing high-level control signals and observations coming from the environment and passing them to the SwimmerModule in a suitable format. This class is basically responsible for making the SwimmerModule compatible with the tonic library. If you wish to use any other library to try a algorithm not present in tonic you have to write a new wrapper to make SwimmerModule compatible with that library.

3.2: Train NCAP

We will now define functions akin to those for MLP we defined in Section 3.2, but tailored for the SwimmerActor model.

⏳

/opt/hostedtoolcache/Python/3.10.22/x64/lib/python3.10/site-packages/gym/spaces/box.py:127: UserWarning: WARN: Box bound precision lowered by casting to float32
  logger.warn(f"Box bound precision lowered by casting to {self.dtype}")
Config file saved to data/local/experiments/tonic/swimmer-swim/ncap_ppo/config.yaml
          Time left:  epoch 0:00:56  total 0:04:40          
          Time left:  epoch 0:00:22  total 0:01:55          
          Time left:  epoch 0:00:22  total 0:01:54          
          Time left:  epoch 0:00:21  total 0:01:53          
          Time left:  epoch 0:00:21  total 0:01:52          
          Time left:  epoch 0:00:20  total 0:01:51          
          Time left:  epoch 0:00:20  total 0:01:51          
          Time left:  epoch 0:00:20  total 0:01:50          
          Time left:  epoch 0:00:19  total 0:01:50          
          Time left:  epoch 0:00:19  total 0:01:50          
          Time left:  epoch 0:00:18  total 0:01:49          
          Time left:  epoch 0:00:18  total 0:01:49          
          Time left:  epoch 0:00:18  total 0:01:49          
          Time left:  epoch 0:00:24  total 0:02:27          
          Time left:  epoch 0:00:23  total 0:02:24          
          Time left:  epoch 0:00:22  total 0:02:21          
          Time left:  epoch 0:00:21  total 0:02:18          
          Time left:  epoch 0:00:20  total 0:02:16          
          Time left:  epoch 0:00:20  total 0:02:14          
          Time left:  epoch 0:00:19  total 0:02:12          
          Time left:  epoch 0:00:18  total 0:02:10          
          Time left:  epoch 0:00:18  total 0:02:09          
          Time left:  epoch 0:00:17  total 0:02:07          
          Time left:  epoch 0:00:16  total 0:02:06          
          Time left:  epoch 0:00:16  total 0:02:05          
          Time left:  epoch 0:00:18  total 0:02:23          
          Time left:  epoch 0:00:17  total 0:02:20          
          Time left:  epoch 0:00:16  total 0:02:19          
          Time left:  epoch 0:00:16  total 0:02:17          
          Time left:  epoch 0:00:15  total 0:02:15          
          Time left:  epoch 0:00:14  total 0:02:14          
          Time left:  epoch 0:00:14  total 0:02:12          
          Time left:  epoch 0:00:13  total 0:02:11          
          Time left:  epoch 0:00:13  total 0:02:09          
          Time left:  epoch 0:00:12  total 0:02:08          
          Time left:  epoch 0:00:12  total 0:02:07          
          Time left:  epoch 0:00:11  total 0:02:06          
          Time left:  epoch 0:00:12  total 0:02:17          
          Time left:  epoch 0:00:11  total 0:02:16          
          Time left:  epoch 0:00:10  total 0:02:14          
          Time left:  epoch 0:00:10  total 0:02:13          
          Time left:  epoch 0:00:09  total 0:02:11          
          Time left:  epoch 0:00:09  total 0:02:10          
          Time left:  epoch 0:00:08  total 0:02:09          
          Time left:  epoch 0:00:08  total 0:02:08          
          Time left:  epoch 0:00:07  total 0:02:06          
          Time left:  epoch 0:00:06  total 0:02:05          
          Time left:  epoch 0:00:06  total 0:02:04          
          Time left:  epoch 0:00:05  total 0:02:03          
          Time left:  epoch 0:00:05  total 0:02:02          
          Time left:  epoch 0:00:05  total 0:02:10          
          Time left:  epoch 0:00:04  total 0:02:09          
          Time left:  epoch 0:00:04  total 0:02:08          
          Time left:  epoch 0:00:03  total 0:02:06          
          Time left:  epoch 0:00:03  total 0:02:05          
          Time left:  epoch 0:00:02  total 0:02:04          
          Time left:  epoch 0:00:02  total 0:02:03          
          Time left:  epoch 0:00:01  total 0:02:02          
          Time left:  epoch 0:00:01  total 0:02:01          
          Time left:  epoch 0:00:00  total 0:02:00          
          Time left:  epoch 0:00:00  total 0:01:59          

actor                                                       
  clip fraction                                       0.0182
  entropy                                             -0.884
  iterations                                              80
  kl                                                  0.0034
  loss                                              -0.00131
  std                                                    0.1
  stop                                                     0
critic                                                      
  iterations                                              80
  loss                                                  51.4
  v                                                     33.3
test                                                        
  action                                                    
    max                                                 1.34
    mean                                              0.0166
    min                                                -1.32
    size                                               5,000
    std                                                0.803
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  793
    mean                                                 784
    min                                                  775
    size                                                   5
    std                                                 6.96
train                                                       
  action                                                    
    max                                                 1.42
    mean                                              0.0351
    min                                                -1.38
    size                                              20,000
    std                                                0.805
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  790
    mean                                                 779
    min                                                  755
    size                                                  20
    std                                                 7.14
  episodes                                                20
  epoch seconds                                           35
  epoch steps                                          2e+04
  epochs                                                   1
  seconds                                                 35
  steps                                                2e+04
  steps per second                                       571
  worker steps                                         2e+04

Logging data to data/local/experiments/tonic/swimmer-swim/ncap_ppo/log.csv
          Time left:  epoch 0:00:35  total 0:02:20          
          Time left:  epoch 0:00:34  total 0:02:18          
          Time left:  epoch 0:00:35  total 0:02:24          
          Time left:  epoch 0:00:34  total 0:02:22          
          Time left:  epoch 0:00:33  total 0:02:21          
          Time left:  epoch 0:00:32  total 0:02:19          
          Time left:  epoch 0:00:31  total 0:02:18          
          Time left:  epoch 0:00:31  total 0:02:17          
          Time left:  epoch 0:00:30  total 0:02:15          
          Time left:  epoch 0:00:29  total 0:02:14          
          Time left:  epoch 0:00:28  total 0:02:13          
          Time left:  epoch 0:00:28  total 0:02:12          
          Time left:  epoch 0:00:27  total 0:02:10          
          Time left:  epoch 0:00:26  total 0:02:09          
          Time left:  epoch 0:00:27  total 0:02:14          
          Time left:  epoch 0:00:26  total 0:02:12          
          Time left:  epoch 0:00:25  total 0:02:11          
          Time left:  epoch 0:00:25  total 0:02:10          
          Time left:  epoch 0:00:24  total 0:02:09          
          Time left:  epoch 0:00:23  total 0:02:08          
          Time left:  epoch 0:00:23  total 0:02:06          
          Time left:  epoch 0:00:22  total 0:02:05          
          Time left:  epoch 0:00:21  total 0:02:04          
          Time left:  epoch 0:00:21  total 0:02:03          
          Time left:  epoch 0:00:20  total 0:02:02          
          Time left:  epoch 0:00:19  total 0:02:01          
          Time left:  epoch 0:00:19  total 0:02:00          
          Time left:  epoch 0:00:19  total 0:02:03          
          Time left:  epoch 0:00:18  total 0:02:02          
          Time left:  epoch 0:00:17  total 0:02:01          
          Time left:  epoch 0:00:17  total 0:02:00          
          Time left:  epoch 0:00:16  total 0:01:59          
          Time left:  epoch 0:00:15  total 0:01:58          
          Time left:  epoch 0:00:15  total 0:01:57          
          Time left:  epoch 0:00:14  total 0:01:56          
          Time left:  epoch 0:00:14  total 0:01:55          
          Time left:  epoch 0:00:13  total 0:01:54          
          Time left:  epoch 0:00:12  total 0:01:54          
          Time left:  epoch 0:00:12  total 0:01:53          
          Time left:  epoch 0:00:12  total 0:01:55          
          Time left:  epoch 0:00:11  total 0:01:54          
          Time left:  epoch 0:00:10  total 0:01:53          
          Time left:  epoch 0:00:10  total 0:01:52          
          Time left:  epoch 0:00:09  total 0:01:51          
          Time left:  epoch 0:00:09  total 0:01:50          
          Time left:  epoch 0:00:08  total 0:01:50          
          Time left:  epoch 0:00:07  total 0:01:49          
          Time left:  epoch 0:00:07  total 0:01:48          
          Time left:  epoch 0:00:06  total 0:01:47          
          Time left:  epoch 0:00:06  total 0:01:46          
          Time left:  epoch 0:00:05  total 0:01:45          
          Time left:  epoch 0:00:05  total 0:01:47          
          Time left:  epoch 0:00:04  total 0:01:46          
          Time left:  epoch 0:00:03  total 0:01:45          
          Time left:  epoch 0:00:03  total 0:01:45          
          Time left:  epoch 0:00:02  total 0:01:44          
          Time left:  epoch 0:00:02  total 0:01:43          
          Time left:  epoch 0:00:01  total 0:01:42          
          Time left:  epoch 0:00:01  total 0:01:41          
          Time left:  epoch 0:00:00  total 0:01:40          
          Time left:  epoch 0:00:00  total 0:01:40          

actor                                                       
  clip fraction                                       0.0195
  entropy                                             -0.884
  iterations                                              80
  kl                                                   0.003
  loss                                              -0.00142
  std                                                    0.1
  stop                                                     0
critic                                                      
  iterations                                              80
  loss                                                  3.69
  v                                                     66.8
test                                                        
  action                                                    
    max                                                 1.38
    mean                                             0.00163
    min                                                -1.35
    size                                               5,000
    std                                                 0.81
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  795
    mean                                                 789
    min                                                  780
    size                                                   5
    std                                                 5.52
train                                                       
  action                                                    
    max                                                 1.36
    mean                                              0.0241
    min                                                -1.43
    size                                              20,000
    std                                                0.808
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  801
    mean                                                 787
    min                                                  777
    size                                                  20
    std                                                 6.42
  episodes                                                40
  epoch seconds                                         36.8
  epoch steps                                          2e+04
  epochs                                                   2
  seconds                                               71.8
  steps                                                4e+04
  steps per second                                       544
  worker steps                                         4e+04

          Time left:  epoch 0:00:35  total 0:01:47          
          Time left:  epoch 0:00:35  total 0:01:46          
          Time left:  epoch 0:00:34  total 0:01:46          
          Time left:  epoch 0:00:34  total 0:01:47          
          Time left:  epoch 0:00:33  total 0:01:46          
          Time left:  epoch 0:00:33  total 0:01:45          
          Time left:  epoch 0:00:32  total 0:01:44          
          Time left:  epoch 0:00:31  total 0:01:43          
          Time left:  epoch 0:00:31  total 0:01:43          
          Time left:  epoch 0:00:30  total 0:01:42          
          Time left:  epoch 0:00:29  total 0:01:41          
          Time left:  epoch 0:00:29  total 0:01:40          
          Time left:  epoch 0:00:28  total 0:01:39          
          Time left:  epoch 0:00:27  total 0:01:38          
          Time left:  epoch 0:00:27  total 0:01:37          
          Time left:  epoch 0:00:26  total 0:01:37          
          Time left:  epoch 0:00:26  total 0:01:38          
          Time left:  epoch 0:00:25  total 0:01:37          
          Time left:  epoch 0:00:25  total 0:01:36          
          Time left:  epoch 0:00:24  total 0:01:35          
          Time left:  epoch 0:00:23  total 0:01:34          
          Time left:  epoch 0:00:23  total 0:01:34          
          Time left:  epoch 0:00:22  total 0:01:33          
          Time left:  epoch 0:00:21  total 0:01:32          
          Time left:  epoch 0:00:21  total 0:01:31          
          Time left:  epoch 0:00:20  total 0:01:30          
          Time left:  epoch 0:00:19  total 0:01:29          
          Time left:  epoch 0:00:19  total 0:01:29          
          Time left:  epoch 0:00:18  total 0:01:30          
          Time left:  epoch 0:00:18  total 0:01:29          
          Time left:  epoch 0:00:17  total 0:01:28          
Saving weights to data/local/experiments/tonic/swimmer-swim/ncap_ppo/checkpoints/step_50000.pt
          Time left:  epoch 0:00:17  total 0:01:27          
          Time left:  epoch 0:00:16  total 0:01:27          
          Time left:  epoch 0:00:15  total 0:01:26          
          Time left:  epoch 0:00:15  total 0:01:25          
          Time left:  epoch 0:00:14  total 0:01:24          
          Time left:  epoch 0:00:13  total 0:01:23          
          Time left:  epoch 0:00:13  total 0:01:23          
          Time left:  epoch 0:00:12  total 0:01:22          
          Time left:  epoch 0:00:12  total 0:01:21          
          Time left:  epoch 0:00:11  total 0:01:22          
          Time left:  epoch 0:00:11  total 0:01:21          
          Time left:  epoch 0:00:10  total 0:01:20          
          Time left:  epoch 0:00:09  total 0:01:20          
          Time left:  epoch 0:00:09  total 0:01:19          
          Time left:  epoch 0:00:08  total 0:01:18          
          Time left:  epoch 0:00:08  total 0:01:17          
          Time left:  epoch 0:00:07  total 0:01:17          
          Time left:  epoch 0:00:06  total 0:01:16          
          Time left:  epoch 0:00:06  total 0:01:15          
          Time left:  epoch 0:00:05  total 0:01:14          
          Time left:  epoch 0:00:05  total 0:01:14          
          Time left:  epoch 0:00:04  total 0:01:13          
          Time left:  epoch 0:00:04  total 0:01:14          
          Time left:  epoch 0:00:03  total 0:01:13          
          Time left:  epoch 0:00:02  total 0:01:12          
          Time left:  epoch 0:00:02  total 0:01:11          
          Time left:  epoch 0:00:01  total 0:01:11          
          Time left:  epoch 0:00:01  total 0:01:10          
          Time left:  epoch 0:00:00  total 0:01:09          
          Time left:  epoch 0:00:00  total 0:01:09          

actor                                                       
  clip fraction                                       0.0282
  entropy                                             -0.884
  iterations                                              80
  kl                                                 0.00248
  loss                                              -0.00163
  std                                                    0.1
  stop                                                     0
critic                                                      
  iterations                                              80
  loss                                                 0.616
  v                                                       77
test                                                        
  action                                                    
    max                                                 1.41
    mean                                              0.0221
    min                                                -1.34
    size                                               5,000
    std                                                0.815
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  806
    mean                                                 796
    min                                                  790
    size                                                   5
    std                                                 5.67
train                                                       
  action                                                    
    max                                                 1.43
    mean                                              0.0282
    min                                                -1.41
    size                                              20,000
    std                                                0.814
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  801
    mean                                                 791
    min                                                  777
    size                                                  20
    std                                                 6.21
  episodes                                                60
  epoch seconds                                         36.8
  epoch steps                                          2e+04
  epochs                                                   3
  seconds                                                109
  steps                                                6e+04
  steps per second                                       544
  worker steps                                         6e+04

          Time left:  epoch 0:00:36  total 0:01:12          
          Time left:  epoch 0:00:35  total 0:01:11          
          Time left:  epoch 0:00:34  total 0:01:10          
          Time left:  epoch 0:00:34  total 0:01:10          
          Time left:  epoch 0:00:33  total 0:01:09          
          Time left:  epoch 0:00:33  total 0:01:09          
          Time left:  epoch 0:00:32  total 0:01:09          
          Time left:  epoch 0:00:32  total 0:01:08          
          Time left:  epoch 0:00:31  total 0:01:07          
          Time left:  epoch 0:00:30  total 0:01:06          
          Time left:  epoch 0:00:30  total 0:01:06          
          Time left:  epoch 0:00:29  total 0:01:05          
          Time left:  epoch 0:00:28  total 0:01:04          
          Time left:  epoch 0:00:28  total 0:01:03          
          Time left:  epoch 0:00:27  total 0:01:03          
          Time left:  epoch 0:00:26  total 0:01:02          
          Time left:  epoch 0:00:26  total 0:01:01          
          Time left:  epoch 0:00:25  total 0:01:02          
          Time left:  epoch 0:00:25  total 0:01:01          
          Time left:  epoch 0:00:24  total 0:01:00          
          Time left:  epoch 0:00:23  total 0:00:59          
          Time left:  epoch 0:00:23  total 0:00:59          
          Time left:  epoch 0:00:22  total 0:00:58          
          Time left:  epoch 0:00:22  total 0:00:57          
          Time left:  epoch 0:00:21  total 0:00:57          
          Time left:  epoch 0:00:20  total 0:00:56          
          Time left:  epoch 0:00:20  total 0:00:55          
          Time left:  epoch 0:00:19  total 0:00:55          
          Time left:  epoch 0:00:18  total 0:00:54          
          Time left:  epoch 0:00:18  total 0:00:54          
          Time left:  epoch 0:00:17  total 0:00:53          
          Time left:  epoch 0:00:17  total 0:00:53          
          Time left:  epoch 0:00:16  total 0:00:52          
          Time left:  epoch 0:00:16  total 0:00:51          
          Time left:  epoch 0:00:15  total 0:00:51          
          Time left:  epoch 0:00:14  total 0:00:50          
          Time left:  epoch 0:00:14  total 0:00:49          
          Time left:  epoch 0:00:13  total 0:00:49          
          Time left:  epoch 0:00:12  total 0:00:48          
          Time left:  epoch 0:00:12  total 0:00:47          
          Time left:  epoch 0:00:11  total 0:00:47          
          Time left:  epoch 0:00:11  total 0:00:46          
          Time left:  epoch 0:00:10  total 0:00:46          
          Time left:  epoch 0:00:10  total 0:00:45          
          Time left:  epoch 0:00:09  total 0:00:45          
          Time left:  epoch 0:00:08  total 0:00:44          
          Time left:  epoch 0:00:08  total 0:00:43          
          Time left:  epoch 0:00:07  total 0:00:43          
          Time left:  epoch 0:00:07  total 0:00:42          
          Time left:  epoch 0:00:06  total 0:00:41          
          Time left:  epoch 0:00:05  total 0:00:41          
          Time left:  epoch 0:00:05  total 0:00:40          
          Time left:  epoch 0:00:04  total 0:00:39          
          Time left:  epoch 0:00:04  total 0:00:39          
          Time left:  epoch 0:00:03  total 0:00:39          
          Time left:  epoch 0:00:02  total 0:00:38          
          Time left:  epoch 0:00:02  total 0:00:37          
          Time left:  epoch 0:00:01  total 0:00:37          
          Time left:  epoch 0:00:01  total 0:00:36          
          Time left:  epoch 0:00:00  total 0:00:35          
          Time left:  epoch 0:00:00  total 0:00:35          

actor                                                       
  clip fraction                                       0.0258
  entropy                                             -0.884
  iterations                                              80
  kl                                                 0.00305
  loss                                              -0.00153
  std                                                    0.1
  stop                                                     0
critic                                                      
  iterations                                              80
  loss                                                 0.232
  v                                                     80.1
test                                                        
  action                                                    
    max                                                 1.34
    mean                                              0.0338
    min                                                -1.38
    size                                               5,000
    std                                                0.822
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  802
    mean                                                 797
    min                                                  789
    size                                                   5
    std                                                  5.1
train                                                       
  action                                                    
    max                                                 1.39
    mean                                              0.0214
    min                                                -1.42
    size                                              20,000
    std                                                0.821
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  808
    mean                                                 798
    min                                                  784
    size                                                  20
    std                                                 5.94
  episodes                                                80
  epoch seconds                                         37.2
  epoch steps                                          2e+04
  epochs                                                   4
  seconds                                                146
  steps                                                8e+04
  steps per second                                       538
  worker steps                                         8e+04

          Time left:  epoch 0:00:36  total 0:00:36          
          Time left:  epoch 0:00:35  total 0:00:35          
          Time left:  epoch 0:00:35  total 0:00:35          
          Time left:  epoch 0:00:34  total 0:00:34          
          Time left:  epoch 0:00:33  total 0:00:33          
          Time left:  epoch 0:00:33  total 0:00:33          
          Time left:  epoch 0:00:32  total 0:00:32          
          Time left:  epoch 0:00:32  total 0:00:32          
          Time left:  epoch 0:00:31  total 0:00:31          
          Time left:  epoch 0:00:30  total 0:00:30          
          Time left:  epoch 0:00:30  total 0:00:30          
          Time left:  epoch 0:00:29  total 0:00:29          
          Time left:  epoch 0:00:29  total 0:00:29          
          Time left:  epoch 0:00:28  total 0:00:28          
          Time left:  epoch 0:00:27  total 0:00:27          
          Time left:  epoch 0:00:27  total 0:00:27          
          Time left:  epoch 0:00:26  total 0:00:26          
          Time left:  epoch 0:00:25  total 0:00:25          
          Time left:  epoch 0:00:25  total 0:00:25          
          Time left:  epoch 0:00:24  total 0:00:24          
          Time left:  epoch 0:00:24  total 0:00:24          
          Time left:  epoch 0:00:23  total 0:00:23          
          Time left:  epoch 0:00:22  total 0:00:22          
          Time left:  epoch 0:00:22  total 0:00:22          
          Time left:  epoch 0:00:21  total 0:00:21          
          Time left:  epoch 0:00:21  total 0:00:21          
          Time left:  epoch 0:00:20  total 0:00:20          
          Time left:  epoch 0:00:19  total 0:00:19          
          Time left:  epoch 0:00:19  total 0:00:19          
          Time left:  epoch 0:00:18  total 0:00:18          
          Time left:  epoch 0:00:17  total 0:00:17          
          Time left:  epoch 0:00:17  total 0:00:17          
          Time left:  epoch 0:00:16  total 0:00:16          
          Time left:  epoch 0:00:16  total 0:00:16          
          Time left:  epoch 0:00:15  total 0:00:15          
          Time left:  epoch 0:00:14  total 0:00:14          
          Time left:  epoch 0:00:14  total 0:00:14          
          Time left:  epoch 0:00:13  total 0:00:13          
          Time left:  epoch 0:00:13  total 0:00:13          
          Time left:  epoch 0:00:12  total 0:00:12          
          Time left:  epoch 0:00:11  total 0:00:11          
          Time left:  epoch 0:00:11  total 0:00:11          
          Time left:  epoch 0:00:10  total 0:00:10          
          Time left:  epoch 0:00:10  total 0:00:10          
          Time left:  epoch 0:00:09  total 0:00:09          
          Time left:  epoch 0:00:08  total 0:00:08          
          Time left:  epoch 0:00:08  total 0:00:08          
          Time left:  epoch 0:00:07  total 0:00:07          
          Time left:  epoch 0:00:07  total 0:00:07          
          Time left:  epoch 0:00:06  total 0:00:06          
          Time left:  epoch 0:00:05  total 0:00:05          
          Time left:  epoch 0:00:05  total 0:00:05          
          Time left:  epoch 0:00:04  total 0:00:04          
          Time left:  epoch 0:00:04  total 0:00:04          
          Time left:  epoch 0:00:03  total 0:00:03          
          Time left:  epoch 0:00:02  total 0:00:02          
          Time left:  epoch 0:00:02  total 0:00:02          
          Time left:  epoch 0:00:01  total 0:00:01          
          Time left:  epoch 0:00:01  total 0:00:01          
          Time left:  epoch 0:00:00  total 0:00:00          
             Time left:  epoch 0:00:00  total               

actor                                                       
  clip fraction                                       0.0308
  entropy                                             -0.884
  iterations                                              80
  kl                                                 0.00263
  loss                                              -0.00177
  std                                                    0.1
  stop                                                     0
critic                                                      
  iterations                                              80
  loss                                                 0.129
  v                                                     81.4
test                                                        
  action                                                    
    max                                                 1.42
    mean                                              0.0208
    min                                                -1.33
    size                                               5,000
    std                                                 0.83
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                   5
    std                                                    0
  episode score                                             
    max                                                  820
    mean                                                 811
    min                                                  806
    size                                                   5
    std                                                 5.36
train                                                       
  action                                                    
    max                                                 1.42
    mean                                               0.027
    min                                                -1.38
    size                                              20,000
    std                                                0.827
  episode length                                            
    max                                                1,000
    mean                                               1e+03
    min                                                1,000
    size                                                  20
    std                                                    0
  episode score                                             
    max                                                  817
    mean                                                 803
    min                                                  796
    size                                                  20
    std                                                 5.42
  episodes                                               100
  epoch seconds                                         36.9
  epoch steps                                          2e+04
  epochs                                                   5
  seconds                                                183
  steps                                                1e+05
  steps per second                                       542
  worker steps                                         1e+05


Saving weights to data/local/experiments/tonic/swimmer-swim/ncap_ppo/checkpoints/step_100000.pt

Let’s visualize the trained NCAP agent in the environment.

⏳


Loading weights from data/local/experiments/tonic/swimmer-swim/pretrained_ncap_ppo/checkpoints/step_10000000.pt
Reward for the run:  916.4626159919426
/tmp/ipykernel_7666/4073379236.py:65: MatplotlibDeprecationWarning: Auto-close()ing of figures upon backend switching is deprecated since 3.8 and will be removed two minor releases later.  To suppress this warning, explicitly call plt.close('all') first.
  matplotlib.use(orig_backend)  # Switch back to the original backend.
Loading...

❓

This architecture was designed using the C. elegans motor circuit that can swim right at birth i.e it should already have really good priors. Can you try visualizing an agent with an untrained NCAP model. Can it swim?

3.3 Plot perfomance

Now we are going to visualize performance of our model

<Figure size 640x480 with 1 Axes>

❓

  • Compare the performance and learning curve of NCAP to MLP for the basic swimmer agent.

  • Try testing the model on a modification of the environment (e.g., the 12-link swimmer) it was trained on.

  • What happens if we remove certain weight constraints (e.g., sign constraint) from the NCAP model?


Section 4: Visualizing the sparse network

Given the importance of architectural choices in our project we have provided a function which can visualize the network architecture. This includes the ability to render the NCAP network, representing the C. Elegans connectome.

Notice that the NCAP architecture is highly sparse and interpretable as compared to the MLP. Moreover notice that the ncap architecture can be completely embedded within a fully connected MLP of 3 hidden layers and ReLU nonlinearities. This enables us to do a thorough investigation into how specific architectural elements influence both performance and the learning process. By leveraging this capability, we can systematically analyze the impact of the architectural preferences inherent to the model and make better design choices.

It might be useful to also visualize the network’s activity for NCAP. Given it only has 4 learnable parameters it becomes much easier to interpret the network.


Conclusion

Based on the concepts we’ve discussed in this tutorial, you should now be equipped to advance with the project. Within this project, there are multiple pathways you can explore. For each pathway, you will delve deeply into one of the main sections outlined in this notebook, allowing for a thorough investigation of different factors that can influence performance:

  • Exploring the effects of environment: Investigate how different environmental settings impact agent performance. This could involve altering parameters of the environment or the types of tasks and reward functions. Understanding these effects can help in making better architectural choices and learning algorithms that result in agents that are robust and adaptable

  • Exploring the effects of learning algorithms: Standard RL algorithms often struggle with sparse and constrained networks, which can lead to suboptimal performance. Explore where these algorithms fail and analyze potential reasons for their limitations. Experiment with modifications or alternative algorithms that might overcome these challenges.

  • Exploring the effects of model architecture: Investigate how various architectural decisions within the NCAP model influence its performance. Visualize the model and its activity and explore potential improvements by tweaking architectural elements, assessing how these changes affect learning outcomes and operational efficiency.