mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-24 02:57:11 +08:00
Clamp NNUE evaluation score
No functional change.
This commit is contained in:
@@ -152,7 +152,10 @@ namespace Eval::NNUE {
|
||||
|
||||
// Evaluation function. Perform differential calculation.
|
||||
Value evaluate(const Position& pos) {
|
||||
return ComputeScore(pos, false);
|
||||
Value v = ComputeScore(pos, false);
|
||||
v = Utility::clamp(v, VALUE_TB_LOSS_IN_MAX_PLY + 1, VALUE_TB_WIN_IN_MAX_PLY - 1);
|
||||
|
||||
return v;
|
||||
}
|
||||
|
||||
// Evaluation function. Perform full calculation.
|
||||
|
||||
Reference in New Issue
Block a user