Skip to content

Commit

Permalink
feat: Add one second sleep to eval schedules loop.
Browse files Browse the repository at this point in the history
Co-authored-by: Dries <30599100+DriesSmit@users.noreply.github.com>
  • Loading branch information
KaleabTessera and DriesSmit authored Nov 30, 2021
1 parent 47e1725 commit 46818c4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion mava/environment_loop.py
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,9 @@ def should_run_loop(eval_condtion: Tuple) -> bool:
step_count += result["episode_length"]
# Log the given results.
self._logger.write(result)

else:
# Note: We assume that the evaluator will be running less than once per second.
time.sleep(1)
# We need to get the latest counts if we are using eval intervals.
if environment_loop_schedule:
self._executor.update()

0 comments on commit 46818c4

Please sign in to comment.