Hey Sam: Hannibal and obvious move heuristic

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Rebel, chrisw

CRoberson
Posts: 2055
Joined: Mon Mar 13, 2006 2:31 am
Location: North Carolina, USA

Hey Sam: Hannibal and obvious move heuristic

Post by CRoberson »

Sam,

Seems you don't have the obvious move heuristic or there is an issue. I was watching a game on OpenWar and Hannibal took an inordinate amount of time to make a decision on move 83.

Here is the position:

[D] 8/7P/b2kB3/8/8/2b5/P1K5/8 w - - 0 83

Here is the game:


[Event "OpenWar 9th Edition 20 + 5"]
[Site "QUAD"]
[Date "2011.11.29"]
[Round "14.25"]
[White "Hannibal 1.1_x64"]
[Black "Eichhörnchen 0.2.12b9"]
[Result "1-0"]
[TimeControl "1200+5"]
[Annotator "29. +0.24 41... +0.44"]
[Number "519"]

1. e4 c5 2. Nf3 d6 3. d4 cxd4 4. Nxd4 Nf6 5. Nc3 a6 6. Bg5 e6 7. f4 Qb6 8.
Qd2 Qxb2 9. Rb1 Qa3 10. e5 h6 11. Bh4 dxe5 12. fxe5 g5 13. exf6 gxh4 14.
Be2 Qa5 15. O-O Nd7 16. Kh1 Qg5 17. Rf4 e5 18. Nd5 exd4 19. Qxd4 Bc5 20.
Qe4+ Kd8 21. Rf5 Re8 22. Qxe8+ Kxe8 23. Rxg5 hxg5 24. Nc7+ Kd8 25. Nxa8
Nxf6 26. Bf3 b5 27. Rd1+ Ke7 28. Nc7 Bd6 29. Nd5+ {+0.24/21 40} Nxd5 30.
Re1+ {+0.27/23 41} Kd8 31. Bxd5 {+0.33/25 44} f6 32. c4 {+0.33/25 45} b4
33. Be6 {+0.28/23 31} Bb7 34. Bg4 {+0.39/24 50} Be5 35. Rd1+ {+0.40/22 25}
Kc7 36. Rd7+ {+0.51/24 26} Kb8 37. Bf3 {+0.45/24 23} Bc8 38. Rf7
{+0.51/25 24} a5 39. Bd5 {+0.51/24 25} Bd4 40. c5 {+0.51/23 45} Bxc5 41.
Rxf6 {+0.49/25 27} a4 {+0.44/15 1:31} 42. Rg6 {+0.45/23 1:08} Be3
{+0.46/15 1:17} 43. Rg7 {+0.49/23 27} Bd2 {+0.34/15 1:05} 44. Kg1
{+0.39/21 22} a3 {+0.05/15 54} 45. Kf2 {+1.02/21 19} Bg4 {+0.24/14 44} 46.
h3 {+1.48/21 17} Bc8 {+0.23/14 35} 47. Ke2 {+1.48/26 2.1} Bf4 {+0.00/15 34}
48. Kf3 {+1.48/26 3} Ba6 {+0.00/15 33} 49. Ke4 {+1.67/23 30} Bd2
{+0.00/15 33} 50. Rf7 {+2.00/22 28} Bc8 {+0.00/14 32} 51. Kd4 {+2.09/22 29}
g4 {-1.39/16 1:32} 52. hxg4 {+2.16/24 0.1} Bxg4 {-1.74/15 1:24} 53. Rb7+
{+2.28/24 0.1} Kc8 {-0.99/14 25} 54. Rh7 {+2.28/25 10} h3 {-1.33/14 25} 55.
gxh3 {+2.28/26 11} Bf5 {-1.60/15 1:12} 56. Rh5 {+2.24/26 0.1} Bg6
{-1.60/14 22} 57. Rh8+ {+2.24/23 0.8} Kc7 {-1.60/15 21} 58. Kc5
{+2.69/22 29} Bf5 {-1.61/14 21} 59. h4 {+2.86/20 20} Bc3 {-2.13/15 1:00}
60. Ra8 {+3.42/24 0.1} Bd2 {-2.13/13 18} 61. h5 {+3.43/20 1.0} Bc8
{-2.26/13 18} 62. Ra7+ {+3.96/22 43} Kb8 {-3.49/15 52} 63. Rh7
{+4.22/21 14} Bf5 {-3.71/13 16} 64. Rb7+ {+4.79/20 4} Kc8 {-3.72/13 15} 65.
Rf7 {+5.06/22 10} Bb1 {-4.50/14 45} 66. Be6+ {+5.20/22 0.1} Kb8
{-4.50/14 14} 67. Rd7 {+5.28/22 4} Be3+ {-4.52/13 13} 68. Kxb4
{+5.31/21 19} Be4 {-4.62/14 13} 69. Kxa3 {+5.41/23 8} Bf3 {-4.77/13 13} 70.
Rh7 {+5.45/22 9} Be4 {-4.78/13 13} 71. Rf7 {+5.48/22 10} Bd3 {-4.83/13 12}
72. Rf3 {+5.77/23 22} Bc1+ {-4.88/13 12} 73. Kb3 {+7.15/23 3:13} Be2
{-4.96/14 12} 74. Rf8+ {+7.15/23 11} Ka7 {-5.14/13 12} 75. Kc2
{+7.31/24 0.7} Be3 {-5.45/13 11} 76. Rf5 {+7.30/24 11} Ba6 {-7.65/14 34}
77. Rf6 {+7.90/23 0.1} Bd4 {-7.76/14 10} 78. Rf7+ {+8.05/22 6} Kb6
{-7.76/14 10} 79. h6 {+8.05/24 13} Ba1 {-7.78/13 10} 80. h7 {+8.17/23 11}
Kc5 {-8.05/14 10} 81. Rc7+ {+16.75/20 1:57} Kd6 {-7.94/15 10} 82. Rc3
{+19.14/21 1:58} Bxc3 {-8.51/16 28} 83. Kxc3 {+19.99/15 1:25} Kxe6
{-12.50/17 26} 84. h8=Q {+13.09/12 5} Bb5 {-12.85/15 24} 85. Qh6+
{+19.13/10 9} Kd5 {-20.76/15 22} 86. Qg5+ {+18.63/11 11} Kd6 {-24.12/16 20}
87. Qxb5 {+20.22/10 9} Ke6 {-327.53/17 19} 88. Qe8+ Kf5 {-20.78/12 6} 89.
Qc8+ {+19.82/8 20} Ke5 {-327.51/16 17} 90. Qc5+ {+18.96/7 6} Kf4
{-24.31/14 5} 91. Qd6+ {+19.00/7 10} Ke4 {-325.12/13 16} 92. a4
{+19.19/7 9} Kf3 {-25.17/15 5} 93. Qd5+ {+19.84/6 5} Kg4 {-327.55/16 15}
94. Qe4+ {+19.98/6 4} Kg5 {-21.81/14 5} 95. a5 {+20.25/7 13} Kf6
{-327.57/15 14} 96. a6 {+99.91/21 0.1} Kg7 {-327.59/13 4} 97. Qe6
{+99.93/8 0.3} Kh7 {-327.59/13 4} 98. a7 {+99.95/21 0.1} Kg7 {-327.61/12 4}
99. a8=Q {+99.97/21 0.1} Kh7 {-327.65/11 4} 100. Qag8# {+99.99/21 0.1}
{Xboard adjudication: Checkmate} 1-0
BubbaTough
Posts: 1154
Joined: Fri Jun 23, 2006 5:18 am

Re: Hey Sam: Hannibal and obvious move heuristic

Post by BubbaTough »

This is a known, awful issue. I am tempted to release a version that fixes this, even though my current version is not much improved elo-wise from 1.1. Basically, when we added aspiration windows we added a bunch of problems which mostly show up when either mate is detected, or when the scores changes a lot with each ply (which is common when the magnitude of the score is large). Besides a few serious issues (problems mating, occasional awful move after a weird series of fail high/fail low events) it can interact annoyingly with the time management code, causing the program to play very slowly when it has a large lead due to the score oscillations.

For testing groups that auto-resign when there is a large lead, the effects of all these issues are not large, and the elo gain from the aspiration windows and some associated pruning features more than compensate from the occasional oddness. Even when played to mate, the new buggy features seem to be a slight elo gain over simpler, smoother play. HOWEVER, elo aside I find the whole thing incredibly annoying, and a little embarrassing to watch, and if I thought anyone actually used Hannibal for anything other than testing other programs I would definitely release a new version without these problems without waiting for a large elo gain.

-Sam