mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-23 02:27:00 +08:00
Simplify away complexity in evaluation
Simplification STC: https://tests.stockfishchess.org/tests/view/64394bc0605991a801b4f6f0 LLR: 2.95 (-2.94,2.94) <-1.75,0.25> Total: 72360 W: 19313 L: 19138 D: 33909 Ptnml(0-2): 206, 7883, 19800, 8112, 179 Simplification LTC: https://tests.stockfishchess.org/tests/view/6439e788c233ce943b6bdac1 LLR: 2.94 (-2.94,2.94) <-1.75,0.25> Total: 224992 W: 60665 L: 60654 D: 103673 Ptnml(0-2): 96, 21875, 68526, 21920, 79 closes https://github.com/official-stockfish/Stockfish/pull/4530 Bench: 3709369
This commit is contained in:
committed by
Joost VandeVondele
parent
f9d9c69bc3
commit
c90dd38903
@@ -1046,7 +1046,7 @@ make_v:
|
||||
/// evaluate() is the evaluator for the outer world. It returns a static
|
||||
/// evaluation of the position from the point of view of the side to move.
|
||||
|
||||
Value Eval::evaluate(const Position& pos, int* complexity) {
|
||||
Value Eval::evaluate(const Position& pos) {
|
||||
|
||||
assert(!pos.checkers());
|
||||
|
||||
@@ -1075,10 +1075,6 @@ Value Eval::evaluate(const Position& pos, int* complexity) {
|
||||
+ (424 + optimism) * abs(psq - nnue)
|
||||
) / 1024;
|
||||
|
||||
// Return hybrid NNUE complexity to caller
|
||||
if (complexity)
|
||||
*complexity = nnueComplexity;
|
||||
|
||||
optimism = optimism * (272 + nnueComplexity) / 256;
|
||||
v = (nnue * scale + optimism * (scale - 748)) / 1024;
|
||||
}
|
||||
@@ -1089,10 +1085,6 @@ Value Eval::evaluate(const Position& pos, int* complexity) {
|
||||
// Guarantee evaluation does not hit the tablebase range
|
||||
v = std::clamp(v, VALUE_TB_LOSS_IN_MAX_PLY + 1, VALUE_TB_WIN_IN_MAX_PLY - 1);
|
||||
|
||||
// When not using NNUE, return classical complexity to caller
|
||||
if (complexity && useClassical)
|
||||
*complexity = abs(v - psq);
|
||||
|
||||
return v;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user