Basics
Moderator: Ras
-
Henk
- Posts: 7251
- Joined: Mon May 27, 2013 10:31 am
Re: Basics
No with user interface I meant the driver part of my engine that prints the move. If it does nor use the driver it plays the internal move when it uses it's own GUI.
-
Henk
- Posts: 7251
- Joined: Mon May 27, 2013 10:31 am
Re: Basics
(Changed it.) By the way at level 1 Skipper does not see stalemate. (It also should not add h3h4)
Code: Select all
Depth Value Time(seconds) Nodes
3 M3 0.06 676 f1=R h2h3 f1h1 h3h4
2 9.4576 0.06 313 f1=R h2h3
1 11.9576 0.06 71 f1=Q
-
mar
- Posts: 2675
- Joined: Fri Nov 26, 2010 2:00 pm
- Location: Czech Republic
- Full name: Martin Sedlak
Re: Basics
That's ok, you don't have to detect stalemate in qs.Henk wrote:By the way at level 1 Skipper does not see stalemate.
-
Daniel Anulliero
- Posts: 773
- Joined: Fri Jan 04, 2013 4:55 pm
- Location: Nice
Re: Basics
Funny pv at depth 3Henk wrote:(Changed it.) By the way at level 1 Skipper does not see stalemate. (It also should not add h3h4)
Code: Select all
Depth Value Time(seconds) Nodes 3 M3 0.06 676 f1=R h2h3 f1h1 h3h4 2 9.4576 0.06 313 f1=R h2h3 1 11.9576 0.06 71 f1=Q
Rh1+ and Kh4 illegal move
-
Henk
- Posts: 7251
- Joined: Mon May 27, 2013 10:31 am
Re: Basics
Yes terrible bug(s). Skipper played in this position Rf2: ???? Don't know what has happened. Can't reproduce. I remember Skipper giving away a bishop a few days ago but I thought it had to do with a too large passed pawn bonus.Daniel Anulliero wrote:Welllll. ... KRKN is usualy à draw ...Henk wrote:Actually I think KRKN end game occurs more frequently than KRK or otherwise KRKNP. See Skipper often playing that endgame and always losing.
I have a scoop for you ... you have bugs somewhere
Need to fix them...
Where can I see skipper playing ? Any download?
Personnaly I'll plan to release Isa soon , sometimes , the Testers or the "magicians of compiler" can help to fix tons of things .
You should release Skipper too
[d] 6k1/5p1p/6p1/1p6/2p2P1B/7P/4rP2/1K6 b - - 3 41
See not reproducible:
Code: Select all
Depth Value Time(seconds) Nodes
13 5.0408 0.37 442114 b5b4 h4f6 e2f2 f6e5 c4c3 h3h4 c3c2 b1b2 b4b3 e5b8 g8g7 b8d6 f2e2
12 5.0856 0.29 329596 b5b4 h4f6 e2f2 f6e5 c4c3 h3h4 c3c2 b1c1 b4b3 c1b2 f2d2 b2c1
11 5.0408 0.23 253375 b5b4 h4f6 e2f2 f6e5 c4c3 h3h4 c3c2 b1b2 b4b3 e5d6 f2e2
10 4.9896 0.17 158083 b5b4 h4f6 e2f2 f6e5 c4c3 b1a1 c3c2 a1b2 b4b3 h3h4
9 4.4904 0.09 57705 b5b4 b1a1 b4b3 h4f6 e2a2 a1b1 a2f2 f6e5 f7f5
8 4.3560 0.07 29370 b5b4 b1a1 b4b3 h4g3 e2a2 a1b1 c4c3 h3h4
7 4.2344 0.06 14085 b5b4 f2f3 c4c3 h4f6 c3c2 b1b2 b4b3
6 4.2344 0.05 10593 b5b4 f2f3 c4c3 h4f6 c3c2 b1b2 b4b3
5 4.1704 0.05 4164 b5b4 f2f3 c4c3 h4f6 c3c2 b1b2
4 3.7096 0.04 1713 b5b4 f2f3 c4c3 h4f6
3 3.7416 0.04 749 b5b4 f2f3 c4c3
2 3.3896 0.04 262 b5b4 f2f3
1 3.3960 0.04 67 b5b4
-
Henk
- Posts: 7251
- Joined: Mon May 27, 2013 10:31 am
Re: Basics
KRK ? It cannot even win KQK. Also 6. .. Bc3: hopeless bad move.
[pgn]
[Event "Computer Chess Game"]
[Site "HP"]
[Date "2016.03.16"]
[Round "-"]
[White "Fairy-Max 4.8S"]
[Black "SkipperWinb"]
[Result "1/2-1/2"]
[TimeControl "120"]
[Annotator "1. +0.13 1... +0.00"]
1. Nc3 {+0.13/8} g6 {+0.00/13 2.5} 2. d3 {+0.06/8 5} Bg7 {+0.02/14 2.4} 3.
h4 {+0.02/7 1.8} Nf6 {+0.58/13 2.3} 4. Bf4 {-0.14/8 2.6} Nh5 {+0.18/13 2.3}
5. Bd2 {-0.35/9 3} O-O {+0.61/13 2.3} 6. e3 {-0.10/8 2.9} Bxc3
{+0.43/9 2.2} 7. bxc3 {+0.25/10 7} b6 {-0.09/10 2.2} 8. Be2 {+0.43/10 1.4}
Nf6 {-0.06/14 2.1} 9. Nf3 {+0.37/10 4} Bb7 {-0.07/15 2.1} 10. O-O
{+0.39/10 3} Nc6 {-0.18/14 2.0} 11. a3 {+0.33/10 1.9} d5 {-0.21/13 2.0} 12.
c4 {+0.34/10 2.1} dxc4 {-0.14/14 2.0} 13. dxc4 {+0.09/10 4} Ne4
{-0.15/14 2.0} 14. Be1 {+0.21/9 1.0} Qxd1 {-0.20/13 1.9} 15. Rxd1
{+0.18/10 1.6} Rad8 {-0.18/13 1.9} 16. Rd5 {+0.23/9 2.1} Ba6 {-0.03/13 1.8}
17. Bd3 {+0.13/10 1.4} Nc5 {-0.14/14 1.8} 18. Rxd8 {-0.10/11 1.7} Nxd8
{-0.22/14 1.8} 19. Be2 {+0.00/10 0.9} Bb7 {-0.17/13 1.7} 20. Nd4
{+0.13/9 1.7} a5 {-0.16/14 1.7} 21. f4 {+0.15/9 1.0} Ne4 {-0.14/15 2.1} 22.
Nb5 {+0.18/10 1.4} Ne6 {-0.16/14 2.0} 23. Nc3 {+0.34/9 1.4} Rd8
{-0.14/14 2.0} 24. Bf3 {+0.23/10 1.8} N6c5 {-0.12/13 1.9} 25. Nxe4
{+0.01/10 1.2} Bxe4 {+0.47/14 2.0} 26. Bxe4 {-0.26/10 0.8} Nxe4
{+0.51/16 1.9} 27. f5 {-0.37/10 0.8} gxf5 {+0.65/14 1.7} 28. Rxf5
{-0.54/11 1.0} Rd1 {+1.30/16 1.8} 29. Rf1 {-0.72/12 1.7} Ra1 {+1.33/17 1.6}
30. h5 {-0.58/11 1.1} Rxa3 {+1.40/12 1.6} 31. h6 {-1.01/11 1.9} Rxe3
{+2.00/14 1.6} 32. Bh4 {-1.06/11 1.4} f6 {+2.00/12 1.5} 33. Rf4
{-1.02/10 0.9} Nd6 {+2.34/13 1.6} 34. Rg4+ {-1.14/10 0.9} Kh8
{+2.35/13 1.5} 35. Bf2 {-1.24/11 1.2} Re4 {+2.47/15 1.5} 36. Rxe4
{-1.71/14 1.1} Nxe4 {+2.52/15 1.5} 37. Bd4 {-1.86/13 4} e5 {+2.90/17 1.3}
38. Bb2 {-1.74/12 1.7} c5 {+2.95/15 1.3} 39. Kf1 {-1.61/12 1.0} Nd2+
{+3.27/17 1.3} 40. Ke2 {-1.71/13 0.9} Nxc4 {+3.46/17 1.3} 41. Bc3
{-2.26/12 0.7} a4 {+3.46/15 0.9} 42. Kd3 {-2.04/12 0.7} b5 {+3.70/15 0.9}
43. Ke4 {-2.47/12 0.9} a3 {+3.69/13 0.8} 44. Kd5 {-2.60/12 1.0} a2
{+5.43/17 0.9} 45. Kxc5 {-1.84/12 0.8} Ne3 {+5.69/16 0.9} 46. Kxb5
{-1.94/12 0.6} Nxc2 {+4.67/19 0.8} 47. Kc4 {-2.00/13 0.5} a1=Q
{+4.68/20 0.7} 48. Bxa1 {-3.14/15 0.9} Nxa1 {+4.68/18 0.7} 49. Kc3
{-3.62/16 0.8} Kg8 {+4.14/18 0.7} 50. Kb2 {-3.63/16 0.6} e4 {+4.46/21 0.7}
51. g4 {-4.18/17 0.8} e3 {+4.81/14 0.7} 52. Kc3 {-3.66/17 0.5} e2
{+4.81/12 0.7} 53. Kd2 {-3.62/17 0.7} e1=Q+ {+4.85/17 0.7} 54. Kxe1
{-3.65/17 0.6} Nc2+ {+4.44/20 0.7} 55. Kd2 {-3.47/16 0.4} Nb4
{+4.46/20 0.7} 56. Kc3 {-3.57/16 0.6} Nc6 {+4.46/20 0.7} 57. Kc4
{-4.30/16 1.0} Kf7 {+4.48/20 0.7} 58. Kd5 {-4.24/15 0.6} Ne7+
{+4.48/20 0.6} 59. Kd6 {-4.36/15 0.4} Ng8 {+4.62/16 0.6} 60. Kd5
{-4.63/15 0.5} Nxh6 {+4.72/19 0.6} 61. Kd4 {-4.73/15 0.5} Nxg4
{+4.73/18 0.6} 62. Ke4 {-5.32/15 0.5} Kg6 {+4.89/17 0.6} 63. Kf3
{-6.06/16 0.5} h5 {+5.04/18 0.6} 64. Kf4 {-6.78/16 0.4} f5 {+5.65/21 0.6}
65. Kf3 {-10.29/16 0.8} Kh6 {+5.65/20 0.6} 66. Kf4 {-8.79/18 0.6} h4
{+8.20/16 0.6} 67. Kxf5 {-8.81/18 0.3} h3 {+8.20/14 0.6} 68. Kxg4
{-8.80/17 0.5} h2 {+8.17/12 0.5} 69. Kf4 {-8.80/16 0.5} h1=Q {+8.17/10 0.5}
70. Ke5 {-79.93/16 0.5} Qc6 {+8.17/9 0.5} 71. Kd4 {-79.93/15 0.5} Kg5
{+7.21/7 0.5} 72. Ke3 {-79.94/15 0.3} Qh1 {+8.11/9 0.5} 73. Kd4
{-8.82/13 0.4} Kg4 {+7.21/8 0.4} 74. Kc5 {-8.85/14 0.4} Kf3 {+7.22/10 0.4}
75. Kd6 {-8.81/12 0.3} Qh2+ {+7.22/10 0.4} 76. Kd7 {-8.83/13 0.3} Qf4
{+7.22/12 0.4} 77. Kc6 {-8.85/13 0.3} Qc4+ {+7.22/12 0.4} 78. Kb6
{-79.92/14 0.5} Qd4+ {+7.22/12 0.4} 79. Kb5 {-79.89/13 0.3} Ke4
{+7.22/13 0.4} 80. Kc6 {-79.94/14 0.3} Qc4+ {+7.22/13 0.4} 81. Kb7
{-79.95/14 0.3} Qf7+ {+7.22/14 0.4} 82. Kc6 {-79.94/14 0.3} Kf3
{+7.22/14 0.4} 83. Kd6 {-79.91/14 0.3} Qf4+ {+7.22/13 0.4} 84. Kc6
{-0.01/28 0.2} Ke4 {+7.22/14 0.4} 85. Kc5 {-79.94/14 0.2} Kf3
{+7.22/15 0.4} 86. Kc6 {-0.01/28 0.2}
{XBoard adjudication: repetition draw} 1/2-1/2
[/pgn]
[pgn]
[Event "Computer Chess Game"]
[Site "HP"]
[Date "2016.03.16"]
[Round "-"]
[White "Fairy-Max 4.8S"]
[Black "SkipperWinb"]
[Result "1/2-1/2"]
[TimeControl "120"]
[Annotator "1. +0.13 1... +0.00"]
1. Nc3 {+0.13/8} g6 {+0.00/13 2.5} 2. d3 {+0.06/8 5} Bg7 {+0.02/14 2.4} 3.
h4 {+0.02/7 1.8} Nf6 {+0.58/13 2.3} 4. Bf4 {-0.14/8 2.6} Nh5 {+0.18/13 2.3}
5. Bd2 {-0.35/9 3} O-O {+0.61/13 2.3} 6. e3 {-0.10/8 2.9} Bxc3
{+0.43/9 2.2} 7. bxc3 {+0.25/10 7} b6 {-0.09/10 2.2} 8. Be2 {+0.43/10 1.4}
Nf6 {-0.06/14 2.1} 9. Nf3 {+0.37/10 4} Bb7 {-0.07/15 2.1} 10. O-O
{+0.39/10 3} Nc6 {-0.18/14 2.0} 11. a3 {+0.33/10 1.9} d5 {-0.21/13 2.0} 12.
c4 {+0.34/10 2.1} dxc4 {-0.14/14 2.0} 13. dxc4 {+0.09/10 4} Ne4
{-0.15/14 2.0} 14. Be1 {+0.21/9 1.0} Qxd1 {-0.20/13 1.9} 15. Rxd1
{+0.18/10 1.6} Rad8 {-0.18/13 1.9} 16. Rd5 {+0.23/9 2.1} Ba6 {-0.03/13 1.8}
17. Bd3 {+0.13/10 1.4} Nc5 {-0.14/14 1.8} 18. Rxd8 {-0.10/11 1.7} Nxd8
{-0.22/14 1.8} 19. Be2 {+0.00/10 0.9} Bb7 {-0.17/13 1.7} 20. Nd4
{+0.13/9 1.7} a5 {-0.16/14 1.7} 21. f4 {+0.15/9 1.0} Ne4 {-0.14/15 2.1} 22.
Nb5 {+0.18/10 1.4} Ne6 {-0.16/14 2.0} 23. Nc3 {+0.34/9 1.4} Rd8
{-0.14/14 2.0} 24. Bf3 {+0.23/10 1.8} N6c5 {-0.12/13 1.9} 25. Nxe4
{+0.01/10 1.2} Bxe4 {+0.47/14 2.0} 26. Bxe4 {-0.26/10 0.8} Nxe4
{+0.51/16 1.9} 27. f5 {-0.37/10 0.8} gxf5 {+0.65/14 1.7} 28. Rxf5
{-0.54/11 1.0} Rd1 {+1.30/16 1.8} 29. Rf1 {-0.72/12 1.7} Ra1 {+1.33/17 1.6}
30. h5 {-0.58/11 1.1} Rxa3 {+1.40/12 1.6} 31. h6 {-1.01/11 1.9} Rxe3
{+2.00/14 1.6} 32. Bh4 {-1.06/11 1.4} f6 {+2.00/12 1.5} 33. Rf4
{-1.02/10 0.9} Nd6 {+2.34/13 1.6} 34. Rg4+ {-1.14/10 0.9} Kh8
{+2.35/13 1.5} 35. Bf2 {-1.24/11 1.2} Re4 {+2.47/15 1.5} 36. Rxe4
{-1.71/14 1.1} Nxe4 {+2.52/15 1.5} 37. Bd4 {-1.86/13 4} e5 {+2.90/17 1.3}
38. Bb2 {-1.74/12 1.7} c5 {+2.95/15 1.3} 39. Kf1 {-1.61/12 1.0} Nd2+
{+3.27/17 1.3} 40. Ke2 {-1.71/13 0.9} Nxc4 {+3.46/17 1.3} 41. Bc3
{-2.26/12 0.7} a4 {+3.46/15 0.9} 42. Kd3 {-2.04/12 0.7} b5 {+3.70/15 0.9}
43. Ke4 {-2.47/12 0.9} a3 {+3.69/13 0.8} 44. Kd5 {-2.60/12 1.0} a2
{+5.43/17 0.9} 45. Kxc5 {-1.84/12 0.8} Ne3 {+5.69/16 0.9} 46. Kxb5
{-1.94/12 0.6} Nxc2 {+4.67/19 0.8} 47. Kc4 {-2.00/13 0.5} a1=Q
{+4.68/20 0.7} 48. Bxa1 {-3.14/15 0.9} Nxa1 {+4.68/18 0.7} 49. Kc3
{-3.62/16 0.8} Kg8 {+4.14/18 0.7} 50. Kb2 {-3.63/16 0.6} e4 {+4.46/21 0.7}
51. g4 {-4.18/17 0.8} e3 {+4.81/14 0.7} 52. Kc3 {-3.66/17 0.5} e2
{+4.81/12 0.7} 53. Kd2 {-3.62/17 0.7} e1=Q+ {+4.85/17 0.7} 54. Kxe1
{-3.65/17 0.6} Nc2+ {+4.44/20 0.7} 55. Kd2 {-3.47/16 0.4} Nb4
{+4.46/20 0.7} 56. Kc3 {-3.57/16 0.6} Nc6 {+4.46/20 0.7} 57. Kc4
{-4.30/16 1.0} Kf7 {+4.48/20 0.7} 58. Kd5 {-4.24/15 0.6} Ne7+
{+4.48/20 0.6} 59. Kd6 {-4.36/15 0.4} Ng8 {+4.62/16 0.6} 60. Kd5
{-4.63/15 0.5} Nxh6 {+4.72/19 0.6} 61. Kd4 {-4.73/15 0.5} Nxg4
{+4.73/18 0.6} 62. Ke4 {-5.32/15 0.5} Kg6 {+4.89/17 0.6} 63. Kf3
{-6.06/16 0.5} h5 {+5.04/18 0.6} 64. Kf4 {-6.78/16 0.4} f5 {+5.65/21 0.6}
65. Kf3 {-10.29/16 0.8} Kh6 {+5.65/20 0.6} 66. Kf4 {-8.79/18 0.6} h4
{+8.20/16 0.6} 67. Kxf5 {-8.81/18 0.3} h3 {+8.20/14 0.6} 68. Kxg4
{-8.80/17 0.5} h2 {+8.17/12 0.5} 69. Kf4 {-8.80/16 0.5} h1=Q {+8.17/10 0.5}
70. Ke5 {-79.93/16 0.5} Qc6 {+8.17/9 0.5} 71. Kd4 {-79.93/15 0.5} Kg5
{+7.21/7 0.5} 72. Ke3 {-79.94/15 0.3} Qh1 {+8.11/9 0.5} 73. Kd4
{-8.82/13 0.4} Kg4 {+7.21/8 0.4} 74. Kc5 {-8.85/14 0.4} Kf3 {+7.22/10 0.4}
75. Kd6 {-8.81/12 0.3} Qh2+ {+7.22/10 0.4} 76. Kd7 {-8.83/13 0.3} Qf4
{+7.22/12 0.4} 77. Kc6 {-8.85/13 0.3} Qc4+ {+7.22/12 0.4} 78. Kb6
{-79.92/14 0.5} Qd4+ {+7.22/12 0.4} 79. Kb5 {-79.89/13 0.3} Ke4
{+7.22/13 0.4} 80. Kc6 {-79.94/14 0.3} Qc4+ {+7.22/13 0.4} 81. Kb7
{-79.95/14 0.3} Qf7+ {+7.22/14 0.4} 82. Kc6 {-79.94/14 0.3} Kf3
{+7.22/14 0.4} 83. Kd6 {-79.91/14 0.3} Qf4+ {+7.22/13 0.4} 84. Kc6
{-0.01/28 0.2} Ke4 {+7.22/14 0.4} 85. Kc5 {-79.94/14 0.2} Kf3
{+7.22/15 0.4} 86. Kc6 {-0.01/28 0.2}
{XBoard adjudication: repetition draw} 1/2-1/2
[/pgn]
-
flok
Re: Basics
Why not?mar wrote:That's ok, you don't have to detect stalemate in qs.Henk wrote:By the way at level 1 Skipper does not see stalemate.
-
mar
- Posts: 2675
- Joined: Fri Nov 26, 2010 2:00 pm
- Location: Czech Republic
- Full name: Martin Sedlak
Re: Basics
They are rare and you can detect stalemates in main search easily (essentially for free) - this really should do.flok wrote:Why not?mar wrote:That's ok, you don't have to detect stalemate in qs.
Now that I think about it, since you already compute mobility in eval, detecting stalemates might be relatively easy, if there is no safe mobility for the king and all other (own) pieces have zero mobility, it should be a stalemate.
Special care would be needed for pawns though, should be trivial for a bitboard engine.
So yes, why not... I still doubt it'd be worth the effort.
EDIT: this wouldn't detect all stalemates but should cover the most obvious cases
-
mar
- Posts: 2675
- Joined: Fri Nov 26, 2010 2:00 pm
- Location: Czech Republic
- Full name: Martin Sedlak
Re: Basics
..continuing (thanks for the 15m limit:)
So you could either simply return 0 in eval or pass the information to qs and prune.
What seems more tempting is to detect trivial checkmates in eval, I think Ed described queen contact checkmates in his technical info on Rebel.
The problem is that those ideas will tax your eval and they have to be worth the additional effort (=happen often enough) or you might lose a bit of elo.
Of course, they might be useful for analysis.
In general, they also add complexity and may introduce new bugs, so I'd be careful.
So you could either simply return 0 in eval or pass the information to qs and prune.
What seems more tempting is to detect trivial checkmates in eval, I think Ed described queen contact checkmates in his technical info on Rebel.
The problem is that those ideas will tax your eval and they have to be worth the additional effort (=happen often enough) or you might lose a bit of elo.
Of course, they might be useful for analysis.
In general, they also add complexity and may introduce new bugs, so I'd be careful.
-
Stan Arts
- Posts: 179
- Joined: Fri Feb 14, 2014 10:53 pm
- Location: the Netherlands
Re: Basics
You probably are not going to try to generate all moves there so when you are not in check how would you know you have no moves?flok wrote: Why not?
One problem with that is recognising for example desperado eternal rook type situations rather than returning a won/lost score from qsearch. But most other stalemate situations are handled easily by normal search and eternal rook positions are ofcourse extremely rare. (But it would be nice to recognise them rather than going for some other losing or not winning ending. When stumbling into one ofcourse you probably get lucky and the endless checks are better than whatever else is at the horizon.)