Shmuma / ptan

PyTorch Agent Net: reinforcement learning toolkit for pytorch
MIT License
531 stars 165 forks source link

Code run time #30

Closed gp1702 closed 4 years ago

gp1702 commented 4 years ago

Is there a way to run the training and evaluation for a certain number of time-steps? Currently the PPO examples in both the first and second edition run forever.

Shmuma commented 4 years ago

Hi! You can always press Ctrl-C on the console to interrupt the optimisation. If you want to do this programmatically, it will be just inside the training loop:

if some_condition:
    break