LCZero update (2)

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

Moderators: hgm, Rebel, chrisw

Werewolf
Posts: 1796
Joined: Thu Sep 18, 2008 10:24 pm

Re: LCZero update

Post by Werewolf »

Yes I did. I followed all commands above to the letter and the command prompt tuning etc seems to go perfectly.

But that leaves me with a load of text like this:

c:\LCZero\leela-zero-0.12-win64>lczero.exe -w latest.txt [-l debug.log]
Unrecognized argument: [-l
Unrecognized argument: debug.log]
LCZero Copyright (C) 2017 Gary Linscott
Based on:Leela Chess Copyright (C) 2017 benediamond
Leela Zero Copyright (C) 2017 Gian-Carlo Pascutto
Stockfish Copyright (C) 2017 Tord Romstad, Marco Costalba, Joona Kiiski, Gary Linscott
This program comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to redistribute it
under certain conditions; see the COPYING file for details.

Allowed options:
-h [ --help ] Show commandline options.
-t [ --threads ] arg (=2) Number of threads to use.
-p [ --playouts ] arg Weaken engine by limiting the number of
playouts. Requires --noponder.
-r [ --resignpct ] arg (=10) Resign when winrate is less than x%.
-n [ --noise ] Apply dirichlet noise to root.
--randomize Randomize move selection at root (only useful
for training).
-s [ --seed ] arg Random number generation seed.
-w [ --weights ] arg File with network weights.
-l [ --logfile ] arg File to log input/output to.
-q [ --quiet ] Disable all diagnostic output.
--noponder Disable thinking on opponent's time.
--start arg Start command {train, bench}.
--supervise arg Dump supervised learning data from the pgn.
--gpu arg ID of the OpenCL device(s) to use (disables
autodetection).
--full-tuner Try harder to find an optimal OpenCL tuning.
--tune-only Tune OpenCL only and then exit.


c:\LCZero\leela-zero-0.12-win64>


And I don't know what to do next. When I go into Arena and load lczero as a UCI engine, it doesn't play any moves.
pferd
Posts: 134
Joined: Thu Jul 24, 2014 2:49 pm

Re: LCZero update

Post by pferd »

Please, try without "[-I debug.log]"
Werewolf
Posts: 1796
Joined: Thu Sep 18, 2008 10:24 pm

Re: LCZero update

Post by Werewolf »

pferd wrote:Please, try without "[-I debug.log]"
OK, that yields this response:

(c) 2017 Microsoft Corporation. All rights reserved.

C:\Program Files (x86)\Arena\Shelf>cd c:\lczero\leela-zero-0.12-win64

c:\LCZero\leela-zero-0.12-win64>lczero.exe -w latest.txt
Generated 1924 moves
Detecting residual layers...v1...64 channels...6 blocks.
Initializing OpenCL.
Detected 1 OpenCL platforms.
Platform version: OpenCL 1.2 CUDA 9.1.75
Platform profile: FULL_PROFILE
Platform name: NVIDIA CUDA
Platform vendor: NVIDIA Corporation
Device ID: 0
Device name: GeForce GTX 1060 6GB
Device type: GPU
Device vendor: NVIDIA Corporation
Device driver: 388.13
Device speed: 1708 MHz
Device cores: 10 CU
Device score: 1112
Selected platform: NVIDIA CUDA
Selected device: GeForce GTX 1060 6GB
with OpenCL 1.2 capability.
Loaded existing SGEMM tuning.
Wavefront/Warp size: 32
Max workgroup size: 1024
Max workgroup dimensions: 1024 1024 64
BLAS Core: Haswell


What should I do now? Thanks.
pferd
Posts: 134
Joined: Thu Jul 24, 2014 2:49 pm

Re: LCZero update

Post by pferd »

Now, you can install it in arena. After the installation go to the manage engine dialogue and select lczero.

Add this to the command line parameters:

-w latest.txt -p 150000 --noponder

This means that the search will stop after at most 150000 nodes.

and make sure its type is UCI
Werewolf
Posts: 1796
Joined: Thu Sep 18, 2008 10:24 pm

Re: LCZero update

Post by Werewolf »

You are a genius.

Thank you.
Werewolf
Posts: 1796
Joined: Thu Sep 18, 2008 10:24 pm

Re: LCZero update

Post by Werewolf »

Would you be able to estimate the elo gain per doubling the number of rollouts?

Is it anywhere near a normal engine where doubling the amount of time yields around 50 elo?
jkiliani
Posts: 143
Joined: Wed Jan 17, 2018 1:26 pm

Re: LCZero update

Post by jkiliani »

Werewolf wrote:Would you be able to estimate the elo gain per doubling the number of rollouts?

Is it anywhere near a normal engine where doubling the amount of time yields around 50 elo?
It is probably more, but so far no-one has calculated a scaling curve for Leela Chess. In theory, NN based engines scale better than Alpha-Beta engines.It would be a very good idea to test that though, would you be interested?
JJJ
Posts: 1346
Joined: Sat Apr 19, 2014 1:47 pm

Re: LCZero update

Post by JJJ »

I can still win at 200 ms / per move despite the elo jump. But for how long ? ^^ And of course I can't at higher time control.

[pgn]1. d4 d5
2. c4 dxc4
3. e3 Nf6
4. Bxc4 e6
5. Nf3 Be7
6. O-O O-O
7. Nc3 Nc6
8. a3 a6
9. Bd3 Rb8
10. Re1 b5
11. Qc2 b4
12. axb4 Nxb4
13. Qb1 Nxd3
14. Qxd3 c5
15. Qc2 cxd4
16. exd4 h6
17. Ne4 Bb7
18. Nxf6+ Bxf6
19. Be3 Bxf3
20. gxf3 a5
21. Qa4 Rxb2
22. Qxa5 Qxa5
23. Rxa5 Rb4
24. Rd1 Rd8
25. Ra3 Kh7
26. Rad3 g6
27. Kg2 Rb5
28. Rc1 Rb4
29. Rcd1 Rg8
30. Rc1 Rgb8
31. Rc7 Bh8
32. Rxf7+ Bg7
33. d5 exd5
34. Rxd5 Kg8
35. Rdd7 Bc3
36. Rh7 h5
37. Rh6 Rf8
38. Rxg6+ Kh8
39. Rh6+ Kg8
40. Rxh5 Rb1
41. Rg5+ Kh8
42. Bd4+ Bxd4
43. Rxd4 Rf7
44. Rh4+ Rh7
45. Rxh7+ Kxh7
46. h4 Kh6
47. f4 Rb4
48. Kg3 Ra4
49. Kg4 Ra2
50. f3 Rh2
51. Rh5+ Kg7
52. f5 Kf6
53. Rh6+ Kg7
54. Rg6+ Kf7
55. h5 Rh1
56. Ra6 Kg7
57. f6+ Kf7
58. Kg5 Rg1+
59. Kf5 Rh1
60. Ra7+ Kf8
61. Kg6 Kg8
62. Ra8# [/pgn]

or this one thanks to his blunder, almost always the same :

[pgn]1. d4 d5
2. c4 dxc4
3. e3 Nf6
4. Bxc4 e6
5. Nf3 Be7
6. O-O O-O
7. Nc3 c5
8. b3 cxd4
9. exd4 a6
10. Bb2 b5
11. Be2 b4
12. Na4 Nbd7
13. Rc1 Bb7
14. Nc5 Nxc5
15. dxc5 Rc8
16. Qxd8 Rfxd8
17. c6 Rxc6
18. Rxc6 Bxc6
19. Bxa6 Ra8
20. Bxf6 Bxf6
21. Bc4 Rxa2
22. h3 Be4
23. Rd1 g6
24. Nd4 Be5
25. f3 Bc2
26. Rd2 Bxd4+
27. Rxd4 Bb1
28. Rd8+ Kg7
29. Rb8 Kf6
30. Rxb4 Rc2
31. Ra4 g5
32. Ra7 Rd2
33. Rb7 Ra2
34. b4 Rd2
35. b5 Rd4
36. Rc7 Rd6
37. Rc6 Rd2
38. b6 Rb2
39. Ba6 h6
40. b7 Ke5
41. Rc8 Rxb7
42. Bxb7 Bg6
43. Rc5+ Kf4
44. Rc4+ Kf5
45. Be4+ Kf6
46. Bxg6 fxg6
47. Kf2 h5
48. Ke3 Kf5
49. Rc5+ Kf6
50. Ke4 h4
51. Rc6 Ke7
52. Ke5 Kd7
53. Rxe6 Kc8
54. Rxg6 Kd7
55. Rxg5 Ke8
56. Rg4 Kd8
57. Rxh4 Kd7
58. f4 Kc8
59. f5 Kd7
60. f6 Kd8
61. Rh8+ Kd7
62. f7 Ke7
63. f8=Q+ Kd7
64. Rh6 Kc7
65. Qg7+ Kb8
66. Rh8# [/pgn]
User avatar
Laskos
Posts: 10948
Joined: Wed Jul 26, 2006 10:21 pm
Full name: Kai Laskos

Re: LCZero update

Post by Laskos »

jkiliani wrote:
Werewolf wrote:Would you be able to estimate the elo gain per doubling the number of rollouts?

Is it anywhere near a normal engine where doubling the amount of time yields around 50 elo?
It is probably more, but so far no-one has calculated a scaling curve for Leela Chess. In theory, NN based engines scale better than Alpha-Beta engines.It would be a very good idea to test that though, would you be interested?
NN with backing up the average score MCTS used in LCZero seems to scale a bit better than Alpha-Beta conventional modern engine like Zurichess, but not by much. I took Zurichess Appenzeller 64-bit (Elo 1821 CCRL 40/4'), a modern engine of the Zurichess line of engines, which in 2 years became pretty strong, and played 3 matches against today's latest LCZero, at 0.1s/move, 1s/move, 10s/move (a total factor of 100 in time control), and the results are similar, maybe a bit better scaling of LCZero:

Code: Select all

0.1s / move

Games Completed = 100 of 100 (Avg game length = 2.668 sec)
Settings = RR/64MB/100ms per move/M 500cp for 3 moves, D 140 moves/EPD:C:\LittleBlitzer\2moves_v1.epd(32000)
Time = 978 sec elapsed, 0 sec remaining
 1.  lczero                   	 7.5/100	4-89-7  	(L: m=17 t=0 i=0 a=72)	(D: r=7 i=0 f=0 s=0 a=0)	(tpm=77.4 d=8.51 nps=88)
 2.  Zurichess App.           	92.5/100	89-4-7  	(L: m=1 t=0 i=0 a=3)	(D: r=7 i=0 f=0 s=0 a=0)	(tpm=10.6 d=2.97 nps=1095171)




1s / move

Games Completed = 100 of 100 (Avg game length = 32.474 sec)
Settings = RR/64MB/1000ms per move/M 500cp for 3 moves, D 140 moves/EPD:C:\LittleBlitzer\2moves_v1.epd(32000)
Time = 1763 sec elapsed, 0 sec remaining
 1.  lczero                   	 9.0/100	5-87-8  	(L: m=11 t=0 i=0 a=76)	(D: r=7 i=1 f=0 s=0 a=0)	(tpm=991.9 d=12.02 nps=351)
 2.  Zurichess App.           	91.0/100	87-5-8  	(L: m=0 t=0 i=0 a=5)	(D: r=7 i=1 f=0 s=0 a=0)	(tpm=22.3 d=4.12 nps=852925)




10s / move

Games Completed = 100 of 100 (Avg game length = 380.767 sec)
Settings = RR/64MB/10000ms per move/M 500cp for 3 moves, D 140 moves/EPD:C:\LittleBlitzer\2moves_v1.epd(32000)
Time = 10654 sec elapsed, 0 sec remaining
 1.  lczero                   	11.5/100	6-83-11  	(L: m=18 t=0 i=0 a=65)	(D: r=10 i=0 f=1 s=0 a=0)	(tpm=10018.1 d=14.96 nps=68)
 2.  Zurichess App.           	88.5/100	83-6-11  	(L: m=0 t=0 i=0 a=6)	(D: r=10 i=0 f=1 s=0 a=0)	(tpm=129.7 d=5.69 nps=744436)
Also, the strength of LCZero of today can be estimated at 1400-1500 CCRL 40/4 Elo points.
User avatar
CMCanavessi
Posts: 1142
Joined: Thu Dec 28, 2017 4:06 pm
Location: Argentina

Re: LCZero update

Post by CMCanavessi »

Someone asked when will be the first time Lc0 will be able to beat SF level 20.
It has happened! Lc0 won as black! \o/ (SF had 1 second per game, Lc0 had 200000 playouts per move)

https://lichess.org/I9OtjJUy

Finally! :) Historical moment! (or that's not what they meant?) :lol:
Follow my tournament and some Leela gauntlets live at http://twitch.tv/ccls