Skip to content

Commit

Permalink
Adds close method
Browse files Browse the repository at this point in the history
  • Loading branch information
Ivan-267 committed Aug 3, 2023
1 parent 6b73e59 commit 680700d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions godot_rl/wrappers/clean_rl_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,12 @@ def single_observation_space(self):
@property
def single_action_space(self):
return self.envs[0].action_space

@property
def num_envs(self) -> int:
return self.envs[0].num_envs * self.n_parallel

def close(self) -> None:
# Close each environment
for env in self.envs:
env.close()

0 comments on commit 680700d

Please sign in to comment.