mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-23 02:27:00 +08:00
Also dampen NNUE eval with 50 move rule
Move the existing dampening function last so that NNUE evaluations are
also handled as we approach the 50 move rule.
STC:
LLR: 2.95 (-2.94,2.94) {-0.50,1.50}
Total: 4792 W: 695 L: 561 D: 3536
Ptnml(0-2): 19, 420, 1422, 478, 57
https://tests.stockfishchess.org/tests/view/5f3164179081672066537534
LTC:
LLR: 8.62 (-2.94,2.94) {0.25,1.75}
Total: 286744 W: 18494 L: 17430 D: 250820
Ptnml(0-2): 418, 14886, 111745, 15860, 463
https://tests.stockfishchess.org/tests/view/5f316b039081672066537541
closes https://github.com/official-stockfish/Stockfish/pull/3004
Bench: 4001800
This commit is contained in:
committed by
Joost VandeVondele
parent
ce009ea1aa
commit
e5f450cf0b
@@ -927,9 +927,6 @@ make_v:
|
|||||||
// Side to move point of view
|
// Side to move point of view
|
||||||
v = (pos.side_to_move() == WHITE ? v : -v) + Tempo;
|
v = (pos.side_to_move() == WHITE ? v : -v) + Tempo;
|
||||||
|
|
||||||
// Damp down the evaluation linearly when shuffling
|
|
||||||
v = v * (100 - pos.rule50_count()) / 100;
|
|
||||||
|
|
||||||
return v;
|
return v;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -941,14 +938,15 @@ make_v:
|
|||||||
|
|
||||||
Value Eval::evaluate(const Position& pos) {
|
Value Eval::evaluate(const Position& pos) {
|
||||||
|
|
||||||
if (Eval::useNNUE)
|
bool classical = !Eval::useNNUE
|
||||||
{
|
|| abs(eg_value(pos.psq_score())) >= NNUEThreshold;
|
||||||
Value v = eg_value(pos.psq_score());
|
Value v = classical ? Evaluation<NO_TRACE>(pos).value()
|
||||||
// Take NNUE eval only on balanced positions
|
: NNUE::evaluate(pos) + Tempo;
|
||||||
if (abs(v) < NNUEThreshold)
|
|
||||||
return NNUE::evaluate(pos) + Tempo;
|
// Damp down the evaluation linearly when shuffling
|
||||||
}
|
v = v * (100 - pos.rule50_count()) / 100;
|
||||||
return Evaluation<NO_TRACE>(pos).value();
|
|
||||||
|
return v;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// trace() is like evaluate(), but instead of returning a value, it returns
|
/// trace() is like evaluate(), but instead of returning a value, it returns
|
||||||
|
|||||||
Reference in New Issue
Block a user