Skip to content

Commit 9bf8767

Browse files
committed
Weights.
1 parent c5386f5 commit 9bf8767

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

py_v3/_eval.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@
2424
PERSONALITY = "normal"
2525

2626
if PERSONALITY == "normal":
27-
WEIGHTS = {"mat": 2, "center": 0.75, "pawn": 0.12, "pieceMap": 0.2}
27+
WEIGHTS = {"mat": 3, "center": 0.75, "pawn": 0.12, "pieceMap": 0.2}
2828
elif PERSONALITY == "attacking":
29-
WEIGHTS = {"mat": 2, "center": 0.65, "pawn": 0.1, "pieceMap": 0.21}
29+
WEIGHTS = {"mat": 3, "center": 0.65, "pawn": 0.1, "pieceMap": 0.21}
3030
elif PERSONALITY == "positional":
31-
WEIGHTS = {"mat": 2.1, "center": 0.6, "pawn": 0.09, "pieceMap": 0.19}
31+
WEIGHTS = {"mat": 3.2, "center": 0.6, "pawn": 0.09, "pieceMap": 0.19}
3232

3333

3434
def Eval(position: Board):
@@ -85,7 +85,7 @@ def Map(position, moveNum):
8585
else:
8686
points = 0
8787

88-
return points / 50
88+
return points / 75
8989

9090

9191
def Material(position: Board):
@@ -113,7 +113,7 @@ def CenterControl(position: Board):
113113
outer += len(position.attackers(chess.WHITE, getattr(chess, sq)))
114114
outer -= len(position.attackers(chess.BLACK, getattr(chess, sq)))
115115

116-
return (inner + outer/4) / 50
116+
return (inner + outer/4) / 75
117117

118118

119119
def PawnStruct(position: Board):
@@ -191,4 +191,4 @@ def PawnStruct(position: Board):
191191

192192
# Final
193193
score = 0.5*((4-whiteIslands)-(4-blackIslands)) + (whitePassed - blackPassed) - 0.1*(whiteStackScore-blackStackScore) + 5*(whiteAvgRank-blackAvgRank)
194-
return score / 10
194+
return score / 15

0 commit comments

Comments
 (0)