nel subcommittee code
The recommended version of Python is 2.7
-
Install the nel-framework according to https://github.com/eaplatanios/nel_framework/#installation-instructions
-
Install the dependencies using
pip install torch
and for python2pip install enum34
-
Run train.py to train, and test.py to visualize
Create a new class that extends BaseAgent
. For this agent, implement the following functions:
save()
: Saves the state of the agent. If you don't want to save, just use apass
statement for the body_load()
: Loads the state of the agent. If you don't want to load, just use apass
statement for the bodystep()
: You can add whatever parameters you want to this. This will be called in your training loop. This function should callenv.step
which takes in a reference to the agent and a function that takes in no arguments and returns the next move that your agent should do.next_move()
: You can add whatever parameters you want to this. This function should return the next move that the agent should do.
Note: The recommended way you should structure the interaction between the environment and the agent is by creating a function that takes in the parameters needed for next_move()
and returns a partial function that takes in no arguments that can be called by env.step
. See the example in RLAgent
.
Youtube video [paper]
Class presentation [link]