def __init__(self, config_type="mini"): """ :param str config_type: one of "mini", "normal", or "distributed", representing the set of configs to use for all of the config attributes. Mini is a small version, normal is the larger version, and distributed is a version which runs across multiple GPUs it seems """ self.opts = Options() self.resource = ResourceConfig() if config_type == "mini": import chess_zero.configs.mini as c elif config_type == "normal": import chess_zero.configs.normal as c elif config_type == "distributed": import chess_zero.configs.distributed as c else: raise RuntimeError(f"unknown config_type: {config_type}") self.model = c.ModelConfig() self.play = c.PlayConfig() self.play_data = c.PlayDataConfig() self.trainer = c.TrainerConfig() self.eval = c.EvaluateConfig() self.labels = Config.labels self.n_labels = Config.n_labels self.flipped_labels = Config.flipped_labels
def __init__(self, config_type="mini"): self.opts = Options() self.resource = ResourceConfig() if config_type == "mini": import chess_zero.configs.mini as c elif config_type == "normal": import chess_zero.configs.normal as c else: raise RuntimeError(f"unknown config_type: {config_type}") self.model = c.ModelConfig() self.play = c.PlayConfig() self.play_data = c.PlayDataConfig() self.trainer = c.TrainerConfig() self.eval = c.EvaluateConfig() self.labels = create_uci_labels() self.n_labels = len(self.labels)
def __init__(self, config_type="mini"): self.opts = Options() self.resource = ResourceConfig() if config_type == "mini": import chess_zero.configs.mini as c elif config_type == "normal": import chess_zero.configs.normal as c elif config_type == "distributed": import chess_zero.configs.distributed as c else: raise RuntimeError('unknown config_type: %s' % (config_type)) self.model = c.ModelConfig() self.play = c.PlayConfig() self.play_data = c.PlayDataConfig() self.trainer = c.TrainerConfig() self.eval = c.EvaluateConfig() self.labels = Config.labels self.n_labels = Config.n_labels self.flipped_labels = Config.flipped_labels
def __init__(self, config_type="normal"): self.opts = Options() self.resource = ResourceConfig() if config_type == "mini": import chess_zero.configs.mini as c elif config_type == "small": import chess_zero.configs.small as c elif config_type == "normal": import chess_zero.configs.normal as c else: raise RuntimeError(f"unknown config_type: {config_type}") self.play_data = c.PlayDataConfig() self.play = c.PlayConfig() self.eval = c.EvaluateConfig() self.human = c.PlayWithHumanConfig() self.trainer = c.TrainerConfig() self.model = c.ModelConfig() self.labels = create_uci_labels() self.n_labels = 4672 # 73x8x8. note: this is NOT (i.e. it's more than) the length of self.labels! only actually possible moves are entered as keys in self.labels.