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

Also log episodic_length for non-PPO scripts. #168

Closed
Tracked by #115 ...
vwxyzjn opened this issue Apr 24, 2022 · 0 comments · Fixed by #173
Closed
Tracked by #115 ...

Also log episodic_length for non-PPO scripts. #168

vwxyzjn opened this issue Apr 24, 2022 · 0 comments · Fixed by #173

Comments

@vwxyzjn
Copy link
Owner

vwxyzjn commented Apr 24, 2022

Problem Description

We should also log episodic_length for non-PPO scripts. That is we do the following for PPO

cleanrl/cleanrl/ppo.py

Lines 213 to 214 in 5184afc

writer.add_scalar("charts/episodic_return", item["episode"]["r"], global_step)
writer.add_scalar("charts/episodic_length", item["episode"]["l"], global_step)

but in dqn.py we don't do this:

cleanrl/cleanrl/dqn.py

Lines 167 to 170 in 5184afc

for info in infos:
if "episode" in info.keys():
print(f"global_step={global_step}, episodic_return={info['episode']['r']}")
writer.add_scalar("charts/episodic_return", info["episode"]["r"], global_step)

@vwxyzjn vwxyzjn mentioned this issue May 31, 2022
19 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant