[−][src]Function ggpf::deep::self_play::muzero_game_generator
pub async fn muzero_game_generator<GB, B, A>(
config: MuZeroConfig<B, A>,
config_selfplay: SelfPlay,
game_builder: GB,
output_chan: Sender<GameHistoryEntry<GB::G>>
) where
GB::G: Features + Send + Sync + 'static,
<GB::G as Base>::Move: Send + Sync,
<GB::G as Game>::Player: Send + Sync,
GB: GameBuilder + Clone + Sync + Send + 'static,
A: Dimension + 'static,
B: Dimension + 'static,
MuZero self-play games generator
Spawn several tasks (number according to settings) that performs self-play games
using the MuZero policy, sending them in the output_chan
channel.
Params
puct_settings
: configuration for PUCT policy and virtual state dimension.game_builder
: game builder.prediction_tensorflow
: interface for the prediction network.dynamics_tensorflow
: interface for the dynamics network.representation_tensorflow
: interface for the representation network.output_chan
: communication channel to emit the generated games.
Panics
This function will panic if the evaluator shapes doesn't fit, or if the CUDA executor goes out of memory.