Closed philwinder closed 4 years ago
I've found a workaround. You can call:
from rl_coach import logger
logger.get_experiment_path("", None)
Which sets the experiment_path
global.
I would still recommend removing the use of the global, however. Removing it should mitigate against bugs like this.
Thanks.
Hi @philwinder,
Thanks a lot for catching this issue. We have only tested dumping gifs and mp4s while running Coach from the command line. I have just tested it again now, and this path seems to work well.
It was not tested, though, when running through the "Coach as a library" Python API (which is fairly new).
I agree that the use of a global variable for the experiment_path
is a less than ideal programming scheme. We definitely will consider changing it in a future update to the framework. Specifically, in this case, I think that the issue is that the 'experiment_path' was initialized to None
instead of and empty string. I have pushed PR #405, which changes the default value of the global experiment_path
to an empty string. It seems to workaround the issue for me.
Perfect, thanks.
Hi there, When trying to dump videos in gym environments I receive the following error when trying to dump a gif:
You encounter the same problem with mp4s too. This is due to a global
experiment_path
which is set to None earlier in the file. In the past I was able to override it, but now that doesn't seem to work any more.Here is a simple example that can recreate the problem:
Any ideas how to work around this?
Thanks, Phil