remove render(mode=visualization)
This commit is contained in:
parent
6902e01db0
commit
253e495df2
|
@ -86,10 +86,10 @@ def eval_policy(
|
||||||
def maybe_render_frame(env):
|
def maybe_render_frame(env):
|
||||||
if save_video: # noqa: B023
|
if save_video: # noqa: B023
|
||||||
if return_first_video:
|
if return_first_video:
|
||||||
visu = env.envs[0].render(mode="visualization")
|
visu = env.envs[0].render()
|
||||||
visu = visu[None, ...] # add batch dim
|
visu = visu[None, ...] # add batch dim
|
||||||
else:
|
else:
|
||||||
visu = np.stack([env.render(mode="visualization") for env in env.envs])
|
visu = np.stack([env.render() for env in env.envs])
|
||||||
ep_frames.append(visu) # noqa: B023
|
ep_frames.append(visu) # noqa: B023
|
||||||
|
|
||||||
for _ in range(num_episodes):
|
for _ in range(num_episodes):
|
||||||
|
|
Loading…
Reference in New Issue