Syzygy tablebases, work in Stockfish?

Discussion of chess software programming and technical issues.

Moderators: bob, hgm, Harvey Williamson

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
Zlatin
Posts: 7
Joined: Wed Dec 07, 2011 7:38 pm

Re: White or Black ran out of time and has no material to ma

Post by Zlatin » Wed Oct 02, 2013 8:43 pm

I have one directory with Syzygy 3-4-5 Individual Files (938.39 MB), one directory with Syzygy 6men DTZ (81.39 GB), and one directory with Syzygy 6men WDL (67.83 GB).
How to set them to work together in my deep analisys in CB12 - maybe in that way:
C:\tablebases\Syzygy3-4-5;D:\tablebases\dtz345;D:\tablebases\dtz6
in "Syzygybases Path"?

And what about "Probe Syzygybases" - 6 ?

syzygy
Posts: 4460
Joined: Tue Feb 28, 2012 10:56 pm

Re: White or Black ran out of time and has no material to ma

Post by syzygy » Wed Oct 02, 2013 11:20 pm

Zlatin wrote:I have one directory with Syzygy 3-4-5 Individual Files (938.39 MB), one directory with Syzygy 6men DTZ (81.39 GB), and one directory with Syzygy 6men WDL (67.83 GB).
How to set them to work together in my deep analisys in CB12 - maybe in that way:
C:\tablebases\Syzygy3-4-5;D:\tablebases\dtz345;D:\tablebases\dtz6
in "Syzygybases Path"?
If those are the 3 directory names this should be fine. However, I would expect a directory name D:\tablebases\wdl6 (with 67.83 GB of files) and not D:\tablebases\dtz345. Of course the actual directory names you use are unimportant, as long as the files are there.

Should you have 68GB of SSD space to spare, then place all .rbtw files there. (And if you would keep a copy of those on HDD, then make sure the SSD directories are first in the path.)
And what about "Probe Syzygybases" - 6 ?
Yes, you have the 6-piece tables, so you should probe them :-)

Zlatin
Posts: 7
Joined: Wed Dec 07, 2011 7:38 pm

Re: White or Black ran out of time and has no material to ma

Post by Zlatin » Thu Oct 03, 2013 8:24 am

Ty Ronald,
Of course D:\tablebases\wdl6, not D:\tablebases\dtz345, my mistake.
I will use tb on my HDD, have not space on SSD.
Can I mix all 3-4-5 and 6man tb in one directory - will Stockfish work properly with tablebases in that way?

phenri
Posts: 284
Joined: Tue Aug 13, 2013 7:44 am

Re: White or Black ran out of time and has no material to ma

Post by phenri » Thu Oct 03, 2013 10:36 am

Hello

Another recently occurred. But it is much more rare.

[pgn][Event "rated blitz game"]
[White "Houdini 3 x64"]
[Black "Stockfish 011013 64 SSE4"]
[WhiteElo "2813"]
[BlackElo "2917"]
[TimeControl "180+0"]
[Date "2013-10-03"]
[Time "02:38:00"]
[Duration "0:06:37"]
[WhiteClock "0:03:00.000"]
[BlackClock "0:03:00.000"]
[Result "1/2-1/2"]

1. c4 e5 2. g3 Nf6 3. Bg2 d5 4. cxd5 Nxd5 5. Nc3 Nb6 6. Nf3 Nc6 7. a3 Be7 8. d3 O-O 9. O-O Be6 10. Be3 f5 11. Rc1 a6 12. b4 Kh8 13. Qe1 Re8 14. h4 Qd7 15. Qd2 Rad8 16. h5 Bf6 17. h6 Nd4 18. hxg7+ Qxg7 19. Nxd4 exd4 20. Bh6 Qg6 21. Nd1 Nd5 22. Re1 Rg8 23. Nb2 Be5 24. e4 dxe3 25. Bxe3 Nxe3 26. Qxe3 Bxb2 27. Rxc7 Bc8 28. Qf4 Bf6 29. Bxb7 Bxb7 30. Rxb7 Rxd3 31. Kg2 Rxa3 32. Rc1 Qh5 33. Rb8 Qg4 34. Rcc8 Rxc8 35. Rxc8+ Kg7 36. Qc7+ Kh6 37. Qc1+ f4 38. Qxa3 Qxc8 39. gxf4 Be7 40. Kg1 Bd6 41. Qa1 Qg8+ 42. Kh1 Qd5+ 43. Kg1 Qd3 44. f5 Kh5 45. Qa2 Kh4 46. f6 Kg5 47. f7 Kf6 48. Kg2 Kg7 49. Qa1+ Kf8 50. Qa4 Kxf7 51. Qd7+ Kg6 52. Qe6+ Kg5 53. Qe1 h5 54. Qe8 Qd5+ 55. Kg1 Bxb4 56. Qe3+ Kg6 57. Qb6+ Qd6 58. Qb7 Bc5 59. Kf1 a5 60. Qb3 Qd4 61. Ke2 Qxf2+ 62. Kd1 Qd4+ 63. Kc2 a4 64. Qb5 Qe4+ 65. Kc3 Qb4+ 66. Qxb4 Bxb4+ 67. Kxb4 h4 68. Kxa4 h3 69. Kb5 h2 70. Kc4 Kf5 71. Kc3 Ke5 72. Kc4 {Black ran out of time and White has no material to mate} 1/2-1/2[/pgn]

[d]8/8/8/4k3/2K5/8/7p/8 b - - 0 72

File used http://rghost.net/49076208
Last edited by phenri on Thu Oct 03, 2013 10:38 am, edited 1 time in total.

syzygy
Posts: 4460
Joined: Tue Feb 28, 2012 10:56 pm

Re: White or Black ran out of time and has no material to ma

Post by syzygy » Thu Oct 03, 2013 10:36 am

Zlatin wrote:Can I mix all 3-4-5 and 6man tb in one directory - will Stockfish work properly with tablebases in that way?
Yes, it looks for each table in all directories, starting with the first directory in the list.

phenri
Posts: 284
Joined: Tue Aug 13, 2013 7:44 am

Re: White or Black ran out of time and has no material to ma

Post by phenri » Thu Oct 03, 2013 9:27 pm

New one

[d]8/8/8/8/3K4/8/kp6/8 b - - 0 165

syzygy
Posts: 4460
Joined: Tue Feb 28, 2012 10:56 pm

Re: White or Black ran out of time and has no material to ma

Post by syzygy » Thu Oct 03, 2013 10:31 pm

phenri wrote:Hello

Another recently occurred. But it is much more rare.

[pgn][Event "rated blitz game"]
[White "Houdini 3 x64"]
[Black "Stockfish 011013 64 SSE4"]
[WhiteElo "2813"]
[BlackElo "2917"]
[TimeControl "180+0"]
[Date "2013-10-03"]
[Time "02:38:00"]
[Duration "0:06:37"]
[WhiteClock "0:03:00.000"]
[BlackClock "0:03:00.000"]
[Result "1/2-1/2"]

1. c4 e5 2. g3 Nf6 3. Bg2 d5 4. cxd5 Nxd5 5. Nc3 Nb6 6. Nf3 Nc6 7. a3 Be7 8. d3 O-O 9. O-O Be6 10. Be3 f5 11. Rc1 a6 12. b4 Kh8 13. Qe1 Re8 14. h4 Qd7 15. Qd2 Rad8 16. h5 Bf6 17. h6 Nd4 18. hxg7+ Qxg7 19. Nxd4 exd4 20. Bh6 Qg6 21. Nd1 Nd5 22. Re1 Rg8 23. Nb2 Be5 24. e4 dxe3 25. Bxe3 Nxe3 26. Qxe3 Bxb2 27. Rxc7 Bc8 28. Qf4 Bf6 29. Bxb7 Bxb7 30. Rxb7 Rxd3 31. Kg2 Rxa3 32. Rc1 Qh5 33. Rb8 Qg4 34. Rcc8 Rxc8 35. Rxc8+ Kg7 36. Qc7+ Kh6 37. Qc1+ f4 38. Qxa3 Qxc8 39. gxf4 Be7 40. Kg1 Bd6 41. Qa1 Qg8+ 42. Kh1 Qd5+ 43. Kg1 Qd3 44. f5 Kh5 45. Qa2 Kh4 46. f6 Kg5 47. f7 Kf6 48. Kg2 Kg7 49. Qa1+ Kf8 50. Qa4 Kxf7 51. Qd7+ Kg6 52. Qe6+ Kg5 53. Qe1 h5 54. Qe8 Qd5+ 55. Kg1 Bxb4 56. Qe3+ Kg6 57. Qb6+ Qd6 58. Qb7 Bc5 59. Kf1 a5 60. Qb3 Qd4 61. Ke2 Qxf2+ 62. Kd1 Qd4+ 63. Kc2 a4 64. Qb5 Qe4+ 65. Kc3 Qb4+ 66. Qxb4 Bxb4+ 67. Kxb4 h4 68. Kxa4 h3 69. Kb5 h2 70. Kc4 Kf5 71. Kc3 Ke5 72. Kc4 {Black ran out of time and White has no material to mate} 1/2-1/2[/pgn]

[d]8/8/8/4k3/2K5/8/7p/8 b - - 0 72
Did it obviously hang or did it just run out of time under time pressure? Was black showing mate scores? Do you have a log?

In this position the tablebases are not used during the search, so if it just ran out of time the problem seems to lie with Stockfish itself. It is hard to see why it would hang on the final position and not on the position 1 move earlier.
Latest unmodified code?

phenri
Posts: 284
Joined: Tue Aug 13, 2013 7:44 am

Re: White or Black ran out of time and has no material to ma

Post by phenri » Fri Oct 04, 2013 2:36 am

syzygy wrote:
Did it obviously hang or did it just run out of time under time pressure? Was black showing mate scores? Do you have a log?
No, no time pressure (always 10, 20, 30sec), but no log sorry. I turn ON logs from now.
syzygy wrote: In this position the tablebases are not used during the search, so if it just ran out of time the problem seems to lie with Stockfish itself. It is hard to see why it would hang on the final position and not on the position 1 move earlier.
I dont know.
syzygy wrote:
Latest unmodified code?
Yes its the latest from syzygy1/Stockfish repository (unmodified).

Jouni
Posts: 2055
Joined: Wed Mar 08, 2006 7:15 pm

Re: White or Black ran out of time and has no material to ma

Post by Jouni » Mon Oct 14, 2013 1:24 pm

I gave 5 piece syzygy a test (Henri compile AFAIK). They work totally OK and endgame analysis is improved. But of course I found same problem positions too. Serious one
[D]2k5/3P4/8/8/8/8/1r5p/R3K3 b Q - 0 1

Stockfish definitely wants to lose :P when -Kd8 wins

Analysis by Stockfish 121013 64:
1...Kxd7 2.0-0-0+
-+ (-#51) Depth: 7/3 00:00:00 2kN, tb=36
1...Kxd7 2.0-0-0+
-+ (-#51) Depth: 8/3 00:00:00 2kN, tb=57
1...Kxd7 2.0-0-0+
-+ (-#51) Depth: 9/3 00:00:00 3kN, tb=86
1...Kxd7 2.0-0-0+
-+ (-#51) Depth: 10/3 00:00:00 5kN, tb=123

Another one

[D]2n5/kP6/8/K7/4B3/8/8/8 w - - 0 1

Analysis by Stockfish 121013 64:

1.bxc8N+ Kb8 2.Nd6 Kc7 3.Nf5 Kd7 4.Bd5 Ke8 5.Kb5 Kf8 6.Kc5 Ke8 7.Kc6 Kf8 8.Kd6 Ke8 9.Ke6 Kf8 10.Kf6 Ke8 11.Nd6+ Kd7 12.Nc4 Kd8 13.Ke6 Ke8 14.Nb6 Kf8 15.Kf6 Ke8 16.Bf7+ Kd8
+- (77.12) Depth: 29/32 00:00:02 5611kN, tb=1

SF should INSTANTLY display mate in 27 or bases are useless here!
Jouni

IQ
Posts: 161
Joined: Thu Dec 17, 2009 9:46 am

Re: White or Black ran out of time and has no material to ma

Post by IQ » Mon Oct 14, 2013 3:32 pm

I played 5000+ games with the 6 piece Syzygy WDL+DTZ (in Stockfish4) and never had a loss on time. There is one possibilty though: In case you put the WDL on a SSD and the DTZ Bases on a normal harddrive. If the normal harddrive spins down during the game due to inactivity (can be adjusted in windows power options) and has to wake up when a 6 piece position on the board is reached then this might take a couple of seconds. This might lead to a loss of time. So harddrive spindown for regular (non ssd) hardrives should be disabled. Or put all WDL+DTZ on the same drive.
phenri wrote:
syzygy wrote:
Did it obviously hang or did it just run out of time under time pressure? Was black showing mate scores? Do you have a log?
No, no time pressure (always 10, 20, 30sec), but no log sorry. I turn ON logs from now.
syzygy wrote: In this position the tablebases are not used during the search, so if it just ran out of time the problem seems to lie with Stockfish itself. It is hard to see why it would hang on the final position and not on the position 1 move earlier.
I dont know.
syzygy wrote:
Latest unmodified code?
Yes its the latest from syzygy1/Stockfish repository (unmodified).

Post Reply