Skip to content

Commit

Permalink
Merge branch 'update-gymnasium-dep' into benchmark-pr
Browse files Browse the repository at this point in the history
  • Loading branch information
taufeeque9 committed Oct 7, 2023
2 parents 77c1115 + ba4b693 commit bb76ee1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/imitation/scripts/eval_policy.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,11 @@ def eval_policy(
log_dir = logging_ingredient.make_log_dir()
sample_until = rollout.make_sample_until(eval_n_timesteps, eval_n_episodes)
post_wrappers = [video_wrapper_factory(log_dir, **video_kwargs)] if videos else None
with environment.make_venv(post_wrappers=post_wrappers) as venv:
render_mode = "rgb_array" if videos else None
with environment.make_venv(
post_wrappers=post_wrappers,
env_make_kwargs=dict(render_mode=render_mode),
) as venv:
if render:
venv = InteractiveRender(venv, render_fps)

Expand Down

0 comments on commit bb76ee1

Please sign in to comment.