Skip to content

Commit

Permalink
Simplify evaluation scaling
Browse files Browse the repository at this point in the history
Set digits in adjusted eval params all to 7.

Passed non-regression STC:
https://tests.stockfishchess.org/tests/view/66fc493d86d5ee47d953b94c
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 57696 W: 15098 L: 14898 D: 27700
Ptnml(0-2): 205, 6784, 14678, 6968, 213

Passed non-regression LTC:
https://tests.stockfishchess.org/tests/view/66fd4b9386d5ee47d953b9d5
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 93786 W: 23868 L: 23721 D: 46197
Ptnml(0-2): 55, 10322, 25993, 10467, 56

closes #5618

Bench: 1277182
  • Loading branch information
linrock authored and Disservin committed Oct 12, 2024
1 parent 6592b13 commit e046c4e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/evaluate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,7 @@ Value Eval::evaluate(const Eval::NNUE::Networks& networks,

assert(!pos.checkers());

bool smallNet = use_smallnet(pos);
int v;

bool smallNet = use_smallnet(pos);
auto [psqt, positional] = smallNet ? networks.small.evaluate(pos, &caches.small)
: networks.big.evaluate(pos, &caches.big);

Expand All @@ -81,7 +79,7 @@ Value Eval::evaluate(const Eval::NNUE::Networks& networks,
nnue -= nnue * nnueComplexity / (smallNet ? 20233 : 17879);

int material = (smallNet ? 553 : 532) * pos.count<PAWN>() + pos.non_pawn_material();
v = (nnue * (76898 + material) + optimism * (8112 + material)) / (smallNet ? 74411 : 76256);
int v = (nnue * (77777 + material) + optimism * (7777 + material)) / 77777;

// Damp down the evaluation linearly when shuffling
v -= v * pos.rule50_count() / 212;
Expand Down

0 comments on commit e046c4e

Please sign in to comment.