Using material based game state gives a small improvement compared to the move count based one. I only tested it with 400 very high speed games. Most of the games were drawn.hgm wrote:Using the move number, rather than characteristics of the position to determine game phase is a bad idea. Some games proceed quickly, others drag on forever. The same position can be reached in 30 moves in one game, and in 130 moves in another. Even Fairy-Max uses a material-based game state (Q=6, R=3, minor=2, so ranging from 0-40 in orthodox Chess).
End Game Heuristics
Moderator: Ras
-
- Posts: 7251
- Joined: Mon May 27, 2013 10:31 am
Re: End Game Heuristics
-
- Posts: 7251
- Joined: Mon May 27, 2013 10:31 am
Re: End Game Heuristics
End game still far from good. Black draws with a mad (rabid) rook. Also white waits far too long with moving its passers. Instead it shuffles its rooks. (3 seconds per move for white so you cannot expect deep searches)
[pgn]
[Site "http://lichess.org/gPfCq1Kc"]
[Date "2014.03.21"]
[White "Anonymous"]
[Black "AI-level-7"]
[Result "1/2-1/2"]
[WhiteElo "?"]
[BlackElo "?"]
[PlyCount "183"]
[Variant "Standard"]
1. Nf3 d5 2. Nc3 Nf6 3. d4 e6 4. e3 Nc6 5. Bb5 Bd7 6. O-O Bd6 7. Qe2 Ne4 8. Nxe4 dxe4 9. Nd2 a6 10. Bc4 b5 11. Bb3 O-O 12. d5 exd5 13. Bxd5 Nb4 14. Bxe4 c6 15. a3 Nd5 16. Qd3 Qh4 17. Nf3 Qh6 18. Bd2 Rfc8 19. h3 Be6 20. Nd4 Rab8 21. Nxe6 Qxe6 22. Bxh7+ Kf8 23. Bf5 Qf6 24. Bxc8 Rxc8 25. e4 Nf4 26. Qf3 Re8 27. Rfe1 Kg8 28. Bc3 Be5 29. Bxe5 Qxe5 30. Rad1 c5 31. Kf1 a5 32. Rd7 Qe6 33. Rd2 Qe5 34. Rdd1 c4 35. Kg1 g5 36. Qg3 Qf6 37. Qg4 Ng6 38. Qd7 Re5 39. Rd6 Nf8 40. Qc7 Qg7 41. Qxa5 g4 42. hxg4 Rg5 43. Qc3 Rxg4 44. Qxg7+ Kxg7 45. a4 bxa4 46. Rc6 Rg5 47. Rxc4 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Qxe5 30. Rad1 c5 31. Kf1 a5 32. Rd7 Qe6 33. Rd2 Qe5 34. Rdd1 c4 35. Kg1 g5 36. Qg3 Qf6 37. Qg4 Ng6 38. Qd7 Re5 39. Rd6 Nf8 40. Qc7 Qg7 41. Qxa5 g4 42. hxg4 Rg5 43. Qc3 Rxg4 44. Qxg7+ Kxg7 45. a4 bxa4 46. Rc6 Rg5 47. Rxc4 a3 48. bxa3 Ng6 49. Rc3 Rb5 50. Rc7 Nf4 51. e5 Rb6 52. Re4 Ne6 53. Rg4+ Kf8 54. Rc8+ Ke7 55. Ra4 Kd7 56. Rc3 Ng7 57. Rf3 Rb1+ 58. Kh2 Ke6 59. Ra6+ Ke7 60. Ra7+ Ke6 61. Raxf7 Ne8 62. Rh7 Rc1 63. Rf8 Kxe5 64. Rxe8+ Kd6 65. Rd8+ Kc6 66. Rdd7 Kb6 67. Rh6+ Kc5 68. Rc7+ Kd4 69. Rh5 Ra1 70. Ra5 Rf1 71. Rf5 Rc1 72. a4 Ra1 73. a5 Ra3 74. Rb5 Ra2 75. Rbc5 Ra4 76. Rh5 Ra2 77. Rb5 Ra3 78. Rf5 Ra2 79. Rg5 Rb2 80. a6 Rb8 81. a7 Ra8 82. Kg1 Rf8 83. Ra5 Re8 84. a8=Q Re1+ 85. Kh2 Rh1+ 86. Kg3 Rh3+ 87. Kg4 Rh4+ 88. Kf3 Rf4+ 89. Kg3 Rg4+ 90. Kh2 Rh4+ 91. Kg1 Rh1+ 92. Kxh1 1/2-1/2
[/pgn]
-
- Posts: 28353
- Joined: Fri Mar 10, 2006 10:06 am
- Location: Amsterdam
- Full name: H G Muller
Re: End Game Heuristics
Rabid Rook is difficult to recognize for engines, so you are a bit unlucky here. (You could divide the score by factor for a branch that ends in a number of checks, but that interferes with hashing.)
It is indeed a bit indecisive before it starts pushing the passer; it seems only to do it opportunistically when black moves away its Rook from behind it, and does not actually make any effort for forcing it forward by covering the square in front of it with one of his Rooks.
Of course this because you don't search deep enough to see the promotion. But even then you should not have this problem if you awarded advancing passers enough. In Fairy-Max a 6th-rank Pawn is worth ~175, and a 7th-rank Pawn ~250. That should help, as on move 74 it would already see an opportunity to gain 75cP by 74. Ra7 Kd4 75. Rh5 any 76. a6 at 5 ply. In fact the whole King chase after move 64 was pointless, allowing the black King to centralize more, which in itself should lower the score. If a more attractive goal, such as getting a Pawn on 6th rank, is in view, it would have opted for that.
It is indeed a bit indecisive before it starts pushing the passer; it seems only to do it opportunistically when black moves away its Rook from behind it, and does not actually make any effort for forcing it forward by covering the square in front of it with one of his Rooks.
Of course this because you don't search deep enough to see the promotion. But even then you should not have this problem if you awarded advancing passers enough. In Fairy-Max a 6th-rank Pawn is worth ~175, and a 7th-rank Pawn ~250. That should help, as on move 74 it would already see an opportunity to gain 75cP by 74. Ra7 Kd4 75. Rh5 any 76. a6 at 5 ply. In fact the whole King chase after move 64 was pointless, allowing the black King to centralize more, which in itself should lower the score. If a more attractive goal, such as getting a Pawn on 6th rank, is in view, it would have opted for that.
-
- Posts: 7251
- Joined: Mon May 27, 2013 10:31 am
Re: End Game Heuristics
I increased the bonus for 6th- and 7-th rank in piece square table. Quick test showed it helped a bit.hgm wrote:Rabid Rook is difficult to recognize for engines, so you are a bit unlucky here. (You could divide the score by factor for a branch that ends in a number of checks, but that interferes with hashing.)
It is indeed a bit indecisive before it starts pushing the passer; it seems only to do it opportunistically when black moves away its Rook from behind it, and does not actually make any effort for forcing it forward by covering the square in front of it with one of his Rooks.
Of course this because you don't search deep enough to see the promotion. But even then you should not have this problem if you awarded advancing passers enough. In Fairy-Max a 6th-rank Pawn is worth ~175, and a 7th-rank Pawn ~250. That should help, as on move 74 it would already see an opportunity to gain 75cP by 74. Ra7 Kd4 75. Rh5 any 76. a6 at 5 ply. In fact the whole King chase after move 64 was pointless, allowing the black King to centralize more, which in itself should lower the score. If a more attractive goal, such as getting a Pawn on 6th rank, is in view, it would have opted for that.
-
- Posts: 7251
- Joined: Mon May 27, 2013 10:31 am
Re: End Game Heuristics
I increased the bonus for 6th- and 7-th rank in piece square table. Quick test showed it was a slight improvement.hgm wrote:Rabid Rook is difficult to recognize for engines, so you are a bit unlucky here. (You could divide the score by factor for a branch that ends in a number of checks, but that interferes with hashing.)
It is indeed a bit indecisive before it starts pushing the passer; it seems only to do it opportunistically when black moves away its Rook from behind it, and does not actually make any effort for forcing it forward by covering the square in front of it with one of his Rooks.
Of course this because you don't search deep enough to see the promotion. But even then you should not have this problem if you awarded advancing passers enough. In Fairy-Max a 6th-rank Pawn is worth ~175, and a 7th-rank Pawn ~250. That should help, as on move 74 it would already see an opportunity to gain 75cP by 74. Ra7 Kd4 75. Rh5 any 76. a6 at 5 ply. In fact the whole King chase after move 64 was pointless, allowing the black King to centralize more, which in itself should lower the score. If a more attractive goal, such as getting a Pawn on 6th rank, is in view, it would have opted for that.