Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SB3 doesn't seem to log success rate #1470

Closed
3 of 4 tasks
npnike10 opened this issue Apr 26, 2023 · 1 comment
Closed
3 of 4 tasks

SB3 doesn't seem to log success rate #1470

npnike10 opened this issue Apr 26, 2023 · 1 comment
Labels
question Further information is requested

Comments

@npnike10
Copy link

npnike10 commented Apr 26, 2023

❓ Question

I am using DQN and PPO. DQN shows success rate for me during training and in tensorboard logs, but PPO doesn't.

I saw that to have success rate logged and displayed during training, one needs to add a dict with 'is_success' key as the value of info at the end of episodes. So I did that and DQN showed me success rate during data it displays when training as well as in the tensorboard logs. I did not wrap env with Monitor myself or use any callbacks etc., I just constructed my gym env which gives such an info and passed it to DQN.

Now with PPO, I don't get the success rate. I am not sure why. As something to try, since the Logger section in SB3 docs suggests wrapping env with a Monitor and giving a particular argument to ensure success rate is logged, I tried that but what happened is the generated monitor.csv does contain a column 'is_success' with true/false values but the data displayed during training or tensorboard logs don't seem to contain success rate. Here's the monitor line:

env = Monitor(env, "./ppo_sumo_tensorboard/", info_keywords=("is_success",))

I don't know if any other code would be helpful but I can happily provide any if it is.

Thank you very much for your time!

Checklist

  • I have checked that there is no similar issue in the repo
  • I have read the documentation
  • If code there is, it is minimal and working
  • If code there is, it is formatted using the markdown code blocks for both code and stack traces.
@npnike10 npnike10 added the question Further information is requested label Apr 26, 2023
@npnike10
Copy link
Author

I see there are similar issues. Sorry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant