Skip to content

Instantly share code, notes, and snippets.

@davidADSP
Last active January 23, 2021 22:04
Show Gist options
  • Save davidADSP/9731e74b945778e933483b958e7b472d to your computer and use it in GitHub Desktop.
Save davidADSP/9731e74b945778e933483b958e7b472d to your computer and use it in GitHub Desktop.
reset wrapper for self-play environment
class SelfPlayEnv(env):
# ...
def reset(self):
super(SelfPlayEnv, self).reset()
self.setup_opponents()
if self.current_player_num != self.agent_player_num:
self.continue_game()
return self.observation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment