Merge remote-tracking branch 'origin/main'
This commit is contained in:
@@ -9,7 +9,7 @@ _DIR = os.path.abspath(os.path.dirname(__file__))
|
||||
|
||||
|
||||
class Lc0Strategy(IStrategy):
|
||||
def __init__(self, path="../lc0/lc0", rollout_depth: int = 4,
|
||||
def __init__(self, path="lc0/lc0", rollout_depth: int = 4,
|
||||
limit: chess.engine.Limit = chess.engine.Limit(depth=4)):
|
||||
super().__init__(rollout_depth)
|
||||
self._lc0 = None
|
||||
@@ -35,5 +35,4 @@ class Lc0Strategy(IStrategy):
|
||||
|
||||
def analyze_board(self, board: chess.Board) -> int:
|
||||
score = score_lc0(board, self.lc0)
|
||||
print("lc0 score", score)
|
||||
return score
|
||||
|
||||
8
main.py
8
main.py
@@ -112,11 +112,11 @@ def read_arguments():
|
||||
strategies = {"Random": StrategyEnum.Random, "Stockfish": StrategyEnum.Stockfish, "Lc0": StrategyEnum.Lc0}
|
||||
|
||||
if os.name == 'nt':
|
||||
stockfish_default = "../stockfish/stockfish-windows-x86-64-avx2"
|
||||
lc0_default = "../lc0/lc0.exe"
|
||||
stockfish_default = "stockfish/stockfish-windows-x86-64-avx2"
|
||||
lc0_default = "lc0/lc0.exe"
|
||||
else:
|
||||
stockfish_default = "../stockfish/stockfish-ubuntu-x86-64-avx2"
|
||||
lc0_default = "../lc0/lc0"
|
||||
stockfish_default = "stockfish/stockfish-ubuntu-x86-64-avx2"
|
||||
lc0_default = "lc0/lc0"
|
||||
|
||||
parser.add_argument("--proc", default=2, help="Number of processors to use for simulation, default=1")
|
||||
parser.add_argument("--time", default=0.5, help="Time limit for each simulation step, default=0.5")
|
||||
|
||||
Reference in New Issue
Block a user