]> git.sesse.net Git - stockfish/commitdiff
Halve king eval margin
authorhomoSapiensSapiens <reuvenpe2005@gmail.com>
Tue, 16 Jul 2013 15:52:55 +0000 (18:52 +0300)
committerMarco Costalba <mcostalba@gmail.com>
Fri, 19 Jul 2013 06:16:39 +0000 (08:16 +0200)
But still keep the same original
margin for score.

Passed both short TC test
LR: 2.95 (-2.94,2.94)
Total: 3710 W: 845 L: 726 D: 2139

And long TC
LLR: 2.95 (-2.94,2.94)
Total: 57859 W: 10939 L: 10532 D: 36388

bench: 4769737

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
src/evaluate.cpp

index bb9a2f97c0f5b7fddbe3c5aec66eb20e8aab332a..207892f4dea1fce081a588dcbab770b8c3aab18e 100644 (file)
@@ -767,7 +767,7 @@ Value do_evaluate(const Position& pos, Value& margin) {
         // be very big, and so capturing a single attacking piece can therefore
         // result in a score change far bigger than the value of the captured piece.
         score -= KingDanger[Us == Search::RootColor][attackUnits];
-        margins[Us] += mg_value(KingDanger[Us == Search::RootColor][attackUnits]);
+        margins[Us] += mg_value(KingDanger[Us == Search::RootColor][attackUnits]) / 2;
     }
 
     if (Trace)