Skip to content

Commit

Permalink
Correct logging to plot per episode reward rather than per timestep
Browse files Browse the repository at this point in the history
  • Loading branch information
shariqiqbal2810 committed Jul 20, 2020
1 parent bd263af commit 105d60e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ def run(config):
ep_rews = replay_buffer.get_average_rewards(
config.episode_length * config.n_rollout_threads)
for a_i, a_ep_rew in enumerate(ep_rews):
logger.add_scalar('agent%i/mean_episode_rewards' % a_i, a_ep_rew, ep_i)
logger.add_scalar('agent%i/mean_episode_rewards' % a_i,
a_ep_rew * config.episode_length, ep_i)

if ep_i % config.save_interval < config.n_rollout_threads:
model.prep_rollouts(device='cpu')
Expand Down

0 comments on commit 105d60e

Please sign in to comment.