PierreExeter / rl_reach

RL Reach is a platform for running reproducible reinforcement learning experiments.
https://rl-reach.readthedocs.io/en/latest/index.html
42 stars 9 forks source link

evaluate_policy.py - Cant find 'res_episode_1.csv' #3

Closed stefanwanckel closed 3 years ago

stefanwanckel commented 3 years ago

'evaluate_policy.py' works fine without the --log-info flag. However, when attempting to create the log info, I get the following error:

Traceback (most recent call last): File "scripts/plot_episode_eval_log.py", line 17, in FILE_PATH = str(list(Path(LOG_DIR).rglob('res_episode_1.csv'))[0]) IndexError: list index out of range

The file 'res_episode.csv' does not exist in the logs directory and hence FILE_PATH is empty. I had trouble finding the script that creates the 'res_episode_1.csv' file. Could you point me in the right direction? Thanks in advance for your help.

PierreExeter commented 3 years ago

The res_episode_1.csv file is created in the enjoy.py file. This script is called by the evaluate_policy.py script. The plot_episode_eval_log.py will return this error if the csv file is not written in the first place. If you send me a minimal example that reproduces the error, I can have a closer look.

stefanwanckel commented 3 years ago

Thanks for your reply. I was missing the obsDictWrapper. It works now

PierreExeter commented 3 years ago

Glad to hear