Running GPU Lczero under Chessbase?

1,511 views
Skip to first unread message

pwa128

unread,
Jun 8, 2018, 3:40:00 AM6/8/18
to LCZero
I cannot get the GPU version of Lczero to run under Cbase12.exe

The CPU version works fine under Cbase12 but I cannot define a new engine with the GPU version.   

I thought this might have been due to using an AMD card but I upgraded yesterday to a 1070 Ti and the problem persists.     The change of card has resolved issues with the GPU version running under Shredder and CuteChess, but my main GUI is Cbase so this is particularly frustrating.  

Has anyone else got this to work, and if so how?

Stefan Pohl

unread,
Jun 8, 2018, 4:30:55 AM6/8/18
to LCZero
With a GTX 1070 TI, you can use LC0 Cuda, which is running 5x faster, than the GPU-version.


How to run Leela CUDA (should be around 5x faster, than Leela GPU(!)) in Fritz/Shredder GUI:

Important: Leela CUDA needs 3 .dll-files from the NVIDIA-developer-website, otherwise it can not run!
And - of course - you need a NVIDIA CUDA GPU in your PC...

1) Update your Nvidia driver for your GPU to the latest version here: http://www.nvidia.de/Download/index.aspx
After that: reboot your PC.
2) Get LC0.exe for the cuDNN version from: https://crem.xyz/lc0/ and unpack it and put it in your Leela CUDA folder.
3) Install CUDA v9.2 from https://developer.nvidia.com/cuda-92-download-archive (you need an account) and get 
cublas64_92.dll and cudart64_92.dll from the bin directory of CUDA v9.2 and copy it to your Leela CUDA-folder.
(Alternatively if you don't want to install CUDA, you can just unpack the installer and search in the unpacked
folder and files for the .dlls with <Strg>+F in the Windows-Explorer, that was, what I did). Put the 2 files in
your Leela CUDA-folder.
4) Get cuDNN for CUDA 9.2 from https://developer.nvidia.com/rdp/cudnn-download (you also need an account for this) 
and get cudnn64_7.dll from the bin directory of the zip and extract it and put it in your Leela CUDA-folder.
5) Download the latest network from http://lczero.org/networks and unpack it (Leela CUDA will autodetect it in 
any form either as weights.txt or however it is named) and put it in your Leela CUDA-folder.
6) Create the UCI-Engine in Fritz/Shredder.

Done.

pwa128

unread,
Jun 8, 2018, 6:29:29 AM6/8/18
to LCZero
Thanks for this - it is really clear!   I was going to hold off from setting up LC0 until I had sorted a few other things out but if it will defintely run under Cbase12 I will tackle it sooner rather than later.

123

unread,
Jun 8, 2018, 11:33:07 AM6/8/18
to LCZero
pwa128:
I cannot get the GPU version of Lczero to run under Cbase12.exe

Buy Aquarium 2018 

pwa128

unread,
Jun 8, 2018, 11:39:21 AM6/8/18
to LCZero
I have Aquarioum, I much prefer Chessbase.

pwa128

unread,
Jun 9, 2018, 11:47:17 AM6/9/18
to LCZero
I followed these instructions but it has not fully resolved the problem:

- it was really easy to install LC0 with these instructions.
- it runs quickly as expected
- it runs perfectly under Shredder and Cutechess, with the PVs showing just fine
- it now does run under Chessbase, but Chessbase will not display its PVs even with the verbose setting on.

Perhaps LC0's output is not quite to the UCI standards and other GUIs are more forgiving but Cbase12.exe isn't ?


On Friday, June 8, 2018 at 9:30:55 AM UTC+1, Stefan Pohl wrote:

Albert Silver

unread,
Jun 9, 2018, 2:58:10 PM6/9/18
to LCZero
It is sometimes slow to initialize. My suggestion is to enter the UCI settings and configure the weights file. Also, sometimes just clicking on one move and then another after first starting it resolves the invisible PV issue.

Stefan Pohl

unread,
Jun 10, 2018, 1:27:22 AM6/10/18
to LCZero

- it now does run under Chessbase, but Chessbase will not display its PVs even with the verbose setting on.

 That is a problem of older Fritz/Chessbase versions. I had the same problem (no PVs) with Fritz 13. In Fritz 16, it works.

pwa128

unread,
Jun 10, 2018, 4:34:00 AM6/10/18
to LCZero
Actually LC0 is really quick to initiailise on my machine.   Thanks for the suggestions and I have tried them all repeatedly and in many permutations but with no luck.

pwa128

unread,
Jun 10, 2018, 4:46:19 AM6/10/18
to LCZero
Interesting that a later version of Fritz can run LC0 OK.   BTW Stefan, thanks again for the instructions for installing LC0.

I had a number of hypothesis about why LC0 will not do the PV with Chessbase 12.
But I have:
- checked LC0's output character by character and it looks fine; no dodgy characters, looks fully UCI compliant to me
- checked the CB parameter file and it looks fine
- compared the CB LC0 parameter file with the Cutechess LC0 parameter file and CB Komodo and SF parameter files, but this gives no clues; everything looks comparable; CB clearly can pass parameter names with embedded spaces and true values as required for the verbose setting.

So I have come to a fullstop for the time being and I think the Leela programmers have more important things to concentrate on at the moment.

Stefan Pohl

unread,
Jun 11, 2018, 2:10:05 AM6/11/18
to LCZero
Yes, it is really a mistery. I have really no idea, why the PVs are displayed in Fritz 16 (as far, as I heard from others, in Fritz 14 and 15 LC0 Cuda displays PVs, too), but not in Fritz 13. All I can say, is, that LC0 Cuda plays in Fritz 13, too. When she moves, the PV is displayed. But not, when she thinks. So, you can use LC0 Cuda for playing. But not for analyzing, if you have older Fritz/Chessbase versions. The only solution is to update to new Fritz or new Cehssbase version. Sad. But true.

FWCC1

unread,
Jun 11, 2018, 9:56:34 AM6/11/18
to LCZero
When I get to OpenCL my dialog box closes.I am trying to use GPU Leela
< option name Puct type string default 0.600000
0.344: < option name SlowMover type spin default 89 min 1 max 2147483647
0.344: < option name GoNodesPlayouts type check default false
0.344: < uciok
0.344: > isready
2.031: < Detecting residual layers...v2...192 channels...15 blocks.
3.265: < Initializing OpenCL.
Nothing happens all boxes CLOSE after this
Message has been deleted

Albert Silver

unread,
Jun 11, 2018, 11:24:37 AM6/11/18
to LCZero
It is not just CB programs. Even in Arena I see it sometimes fail to post a PV for 10 seconds, and sometimes it is instant.
Reply all
Reply to author
Forward
0 new messages