Skip to content

Latest commit

 

History

History
32 lines (26 loc) · 1.12 KB

README.md

File metadata and controls

32 lines (26 loc) · 1.12 KB

Instructions to execute

  1. First, create the virtual environment and activate the environment.
virtualenv -p python3 myenv
source myenv/bin/activate
  1. Then, we install all the required packages.
pip install -r requirements.txt
  1. Register custom gym environment.
pip install -e gym-environments/
  1. Now we are ready to train a DQN agent. To do this, we must execute the following command. Notice that inside the train_DQN.py there are different hyperparameters that you can configure to set the training for different topologies, to define the size of the GNN model, etc.
python train_DQN.py
  1. Now that the training process is executing, we can see the DQN agent performance evolution by parsing the log files.
python parse.py -d ./Logs/expsample_DQN_agentLogs.txt
  1. Finally, we can evaluate our trained model on different topologies executing the command below. Notice that in the evaluate_DQN.py script you must modify the hyperparameters of the model to match the ones from the trained model.
python evaluate_DQN.py -d ./Logs/expsample_DQN_agentLogs.txt