Skip to content

Commit 0fa957c

Browse files
Vizvezdeneclocutus2
authored andcommitted
Tweak opposite colord bishops endgame scaling.
Make scale factor dependant on asymmetry of pawn structure. STC http://tests.stockfishchess.org/tests/view/5b92a2a80ebc592cf2753dd4 LLR: 2.96 (-2.94,2.94) [0.00,5.00] Total: 31490 W: 6870 L: 6587 D: 18033 LTC http://tests.stockfishchess.org/tests/view/5b92f8170ebc592cf2754438 LLR: 2.95 (-2.94,2.94) [0.00,5.00] Total: 54928 W: 8988 L: 8653 D: 37287 This patch shows that SF can use some more complicated endgame heuristics to evaluate endgames better from the distance. Closes #1767 Bench: 4248710
1 parent 4bef7aa commit 0fa957c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/evaluate.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -795,9 +795,10 @@ namespace {
795795
if ( pos.opposite_bishops()
796796
&& pos.non_pawn_material(WHITE) == BishopValueMg
797797
&& pos.non_pawn_material(BLACK) == BishopValueMg)
798-
sf = 31;
798+
sf = 8 + 4 * pe->pawn_asymmetry();
799799
else
800800
sf = std::min(40 + (pos.opposite_bishops() ? 2 : 7) * pos.count<PAWN>(strongSide), sf);
801+
801802
}
802803

803804
return ScaleFactor(sf);

0 commit comments

Comments
 (0)