Last active
December 1, 2019 14:44
-
-
Save davidADSP/d0bc05f1deca4fa0c21348513727a646 to your computer and use it in GitHub Desktop.
run_selfplay (https://arxiv.org/src/1911.08265v1/anc/pseudocode.py)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Each self-play job is independent of all others; it takes the latest network | |
# snapshot, produces a game and makes it available to the training job by | |
# writing it to a shared replay buffer. | |
def run_selfplay(config: MuZeroConfig, storage: SharedStorage, | |
replay_buffer: ReplayBuffer): | |
while True: | |
network = storage.latest_network() | |
game = play_game(config, network) | |
replay_buffer.save_game(game) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment