ddugovic / Stockfish

Retired multi-variant fork of popular UCI chess engine; please use Fairy-Stockfish instead
https://github.com/ianfab/Fairy-Stockfish
GNU General Public License v3.0
132 stars 44 forks source link

A ZH game with blunders from SF #490

Closed Vinvin20 closed 6 years ago

Vinvin20 commented 6 years ago

May be this game can help to improve SF-Zh. Especially 21...d5?? because of 22.P@d7!!

https://lichess.org/uZo8Zbgb

ddugovic commented 6 years ago

Yeah, I'm trying to change see_ge of position.cpp which looks really complicated & confusing and doesn't account for sequences of captures involving promoted pieces. Probably changing it would allow simplifying away (or reducing) other evalutation and/or search bonuses.

ianfab commented 6 years ago

Since pawn drops on the 7th rank are very dangerous, I submitted a test for a patch that handles pawn drops to the 7th rank as captures, the same way as it is done for promotions to queen. That might be a bit too much, but let's give it a try.

Edit: Wow, that failed quickly. Either there is a bug or there simply are far too many pawn drops on the 7th rank to justify such a privilege.

ddugovic commented 6 years ago

Hm, I wonder if changing the definition of Position::capture_or_promotion(Move) (consumed by search.cpp) to include such drops could similarly be useful.

ianfab commented 6 years ago

@ddugovic Yeah, that should be a less dramatic change then handling them as captures in move picking, but might achieve similar effects, so it sounds like a promising idea to me.

ddugovic commented 6 years ago

@ianfab OK, cool. Here goes nothing! http://35.161.250.236:6543/tests/view/5a53e9ac6e23db35f28bb1b0

Vinvin20 commented 6 years ago

3 more games with blunders from SF level 8 : https://lichess.org/KDH3s0im#45 https://lichess.org/gcwg4BT1/black#15 https://lichess.org/R4D1sDQN#40

ianfab commented 6 years ago

Some of the peaks in the analysis graph turn out to be caused by evaluation fluctuations, some are only slight mistakes after deeper analysis, and a few seem to be real blunders. However, I can not find a clear pattern in the mistakes apart from that Stockfish is maybe overplaying the positions instead of dropping pieces to strengthen its own camp.

One blunder turned out to really completely switch the evaluation from around +15 to -15 (from black's perpective) when analyzing deeper. But even there I find it hard to identify a reason for the blunder.

Nevertheless, I find this position very interesting to analyze, since it is really fascinating to see how black can make progress despite white's king looking realatively safe. 45... P@h2! is the winning move. The idea seems to be that if the bishop takes, it is deflected from f2, so black can continue with Bxf2+ which further opens up the king position. If the king takes (Kh1 leads to mate), black can play N@d2 with tempo (!) (either directly or after an intermediate move P@h4), because Nxf1+ is actually a mate threat. So (although there are a lot of side lines) P@h2+ essentially gains a tempo at the cost of only one pawn, which seems negligible in such a position with many pieces in hand.

The only idea for improving Stockfish I got from these analyses is that one could give a bonus to moves that threaten to give check on the next move (with non-negative SEE), but I am not entirely sure how and where to do that (move ordering, LMR, ...?).

ddugovic commented 6 years ago

Likewise I tried many move-ordering and SEE ideas recently and none of them worked.

ddugovic commented 6 years ago

The last few upstream commits (now merged) are quite interesting... "Simplify verification search" "Revert to old time management" "Use mobility in kingsafety"

Are these SF blunders reproducible offline with latest master?

ddugovic commented 6 years ago

Welp... P@d7 is just very difficult to find in this particular position and (having attempted 9 different patches in addition to those attempted by Fabian) there appears not to be a generic solution to discovering pawn-on-7th-rank threats.

Vinvin20 commented 6 years ago

Here, the key is probably : pawn on 7th is strong when the back-rank is weak and the player has a rook or a queen in hand.

ddugovic commented 6 years ago

@Vinvin20 I attempted to code a patch based on your idea, but it probably wasn't exactly what you had in mind: a3defd362c3265a7eec8ed4c605039df07df5ca9

Feel free to try coding a patch of your own too...

ddugovic commented 6 years ago

Thanks to simplification 5d57bb467a4d703f480c87f58687705e2f56e338 it's possible pawn-on-7th moves might be pruned less aggressively (or that some parameter tuning without changing logic might improve this).

ddugovic commented 6 years ago

With current master the move 21... Ng3 is quickly found to be winning; however, the following test finds but "mis-evaluates (as not completely winning)" 22. P@d7! after 30 seconds:

setoption name UCI_Variant value crazyhouse
position fen r5k1/p4ppp/3pp3/6qn/3PB3/4P1B1/PrP2PPP/R4RK1/PBQPBnpnn b - - 41 21
go movetime 30000 searchmoves d6d5

EDIT: I left Stockfish running for 13 hours and it wasn't finding a forced mate:

info depth 1 seldepth 1 multipv 1 score cp 77 nodes 561 nps 140250 tbhits 0 time 4 pv Q@c8 P@h2 g1h2 d5e4 c8a8 b2c2
info depth 2 seldepth 3 multipv 1 score cp 1202 nodes 816 nps 204000 tbhits 0 time 4 pv e4h7 g8h7
info depth 3 seldepth 4 multipv 1 score cp 1262 nodes 1099 nps 219800 tbhits 0 time 5 pv e4h7 g8h7 B@d3 g7g6 Q@h1 P@h2 h1h2 h7g7
info depth 4 seldepth 6 multipv 1 score cp 1262 nodes 1297 nps 259400 tbhits 0 time 5 pv e4h7 g8h7 B@d3 g7g6 Q@h1 P@h2 h1h2 h7g7
info depth 5 seldepth 8 multipv 1 score cp 1726 nodes 1618 nps 323600 tbhits 0 time 5 pv e4h7 g8h7 B@d3 g7g6 Q@h1 P@h2 h1h2 h7g7
info depth 6 seldepth 10 multipv 1 score cp 1806 nodes 3495 nps 388333 tbhits 0 time 9 pv e4h7 g8h7 B@d3 g7g6 Q@h1 P@h2 h1h2 h7g7 B@e5 g5e5 P@h6 g7f6 d4e5 f6e5
info depth 7 seldepth 12 multipv 1 score cp 662 nodes 10134 nps 405360 tbhits 0 time 25 pv e4h7 g8h7 B@d3 g7g6 B@e5 f8h6 N@e8 P@h2 g1h2
info depth 8 seldepth 12 multipv 1 score cp 265 nodes 23699 nps 370296 tbhits 0 time 64 pv e4d3 P@e4 B@h4 g5h4 g3h4 e4d3 N@e7 f8e7
info depth 9 seldepth 15 multipv 1 score cp 192 nodes 50663 nps 361878 tbhits 0 time 140 pv e4d3 P@e4 B@h4 N@h3 g1h1 e4d3 h4g5 h3g5 c2d3
info depth 10 seldepth 16 multipv 1 score cp 315 nodes 123760 nps 396666 tbhits 0 time 312 pv e4d3 N@e4 N@f3 g5h5 P@c7 N@g4 B@h4 e4f2 f1f2 P@h2 f3h2
info depth 11 seldepth 17 multipv 1 score cp 236 nodes 170764 nps 409505 tbhits 0 time 417 pv e4d3 N@e4 N@f3 g5h5 P@e7 N@g4 e7f8q a8f8 B@h4 P@h2 f3h2 g4h2
info depth 12 seldepth 23 multipv 1 score cp 112 nodes 654358 nps 476243 hashfull 324 tbhits 0 time 1374 pv Q@e8 d5e4 e8a8 B@d6 R@h3 b2b8 a8e4 N@f6 e4d3 P@b2 B@h4 b2a1r h4g5 a1f1 g1f1
info depth 13 seldepth 19 multipv 1 score cp 175 lowerbound nodes 1145320 nps 452695 hashfull 518 tbhits 0 time 2530 pv e4h7
info depth 13 seldepth 20 multipv 1 score cp 258 lowerbound nodes 1191554 nps 447784 hashfull 539 tbhits 0 time 2661 pv e4h7
info depth 13 seldepth 23 multipv 1 score cp 195 nodes 1251486 nps 443317 hashfull 561 tbhits 0 time 2823 pv e4h7 g8h7 Q@h2 P@h6 B@f4 g5e7 B@c5 B@f5 c5e7 f8e7 g1h1 b2c2 P@c7 B@e4
info depth 14 seldepth 19 multipv 1 score cp 188 upperbound nodes 1482863 nps 440672 hashfull 655 tbhits 0 time 3365 pv e4h7 g8h7
info depth 14 seldepth 21 multipv 1 score cp 180 upperbound nodes 1644809 nps 448543 hashfull 689 tbhits 0 time 3667 pv e4h7 g8h7
info depth 14 seldepth 22 multipv 1 score cp 188 lowerbound nodes 1745500 nps 456817 hashfull 721 tbhits 0 time 3821 pv e4h7
info depth 14 seldepth 22 multipv 1 score cp 204 lowerbound nodes 1773878 nps 459196 hashfull 724 tbhits 0 time 3863 pv e4h7
info depth 14 seldepth 22 multipv 1 score cp 225 lowerbound nodes 1808254 nps 462114 hashfull 728 tbhits 0 time 3913 pv e4h7
info depth 14 seldepth 22 multipv 1 score cp 169 upperbound nodes 1850069 nps 465894 hashfull 731 tbhits 0 time 3971 pv e4h7 g8h7
info depth 14 seldepth 27 multipv 1 score cp 212 lowerbound nodes 1905235 nps 470080 hashfull 746 tbhits 0 time 4053 pv e4h7
info depth 14 seldepth 27 multipv 1 score cp 262 lowerbound nodes 1971647 nps 474638 hashfull 755 tbhits 0 time 4154 pv e4h7
info depth 14 seldepth 27 multipv 1 score cp 280 nodes 2026912 nps 478835 hashfull 761 tbhits 0 time 4233 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7h8 P@c7 b2c2 d7d8r P@e2 B@h5 B@g8 h5e2 N@c3 d8a8 c3e2 g1h1
info depth 15 seldepth 24 multipv 1 score cp 287 lowerbound nodes 2372637 nps 479127 hashfull 827 tbhits 0 time 4952 pv e4h7
info depth 15 seldepth 24 multipv 1 score cp 295 lowerbound nodes 2406102 nps 478065 hashfull 830 tbhits 0 time 5033 pv e4h7
info depth 15 seldepth 24 multipv 1 score cp 306 lowerbound nodes 2448502 nps 476640 hashfull 836 tbhits 0 time 5137 pv e4h7
info depth 15 seldepth 24 multipv 1 score cp 322 lowerbound nodes 2492603 nps 477693 hashfull 842 tbhits 0 time 5218 pv e4h7
info depth 15 seldepth 24 multipv 1 score cp 343 lowerbound nodes 2551258 nps 481460 hashfull 846 tbhits 0 time 5299 pv e4h7
info depth 15 seldepth 24 multipv 1 score cp 372 lowerbound nodes 2638633 nps 486383 hashfull 856 tbhits 0 time 5425 pv e4h7
info depth 15 seldepth 24 multipv 1 score cp 389 nodes 2867174 nps 491038 hashfull 876 tbhits 0 time 5839 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5e7 B@h5 N@e4 P@g6 f7g6 h5g6 h7g6 B@g8 b2c2 N@e5 g6f6 P@c5 N@e2 g1h1
info depth 16 seldepth 30 multipv 1 score cp 381 upperbound nodes 3151065 nps 494828 hashfull 913 tbhits 0 time 6368 pv e4h7 g8h7
info depth 16 seldepth 30 multipv 1 score cp 374 upperbound nodes 3166419 nps 494443 hashfull 913 tbhits 0 time 6404 pv e4h7 g8h7
info depth 16 seldepth 30 multipv 1 score cp 362 upperbound nodes 3200885 nps 493202 hashfull 914 tbhits 0 time 6490 pv e4h7 g8h7
info depth 16 seldepth 30 multipv 1 score cp 372 lowerbound nodes 3413232 nps 490759 hashfull 930 tbhits 0 time 6955 pv e4h7
info depth 16 seldepth 30 multipv 1 score cp 393 lowerbound nodes 3613767 nps 490534 hashfull 933 tbhits 0 time 7367 pv e4h7
info depth 16 seldepth 30 multipv 1 score cp 360 nodes 3686664 nps 489336 hashfull 938 tbhits 0 time 7534 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5e7 B@h5 B@g6 h5g6 f7g6 B@f7 B@f5 N@e5 N@f6 B@e8 N@h8 f7g6 h8g6 e5g6 N@e2 g1h1 e7e8 d7e8q
info depth 17 seldepth 29 multipv 1 score cp 367 lowerbound nodes 4612504 nps 483136 hashfull 982 tbhits 0 time 9547 pv e4h7
info depth 17 seldepth 29 multipv 1 score cp 375 lowerbound nodes 4698004 nps 484280 hashfull 984 tbhits 0 time 9701 pv e4h7
info depth 17 seldepth 29 multipv 1 score cp 386 lowerbound nodes 4861557 nps 487227 hashfull 987 tbhits 0 time 9978 pv e4h7
info depth 17 seldepth 29 multipv 1 score cp 402 lowerbound nodes 4996778 nps 490072 hashfull 987 tbhits 0 time 10196 pv e4h7
info depth 17 seldepth 29 multipv 1 score cp 423 lowerbound nodes 5234581 nps 489167 hashfull 992 tbhits 0 time 10701 pv e4h7
info depth 17 seldepth 29 multipv 1 score cp 452 lowerbound nodes 5558117 nps 482852 hashfull 995 tbhits 0 time 11511 pv e4h7
info depth 17 seldepth 29 multipv 1 score cp 352 upperbound nodes 5892430 nps 483382 hashfull 997 tbhits 0 time 12190 pv e4h7 g8h7
info depth 17 seldepth 29 multipv 1 score cp 421 lowerbound nodes 6186727 nps 480970 hashfull 997 tbhits 0 time 12863 pv e4h7
info depth 17 seldepth 34 multipv 1 score cp 486 lowerbound nodes 7177331 nps 488652 hashfull 999 tbhits 0 time 14688 pv e4h7
info depth 17 seldepth 34 multipv 1 score cp 410 nodes 7498973 nps 492834 hashfull 999 tbhits 0 time 15216 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7h8 P@c7 N@g4 c7c8q N@e4 B@e2 g4h2 c8a8 Q@g8 g1h2 e4g5 B@d3 B@e4 f4g5 e4d3
info depth 18 seldepth 30 multipv 1 score cp 402 upperbound nodes 8857651 nps 504508 hashfull 999 tbhits 0 time 17557 pv e4h7 g8h7
info depth 18 seldepth 30 multipv 1 score cp 410 lowerbound nodes 9505119 nps 507670 hashfull 999 tbhits 0 time 18723 pv e4h7
info depth 18 seldepth 30 multipv 1 score cp 421 lowerbound nodes 9804985 nps 509217 hashfull 999 tbhits 0 time 19255 pv e4h7
info depth 18 seldepth 30 multipv 1 score cp 437 lowerbound nodes 9999365 nps 507633 hashfull 999 tbhits 0 time 19698 pv e4h7
info depth 18 seldepth 30 multipv 1 score cp 459 lowerbound nodes 10192547 nps 508179 hashfull 999 tbhits 0 time 20057 pv e4h7
info depth 18 seldepth 30 multipv 1 score cp 488 lowerbound nodes 10867908 nps 510854 hashfull 999 tbhits 0 time 21274 pv e4h7
info depth 18 seldepth 30 multipv 1 score cp 526 lowerbound nodes 12513305 nps 511686 hashfull 999 tbhits 0 time 24455 pv e4h7
info depth 18 seldepth 30 multipv 1 score cp 511 nodes 12671208 nps 511616 hashfull 999 tbhits 0 time 24767 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7h8 P@c7 N@g4 c7c8q N@e2 g1h1 g4h2 c8a8 B@b8 d7d8q Q@g8 a8b8 b2b8 d8b8 h2f1 a1f1 R@h5 R@h3 h5h3 g5h3 N@g4 N@f3
info depth 19 seldepth 35 multipv 1 score cp 504 upperbound nodes 13331699 nps 508397 hashfull 999 tbhits 0 time 26223 pv e4h7 g8h7
info depth 19 seldepth 35 multipv 1 score cp 496 upperbound nodes 13484122 nps 506769 hashfull 999 tbhits 0 time 26608 pv e4h7 g8h7
info depth 19 seldepth 35 multipv 1 score cp 485 upperbound nodes 13722744 nps 506411 hashfull 999 tbhits 0 time 27098 pv e4h7 g8h7
info depth 19 seldepth 35 multipv 1 score cp 469 upperbound nodes 13853629 nps 507551 hashfull 999 tbhits 0 time 27295 pv e4h7 g8h7
info depth 19 seldepth 35 multipv 1 score cp 447 upperbound nodes 13999954 nps 508626 hashfull 999 tbhits 0 time 27525 pv e4h7 g8h7
info depth 19 seldepth 35 multipv 1 score cp 418 upperbound nodes 14157253 nps 509638 hashfull 999 tbhits 0 time 27779 pv e4h7 g8h7
info depth 19 seldepth 35 multipv 1 score cp 441 lowerbound nodes 15292268 nps 508285 hashfull 999 tbhits 0 time 30086 pv e4h7
info depth 19 seldepth 35 multipv 1 score cp 491 lowerbound nodes 16390418 nps 508703 hashfull 999 tbhits 0 time 32220 pv e4h7
info depth 19 seldepth 35 multipv 1 score cp 525 nodes 17671567 nps 507409 hashfull 999 tbhits 0 time 34827 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7h8 P@c7 N@e4 c7c8r N@g4 B@e2 g4h2 c8a8 B@e7 g1h2 e4g5 a8f8 e7f8 B@g4 f5h7 R@c8 Q@g8
info depth 20 seldepth 24 multipv 1 score cp 517 upperbound nodes 18224498 nps 507335 hashfull 999 tbhits 0 time 35922 pv e4h7 g8h7
info depth 20 seldepth 33 multipv 1 score cp 510 upperbound nodes 18706736 nps 504211 hashfull 999 tbhits 0 time 37101 pv e4h7 g8h7
info depth 20 seldepth 34 multipv 1 score cp 498 upperbound nodes 18879619 nps 503523 hashfull 999 tbhits 0 time 37495 pv e4h7 g8h7
info depth 20 seldepth 34 multipv 1 score cp 482 upperbound nodes 20117142 nps 502075 hashfull 999 tbhits 0 time 40068 pv e4h7 g8h7
info depth 20 seldepth 34 multipv 1 score cp 495 lowerbound nodes 21574836 nps 497781 hashfull 999 tbhits 0 time 43342 pv e4h7
info depth 20 seldepth 34 multipv 1 score cp 524 lowerbound nodes 23429577 nps 495633 hashfull 999 tbhits 0 time 47272 pv e4h7
info depth 20 seldepth 34 multipv 1 score cp 503 nodes 24619275 nps 490736 hashfull 999 tbhits 0 time 50168 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5e7 B@h5 B@g6 h5g6 f7g6 B@f7 B@f5 N@e5 N@f6 B@e8 N@h8 f7g6 f5g6 e5g6 h8g6 e8g6 h7g6 P@e5 f6g4 B@d3 B@e4
info depth 21 seldepth 38 multipv 1 score cp 510 lowerbound nodes 32789662 nps 488275 hashfull 999 tbhits 0 time 67154 pv e4h7
info depth 21 seldepth 38 multipv 1 score cp 518 lowerbound nodes 34498446 nps 486160 hashfull 999 tbhits 0 time 70961 pv e4h7
info depth 21 seldepth 38 multipv 1 score cp 529 lowerbound nodes 36769249 nps 487216 hashfull 999 tbhits 0 time 75468 pv e4h7
info depth 21 seldepth 38 multipv 1 score cp 545 lowerbound nodes 41101720 nps 486537 hashfull 999 tbhits 0 time 84478 pv e4h7
info depth 21 seldepth 38 multipv 1 score cp 495 upperbound nodes 43420355 nps 486557 hashfull 999 tbhits 0 time 89240 pv e4h7 g8h7
info depth 21 seldepth 43 multipv 1 score cp 531 lowerbound nodes 46888913 nps 490269 hashfull 999 tbhits 0 time 95639 pv e4h7
info depth 21 seldepth 43 multipv 1 score cp 466 upperbound nodes 47604495 nps 488867 hashfull 999 tbhits 0 time 97377 pv e4h7 g8h7
info depth 21 seldepth 43 multipv 1 score cp 517 lowerbound nodes 48938467 nps 487794 hashfull 999 tbhits 0 time 100326 pv e4h7
info depth 21 seldepth 43 multipv 1 score cp 510 nodes 49318447 nps 488257 hashfull 999 tbhits 0 time 101009 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7g8 P@c7 h6g5 d7d8r N@h3 g1h1 N@e4 g2h3 B@f3 N@g2 N@g6 d8a8 b2c2 B@d3 c2c7 B@g4 P@b2 a1e1 P@d2 g4f3 d2e1q g2e1 g5f4 B@g4 f4g3 g4f5
info depth 22 seldepth 45 multipv 1 score cp 517 lowerbound nodes 60687324 nps 484606 hashfull 999 tbhits 0 time 125230 pv e4h7
info depth 22 seldepth 45 multipv 1 score cp 525 lowerbound nodes 63027663 nps 483415 hashfull 999 tbhits 0 time 130380 pv e4h7
info depth 22 seldepth 45 multipv 1 score cp 536 lowerbound nodes 65761052 nps 482398 hashfull 999 tbhits 0 time 136321 pv e4h7
info depth 22 seldepth 45 multipv 1 score cp 552 lowerbound nodes 69255008 nps 481248 hashfull 999 tbhits 0 time 143907 pv e4h7
info depth 22 seldepth 45 multipv 1 score cp 574 lowerbound nodes 73304226 nps 480702 hashfull 999 tbhits 0 time 152494 pv e4h7
info depth 22 seldepth 45 multipv 1 score cp 603 lowerbound nodes 81049739 nps 482490 hashfull 999 tbhits 0 time 167982 pv e4h7
info depth 22 seldepth 45 multipv 1 score cp 641 lowerbound nodes 90458284 nps 485314 hashfull 999 tbhits 0 time 186391 pv e4h7
info depth 22 seldepth 45 multipv 1 score cp 581 nodes 97027357 nps 486074 hashfull 999 tbhits 0 time 199614 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5e7 B@h5 B@g6 h5g6 f7g6 B@f7 B@e4 B@e8 h7h8 f7g6 e7d7 g6e4 d7e8 N@g6 e8g6 e4g6 N@f6 P@g5 B@e4 g5h6 g7h6 Q@f7
info depth 23 seldepth 34 multipv 1 score cp 588 lowerbound nodes 114739070 nps 485232 hashfull 999 tbhits 0 time 236462 pv e4h7
info depth 23 seldepth 34 multipv 1 score cp 596 lowerbound nodes 121684040 nps 482865 hashfull 999 tbhits 0 time 252004 pv e4h7
info depth 23 seldepth 34 multipv 1 score cp 607 lowerbound nodes 127383774 nps 485055 hashfull 999 tbhits 0 time 262617 pv e4h7
info depth 23 seldepth 34 multipv 1 score cp 623 lowerbound nodes 133879073 nps 484262 hashfull 999 tbhits 0 time 276460 pv e4h7
info depth 23 seldepth 34 multipv 1 score cp 645 lowerbound nodes 141765085 nps 483004 hashfull 999 tbhits 0 time 293507 pv e4h7
info depth 23 seldepth 39 multipv 1 score cp 674 lowerbound nodes 153987273 nps 482148 hashfull 999 tbhits 0 time 319377 pv e4h7
info depth 23 seldepth 45 multipv 1 score cp 573 upperbound nodes 163019065 nps 481653 hashfull 999 tbhits 0 time 338457 pv e4h7 g8h7
info depth 23 seldepth 45 multipv 1 score cp 642 lowerbound nodes 168960554 nps 481955 hashfull 999 tbhits 0 time 350573 pv e4h7
info depth 23 seldepth 45 multipv 1 score cp 707 lowerbound nodes 187430754 nps 481677 hashfull 999 tbhits 0 time 389121 pv e4h7
info depth 23 seldepth 45 multipv 1 score cp 648 nodes 191330622 nps 481320 hashfull 999 tbhits 0 time 397512 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7h8 B@h7 B@g6 B@d3 N@e2 d3e2 g6h7 P@c7 B@d8 c7d8q a8d8 g5h7 f8d6 N@e8 d8d7 e8d6 d7d6 B@a3 f5c2 a3d6 c2e2 R@c8 h8h7
info depth 24 seldepth 36 multipv 1 score cp 655 lowerbound nodes 241594768 nps 488210 hashfull 999 tbhits 0 time 494858 pv e4h7
info depth 24 seldepth 36 multipv 1 score cp 663 lowerbound nodes 251036918 nps 488475 hashfull 999 tbhits 0 time 513919 pv e4h7
info depth 24 seldepth 36 multipv 1 score cp 674 lowerbound nodes 263564257 nps 487589 hashfull 999 tbhits 0 time 540545 pv e4h7
info depth 24 seldepth 36 multipv 1 score cp 690 lowerbound nodes 276229850 nps 488886 hashfull 999 tbhits 0 time 565018 pv e4h7
info depth 24 seldepth 41 multipv 1 score cp 712 lowerbound nodes 293517909 nps 489669 hashfull 999 tbhits 0 time 599420 pv e4h7
info depth 24 seldepth 41 multipv 1 score cp 741 lowerbound nodes 323260989 nps 490330 hashfull 999 tbhits 0 time 659271 pv e4h7
info depth 24 seldepth 41 multipv 1 score cp 692 nodes 344513675 nps 489246 hashfull 999 tbhits 0 time 704172 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7g8 P@g6 N@f6 g5f7 f5g6 f7e5 B@h5 e5g6 h5g6 Q@c6 N@b7 P@c7 b2b6 c6b6 a7b6 c7c8r P@e2 B@b4 e2f1q a1f1 N@e2 g1h1 f6d7
info depth 25 seldepth 33 multipv 1 score cp 700 lowerbound nodes 379939564 nps 490393 hashfull 999 tbhits 0 time 774765 pv e4h7
info depth 25 seldepth 33 multipv 1 score cp 707 lowerbound nodes 399369075 nps 491234 hashfull 999 tbhits 0 time 812990 pv e4h7
info depth 25 seldepth 42 multipv 1 score cp 718 lowerbound nodes 418081485 nps 490928 hashfull 999 tbhits 0 time 851614 pv e4h7
info depth 25 seldepth 42 multipv 1 score cp 734 lowerbound nodes 444555557 nps 491256 hashfull 999 tbhits 0 time 904936 pv e4h7
info depth 25 seldepth 42 multipv 1 score cp 756 lowerbound nodes 483678819 nps 490872 hashfull 999 tbhits 0 time 985346 pv e4h7
info depth 25 seldepth 42 multipv 1 score cp 685 upperbound nodes 495809627 nps 490195 hashfull 999 tbhits 0 time 1011452 pv e4h7 g8h7
info depth 25 seldepth 43 multipv 1 score cp 735 lowerbound nodes 510253893 nps 490868 hashfull 999 tbhits 0 time 1039493 pv e4h7
info depth 25 seldepth 48 multipv 1 score cp 785 lowerbound nodes 565685361 nps 491107 hashfull 999 tbhits 0 time 1151857 pv e4h7
info depth 25 seldepth 49 multipv 1 score cp 727 nodes 598521021 nps 490888 hashfull 999 tbhits 0 time 1219260 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7g8 P@g6 N@f6 g5f7 f5g6 f7e5 B@h5 e5g6 h5g6 Q@c6 N@b7 P@c7 b2b6 c6b6 a7b6 R@c8 N@e2 g1h1 a8c8 d7c8q Q@e7 c8b7 R@h5 c7c8q
info depth 26 seldepth 33 multipv 1 score cp 735 lowerbound nodes 685028753 nps 492029 hashfull 999 tbhits 0 time 1392252 pv e4h7
info depth 26 seldepth 37 multipv 1 score cp 742 lowerbound nodes 712157143 nps 492278 hashfull 999 tbhits 0 time 1446654 pv e4h7
info depth 26 seldepth 37 multipv 1 score cp 754 lowerbound nodes 739887666 nps 492668 hashfull 999 tbhits 0 time 1501795 pv e4h7
info depth 26 seldepth 37 multipv 1 score cp 770 lowerbound nodes 767078101 nps 492537 hashfull 999 tbhits 0 time 1557400 pv e4h7
info depth 26 seldepth 41 multipv 1 score cp 720 upperbound nodes 795369740 nps 492705 hashfull 999 tbhits 0 time 1614290 pv e4h7 g8h7
info depth 26 seldepth 41 multipv 1 score cp 755 lowerbound nodes 808125112 nps 493135 hashfull 999 tbhits 0 time 1638750 pv e4h7
info depth 26 seldepth 41 multipv 1 score cp 794 lowerbound nodes 891815622 nps 494236 hashfull 999 tbhits 0 time 1804430 pv e4h7
info depth 26 seldepth 47 multipv 1 score cp 844 lowerbound nodes 1030618969 nps 504088 hashfull 999 tbhits 0 time 2044521 pv e4h7
info depth 26 seldepth 47 multipv 1 score cp 806 nodes 1064293337 nps 505459 hashfull 999 tbhits 0 time 2105597 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5e7 B@h5 B@f5 N@g5 h7g8 h5f7 g8h8 B@g6 e7d7 g6f5 e6f5 B@e6 d7e7 e6f5 B@e4 f5e4 d5e4 B@f5 B@b5 P@e2 b5e2 f1e1 e2b5 P@b7 a8b8 f7b3 e7b7 f5e4
info depth 27 seldepth 44 multipv 1 score cp 814 lowerbound nodes 1346774925 nps 516998 hashfull 999 tbhits 0 time 2604986 pv e4h7
info depth 27 seldepth 44 multipv 1 score cp 821 lowerbound nodes 1415375337 nps 519575 hashfull 999 tbhits 0 time 2724097 pv e4h7
info depth 27 seldepth 44 multipv 1 score cp 799 upperbound nodes 1445076649 nps 520348 hashfull 999 tbhits 0 time 2777130 pv e4h7 g8h7
info depth 27 seldepth 51 multipv 1 score cp 815 lowerbound nodes 1490485121 nps 522038 hashfull 999 tbhits 0 time 2855127 pv e4h7
info depth 27 seldepth 51 multipv 1 score cp 837 lowerbound nodes 1611154973 nps 525452 hashfull 999 tbhits 0 time 3066226 pv e4h7
info depth 27 seldepth 51 multipv 1 score cp 838 nodes 1709687061 nps 527620 hashfull 999 tbhits 0 time 3240374 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5e7 B@h5 B@g6 h5g6 f7g6 B@f7 B@e4 B@e8 N@d2 f7g6 e4g6 e8g6 h7g6 N@e5 g6h7 B@g6 h7h8 P@c7 B@g8 P@f7 B@h7 f7g8q h7g8 g6d3 P@h7 c7c8q N@g4 e5g4 N@f3 g2f3 d2f3 g1g2 f3h2 g4h2 P@h3 g2h3
info depth 28 seldepth 48 multipv 1 score cp 845 lowerbound nodes 2100505169 nps 535593 hashfull 999 tbhits 0 time 3921829 pv e4h7
info depth 28 seldepth 48 multipv 1 score cp 830 upperbound nodes 2229527614 nps 537788 hashfull 999 tbhits 0 time 4145733 pv e4h7 g8h7
info depth 28 seldepth 48 multipv 1 score cp 819 upperbound nodes 2270833996 nps 538596 hashfull 999 tbhits 0 time 4216207 pv e4h7 g8h7
info depth 28 seldepth 48 multipv 1 score cp 830 lowerbound nodes 2291848528 nps 538961 hashfull 999 tbhits 0 time 4252344 pv e4h7
info depth 28 seldepth 48 multipv 1 score cp 852 lowerbound nodes 2479122008 nps 541675 hashfull 999 tbhits 0 time 4576768 pv e4h7
info depth 28 seldepth 48 multipv 1 score cp 881 lowerbound nodes 2799939729 nps 544653 hashfull 999 tbhits 0 time 5140768 pv e4h7
info depth 28 seldepth 48 multipv 1 score cp 803 upperbound nodes 2976185598 nps 545672 hashfull 999 tbhits 0 time 5454164 pv e4h7 g8h7
info depth 28 seldepth 48 multipv 1 score cp 861 lowerbound nodes 3020825931 nps 546023 hashfull 999 tbhits 0 time 5532412 pv e4h7
info depth 28 seldepth 55 multipv 1 score cp 753 upperbound nodes 3046106751 nps 546330 hashfull 999 tbhits 0 time 5575573 pv e4h7 g8h7
info depth 28 seldepth 55 multipv 1 score cp 840 lowerbound nodes 3079695496 nps 546576 hashfull 999 tbhits 0 time 5634516 pv e4h7
info depth 28 seldepth 55 multipv 1 score cp 945 lowerbound nodes 3781126066 nps 550233 hashfull 999 tbhits 0 time 6871854 pv e4h7
info depth 28 seldepth 55 multipv 1 score cp 805 nodes 4068609799 nps 551024 hashfull 999 tbhits 0 time 7383713 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7h8 B@h7 f5h7 g5f7 h8g8 d7d8r a8d8 f7d8 B@g6 d8e6 B@e7 e6f8 e7f8 R@d8 N@c6 B@e6 P@f7 P@c7 N@e7 B@a3 N@e2 g1h1 f7e6 a3b2 N@e8 P@d6 e7f5 P@d7 c6d8 c7d8q e8d6
info depth 29 seldepth 35 multipv 1 score cp 812 lowerbound nodes 4403188754 nps 553516 hashfull 999 tbhits 0 time 7954936 pv e4h7
info depth 29 seldepth 39 multipv 1 score cp 820 lowerbound nodes 4575553016 nps 554520 hashfull 999 tbhits 0 time 8251370 pv e4h7
info depth 29 seldepth 44 multipv 1 score cp 831 lowerbound nodes 4677770565 nps 555209 hashfull 999 tbhits 0 time 8425228 pv e4h7
info depth 29 seldepth 44 multipv 1 score cp 847 lowerbound nodes 4879866584 nps 556127 hashfull 999 tbhits 0 time 8774732 pv e4h7
info depth 29 seldepth 44 multipv 1 score cp 868 lowerbound nodes 5055283276 nps 556933 hashfull 999 tbhits 0 time 9077002 pv e4h7
info depth 29 seldepth 44 multipv 1 score cp 897 lowerbound nodes 5353359457 nps 556732 hashfull 999 tbhits 0 time 9615679 pv e4h7
info depth 29 seldepth 45 multipv 1 score cp 936 lowerbound nodes 5687048291 nps 557760 hashfull 999 tbhits 0 time 10196225 pv e4h7
info depth 29 seldepth 54 multipv 1 score cp 986 lowerbound nodes 6517190021 nps 559526 hashfull 999 tbhits 0 time 11647693 pv e4h7
info depth 29 seldepth 54 multipv 1 score cp 1007 nodes 7953538155 nps 560501 hashfull 999 tbhits 0 time 14190050 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5e7 B@h5 B@e4 N@g5 h7g8 h5f7 g8h8 f7e6 N@e2 g1h1 e4g2 h2g2 h6g5 B@f5 g5f4 B@d3 P@f7 d3e2 f4g3 f2g3 P@h7 e6d5 N@h6 N@e5 N@d2 f1f2 P@f3 e2f3 d2f3 f2f3 h6f5 f3f5
info depth 30 seldepth 48 multipv 1 score cp 1000 upperbound nodes 10341395506 nps 563186 hashfull 999 tbhits 0 time 18362279 pv e4h7 g8h7
info depth 30 seldepth 48 multipv 1 score cp 992 upperbound nodes 10464383120 nps 563017 hashfull 999 tbhits 0 time 18586245 pv e4h7 g8h7
info depth 30 seldepth 48 multipv 1 score cp 981 upperbound nodes 10541167458 nps 563021 hashfull 999 tbhits 0 time 18722482 pv e4h7 g8h7
info depth 30 seldepth 51 multipv 1 score cp 990 lowerbound nodes 11133412169 nps 563147 hashfull 999 tbhits 0 time 19769965 pv e4h7
info depth 30 seldepth 51 multipv 1 score cp 1012 lowerbound nodes 11442090392 nps 563884 hashfull 999 tbhits 0 time 20291552 pv e4h7
info depth 30 seldepth 51 multipv 1 score cp 1041 lowerbound nodes 12939616267 nps 564746 hashfull 999 tbhits 0 time 22912250 pv e4h7
info depth 30 seldepth 51 multipv 1 score cp 965 upperbound nodes 13457705230 nps 564876 hashfull 999 tbhits 0 time 23824167 pv e4h7 g8h7
info depth 30 seldepth 51 multipv 1 score cp 1022 lowerbound nodes 13812309158 nps 565230 hashfull 999 tbhits 0 time 24436607 pv e4h7
info depth 30 seldepth 54 multipv 1 score cp 915 upperbound nodes 14029092070 nps 565145 hashfull 999 tbhits 0 time 24823845 pv e4h7 g8h7
info depth 30 seldepth 54 multipv 1 score cp 1001 lowerbound nodes 14191791193 nps 565387 hashfull 999 tbhits 0 time 25101004 pv e4h7
info depth 30 seldepth 59 multipv 1 score cp 832 upperbound nodes 15606493085 nps 564847 hashfull 999 tbhits 0 time 27629546 pv e4h7 g8h7
info depth 30 seldepth 62 multipv 1 score cp 969 lowerbound nodes 15860980597 nps 563009 hashfull 999 tbhits 0 time 28171794 pv e4h7
info depth 30 seldepth 63 multipv 1 score cp 1097 nodes 19620470224 nps 545728 hashfull 999 tbhits 0 time 35952823 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5e7 B@h5 B@g6 h5g6 f7g6 B@f7 B@f5 B@e8 f5c2 f7g6 c2g6 e8g6 h7g6 N@e5 g6h7 P@g6 h7h8 B@a3 P@d6 e5f7 e7f7 g6f7 N@e2 g1h1 B@h7 a3b2 B@c6 R@g8 h7g8 f7g8q h8g8 P@f7 g8f7 B@e8 a8e8 h2h5 P@g6 d7e8q c6e8 h5e2 R@h3 g2h3
info depth 31 seldepth 43 multipv 1 score cp 1089 upperbound nodes 20150809156 nps 543669 hashfull 999 tbhits 0 time 37064415 pv e4h7 g8h7
info depth 31 seldepth 43 multipv 1 score cp 1082 upperbound nodes 20173174394 nps 543620 hashfull 999 tbhits 0 time 37108951 pv e4h7 g8h7
info depth 31 seldepth 43 multipv 1 score cp 1070 upperbound nodes 20339942275 nps 543351 hashfull 999 tbhits 0 time 37434227 pv e4h7 g8h7
info depth 31 seldepth 44 multipv 1 score cp 1080 lowerbound nodes 20930921293 nps 543088 hashfull 999 tbhits 0 time 38540568 pv e4h7
info depth 31 seldepth 56 multipv 1 score cp 1101 lowerbound nodes 23825584596 nps 537802 hashfull 999 tbhits 0 time 44301709 pv e4h7
info depth 31 seldepth 56 multipv 1 score cp 1055 upperbound nodes 23918308965 nps 537743 hashfull 999 tbhits 0 time 44479035 pv e4h7 g8h7
info depth 31 seldepth 56 multipv 1 score cp 1016 upperbound nodes 25014861842 nps 536141 hashfull 999 tbhits 0 time 46657171 pv e4h7 g8h7
info depth 31 seldepth 56 multipv 1 score cp 1054 lowerbound nodes 25518962386 nps 535659 hashfull 999 tbhits 0 time 47640267 pv e4h7
info depth 31 seldepth 56 multipv 1 score cp 966 upperbound nodes 26103537069 nps 535649 hashfull 999 tbhits 0 time 48732530 pv e4h7 g8h7
info depth 31 seldepth 56 multipv 1 score cp 1042 lowerbound nodes 26473787612 nps 535716 hashfull 999 tbhits 0 time 49417563 pv e4h7
ddugovic commented 6 years ago

Probably people should submit crazyhouse parameter-tweaking patches (possibly using SPSA to tune first) since those patches are easy (but tedious) to create and would address more than this one position.

ianfab commented 6 years ago

@ddugovic Could you please outline why 22. Q@c6 is a good move after 21...d5? I do not understand how it is winning and Stockfish can not not show me either, since it claims that Q@c6 is losing.

Well, I think finding those people is the issue, not finding suitable ways for them to contribute.

ddugovic commented 6 years ago

@ianfab My mistake, Stockfish does find 22. P@d7! (not Q@c6). I got confused re-reading the original issue after having some difficulty reproducing it.

Here is what I observed (when I force Stockfish to evaluate 22... d5?? instead of allowing it to search where it quickly finds 22... Nxg3 or something like that, I forget):

info depth 19 seldepth 32 multipv 1 score cp 89 upperbound nodes 12231148 nps 558270 hashfull 999 tbhits 0 time 21909 pv d6d5 P@d7
info depth 19 seldepth 32 multipv 1 score cp 81 upperbound nodes 12247883 nps 558448 hashfull 999 tbhits 0 time 21932 pv d6d5 P@d7
info depth 19 seldepth 33 multipv 1 score cp 70 upperbound nodes 12648175 nps 560596 hashfull 999 tbhits 0 time 22562 pv d6d5 P@d7
info depth 19 seldepth 33 multipv 1 score cp 54 upperbound nodes 12797277 nps 561555 hashfull 999 tbhits 0 time 22789 pv d6d5 P@d7
info depth 19 seldepth 33 multipv 1 score cp 32 upperbound nodes 12900865 nps 562349 hashfull 999 tbhits 0 time 22941 pv d6d5 P@d7
info depth 19 seldepth 33 multipv 1 score cp 3 upperbound nodes 13061515 nps 562366 hashfull 999 tbhits 0 time 23226 pv d6d5 P@d7
info depth 19 seldepth 35 multipv 1 score cp -34 upperbound nodes 13366682 nps 560988 hashfull 999 tbhits 0 time 23827 pv d6d5 P@d7
info depth 19 seldepth 35 multipv 1 score cp -3 lowerbound nodes 13818295 nps 560579 hashfull 999 tbhits 0 time 24650 pv d6d5
info depth 19 seldepth 35 multipv 1 score cp -84 upperbound nodes 14032912 nps 559213 hashfull 999 tbhits 0 time 25094 pv d6d5 P@d7
info depth 19 seldepth 44 multipv 1 score cp -11 lowerbound nodes 14137678 nps 559642 hashfull 999 tbhits 0 time 25262 pv d6d5
info depth 19 seldepth 44 multipv 1 score cp 93 lowerbound nodes 15231245 nps 559560 hashfull 999 tbhits 0 time 27220 pv d6d5
info depth 19 seldepth 44 multipv 1 score cp 93 nodes 16799946 nps 559699 hashfull 999 tbhits 0 time 30016 pv d6d5
bestmove d6d5 ponder P@d7
ianfab commented 6 years ago

@ddugovic 22. P@d7 does not seem convincing either. It was of course not me who found this, but Stockfish quickly discovered the crushing 22. P@d7? N@h3! 23. Kh1 Qxg3!!, and after some analysis I am quite convinced that it is right.

ddugovic commented 6 years ago

@ianfab Thanks, that makes sense.

It sounds as if possibly I've been "on a wild goose chase," but also the original issue(s) are no longer reproducible?

ianfab commented 6 years ago

@ddugovic Ah, I did not notice that P@d7 was the originally suggested "refutation". That SF incrementally finds refutations with increasing thinking time is a good sign, in contrast to being completely blind for certain moves like in the past. The position is very interesting since it seems like neither side has a forced mate (at least not in something like <15 moves), but still both sides have strong attacks with many (mate) threats. However, I do not see an obvious move SF misses in this position, so it might not help that much for getting concrete ideas for improvements.

ddugovic commented 6 years ago

@ianfab I agree.

Curiously 1171835ee7541404895940c812cf7e067766e184 increases nps by about 5% (analyzing the position after 22. P@d7 Nxg3? 23. hxg3 B@f8 where 24. Bxh7+! must be winning):

info depth 23 seldepth 39 multipv 1 score cp 697 lowerbound nodes 180811490 nps 506449 hashfull 999 tbhits 0 time 357018 pv e4h7
info depth 23 seldepth 39 multipv 1 score cp 719 lowerbound nodes 201287087 nps 504120 hashfull 999 tbhits 0 time 399284 pv e4h7

versus the earlier:

info depth 23 seldepth 45 multipv 1 score cp 707 lowerbound nodes 187430754 nps 481677 hashfull 999 tbhits 0 time 389121 pv e4h7
info depth 23 seldepth 45 multipv 1 score cp 648 nodes 191330622 nps 481320 hashfull 999 tbhits 0 time 397512 pv e4h7 g8h7 Q@h2 P@h6 P@f4 g5f5 N@g5 h7h8 B@h7 B@g6 B@d3 N@e2 d3e2 g6h7 P@c7 B@d8 c7d8q a8d8 g5h7 f8d6 N@e8 d8d7 e8d6 d7d6 B@a3 f5c2 a3d6 c2e2 R@c8 h8h7
ianfab commented 6 years ago

@ddugovic I do not think that the change in nps has any obvious meaning here. Looking at the code it can not be a (significant) speed-up, so I guess it might simply be related to a different number of TT hits in the two searches.

Note: Your commit introduces a a lichess-style crazyhouse FEN into the benchmark set. I am not sure whether that was intentional, but it might anyway be useful to avoid breaking support for that in the future.

ddugovic commented 6 years ago

Thanks @ianfab and I agree, it seems the change is not a (significant) speed-up for most positions in general (or it might be, at loss of Elo) so the nps change is not meaningful here.

That formatting was unintentional & I'll change it; for simplicity's sake (in case in the future GUIs/interfaces fully adopt the "pocket" style and on a major release we can finally drop support for the "ninth rank" style) I much prefer to have all crazyhouse FENs in the same format.