mirror of
https://github.com/sockspls/badfish
synced 2025-04-29 16:23:09 +00:00
Further simplify stat bonuses
Based on recent simplification by linrock Since it completely removed any special bonuses based on values difference and made it flat stat_bonus(depth + 1) I got an idea that we might as well remove all (depth + 1) bonuses and make them usual depth bonuses. Also removes weird negative bonus for depth 1 as a side effect. Passed STC: https://tests.stockfishchess.org/tests/view/6689d817eca84f4d25863746 LLR: 2.94 (-2.94,2.94) <-1.75,0.25> Total: 18080 W: 4789 L: 4552 D: 8739 Ptnml(0-2): 46, 1987, 4727, 2244, 36 Passed LTC: https://tests.stockfishchess.org/tests/view/6689daa4eca84f4d258639d7 LLR: 2.95 (-2.94,2.94) <-1.75,0.25> Total: 109062 W: 27548 L: 27417 D: 54097 Ptnml(0-2): 58, 11983, 30293, 12164, 33 Passed direct LTC vs linrock patch: https://tests.stockfishchess.org/tests/view/668a46f8eca84f4d25866fe9 LLR: 2.95 (-2.94,2.94) <-1.75,0.25> Total: 100002 W: 25351 L: 25209 D: 49442 Ptnml(0-2): 54, 11119, 27529, 11229, 70 closes https://github.com/official-stockfish/Stockfish/pull/5461 Bench 1175744
This commit is contained in:
parent
5d3517c601
commit
eac2d080a3
1 changed files with 2 additions and 2 deletions
|
@ -86,7 +86,7 @@ Value to_corrected_static_eval(Value v, const Worker& w, const Position& pos) {
|
|||
}
|
||||
|
||||
// History and stats update bonus, based on depth
|
||||
int stat_bonus(Depth d) { return std::clamp(190 * d - 298, 20, 1596); }
|
||||
int stat_bonus(Depth d) { return std::min(190 * d - 108, 1596); }
|
||||
|
||||
// History and stats update malus, based on depth
|
||||
int stat_malus(Depth d) { return (d < 4 ? 736 * d - 268 : 2044); }
|
||||
|
@ -1782,7 +1782,7 @@ void update_all_stats(const Position& pos,
|
|||
Piece moved_piece = pos.moved_piece(bestMove);
|
||||
PieceType captured;
|
||||
|
||||
int quietMoveBonus = stat_bonus(depth + 1);
|
||||
int quietMoveBonus = stat_bonus(depth);
|
||||
int quietMoveMalus = stat_malus(depth);
|
||||
|
||||
if (!pos.capture_stage(bestMove))
|
||||
|
|
Loading…
Add table
Reference in a new issue