Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Easiest instructions so far for windows x64 #88

Closed
jjoshua2 opened this issue Mar 2, 2018 · 56 comments
Closed

Easiest instructions so far for windows x64 #88

jjoshua2 opened this issue Mar 2, 2018 · 56 comments

Comments

@jjoshua2
Copy link
Contributor

jjoshua2 commented Mar 2, 2018

Download client.exe here:
https://github.com/glinscott/leela-chess/releases/download/v0.2/client.exe
Then download leela go here and take out the openblas and opencl dll files:
https://github.com/gcp/leela-zero/releases/download/v0.12/leela-zero-0.12-win64.zip
Then download lczero here:
https://ci.appveyor.com/api/buildjobs/crtkeprmm0lxblc5/artifacts/build%2FRelease%2Flczero.exe
Put client, the 2 dlls, and lczero into a folder, and use the command line (shift+right click a blank white space in the folder and select open powershell/command window here) to run with your custom username and password:
./client.exe -user MYUSERNAME -password MYPASSWORD

EASYMODE - client.exe v1 and all required dlls along with a bat file that you double click to start - just add latest lczero:
https://ufile.io/gy83r Edit: https://ufile.io/1gisa has bat file without the ./ that is working better for people (and more days till expiry).

(You can edit the username and password in the bat file to make yours unique so you don't get banned if someone else misuses this)
EASYMODE zip file scanned. the client.exe has 1/67 false positive and the ddls are 0 detected
https://www.virustotal.com/#/file/b26f81e80e01bda8075fc3fa97cc8ff4c1ce57df70c4cbc3239932c4b6128a18/relations

If you want to run lczero.exe by itself you will need the 2 dlls and a weights file 3/7/18

@jjoshua2 jjoshua2 mentioned this issue Mar 2, 2018
@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 2, 2018

lczero.exe is the only one that is being updated frequently. To grab a new release of lczero go to:
https://ci.appveyor.com/project/glinscott/leela-chess/branch/master
Then click on a job name which will get you to a page that looks like this:
https://ci.appveyor.com/project/glinscott/leela-chess/build/job/23bv1ipyftlkl8ji
and then click artifacts which will take you to a page that looks like this:
https://ci.appveyor.com/project/glinscott/leela-chess/build/job/23bv1ipyftlkl8ji/artifacts
which has the lczero.exe link in blue.

@jkiliani
Copy link
Contributor

jkiliani commented Mar 2, 2018

While Client.exe is the functional equivalent of AutoGTP, it is not the same name of the binary. Please update the instructions to replace autogtp with client.

Edit 2: Looks correct but I'm going to try following it to the letter with Windows soon. If anyone who needs the instructions tries them and it doesn't work, please give detailed feedback.

@kris-computer-go
Copy link

Thanks, it works.
It is possible to run many instances at once (each uses 2 threads by default).
What is purpose of directory data-1 (it is empty all the time)?
How to save all generated pgn files?

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 2, 2018

You can run client.exe multiple times for sure until it uses most of your GPU. I believe there is also a way to tell it to run multiples games and configure threads used.
When a game is produced it is stored into data-1. It is then uploaded and deleted. So it is only empty most of the time. If you have an internet outage it should store games processed and upload them all once you reconnect.
You can see your generated uploaded games http://162.217.248.187/ and click your username. You could also edit the source code and recompile to not delete uploaded games. Maybe someone will make that a command line option.

@brianprichardson
Copy link

brianprichardson commented Mar 2, 2018

Nevermind. Somehow my Cuda, OpenCL and other things got "lost" per GPU-Z and GPU Caps Viewer. Updated graphics driver and things are back and working fine at least for one game...

Problem was:
Win7 client ran for a while.
Now just says:
exit status 3

Tried just lczero:
C:\leela-chess>lczero.exe --weights=seed-64x6.txt
Generated 1924 moves
Detecting residual layers...v1...64 channels...6 blocks.
Initializing OpenCL.
OpenCL: clGetPlatformIDs

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 2, 2018

Updated lczero.exe link

@brianprichardson
Copy link

In start.bat shouldn't it be just client.exe (without the ./ for Windows)?

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 2, 2018 via email

@brianprichardson
Copy link

Ah, I just use cmd, not PowerShell. For cmd, the ./ does not work.

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 4, 2018

sent an email to cylance to report the false positive for the official release client.exe that virus total flags 1/67

@glinscott
Copy link
Owner

Thanks for setting this up! I will try and figure out how to package the dll's automatically through the appveyor build.

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 5, 2018

Updated lczero.exe again

@Zeta36
Copy link

Zeta36 commented Mar 6, 2018

This info should be in the Readme.md, isn't it?

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 6, 2018 via email

@Zeta36
Copy link

Zeta36 commented Mar 6, 2018

I followed these instructions and it worked perfectly for me!! (Windows 10 - Intel i5).

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 6, 2018

Updated lczero.exe

@Ipmanchess
Copy link

Maybe interesting would be that there is a normal Windows/Linux UCI compile like every month or so ,no matter what stenght it has at the moment that we as testers or people who wants to play a play with it have a idea how strong it is and can follow the progress from this engine!

Or is the meaning to let it train/learn till it's stronger then Stockfish first?
I think it would be more fun that many people could follow this progress!

Fantastic work you do guys!!
Ipman.

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 7, 2018

Updated lczero.exe. @Ipmanchess lczero.exe is a normal windows uci compile, it just happens to need a weights file to work as one of its parameters.

@Ipmanchess
Copy link

Can you Edit first post with a direct download with these weights file..
When i download and dubble click engine i get OpenCL.dll missing?

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 7, 2018

The two dlls files are in the easymode zip https://ufile.io/gy83r, and I edited to put the latest weights at the bottom, although I will probably not keep that link up to date with the strongest weights, which is the top one available here: http://162.217.248.187/networks
If you wish to contribute with client.exe it automatically downloads the latest network whenever it is updated.
As of 3/7/18 it barely knows material and sometimes leaves pieces hanging or doesn't capture, but each network has won like 49 - 1 against the previous

@Ipmanchess
Copy link

Thank you..
I have put the files in one folder.. easymode.zip files + weights + lczero.exe
Dubble click.. engine open and close directly?
Still not right..

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 7, 2018

I am using powershell and have a networks folder. I start it with this command.

.\lczero.exe -w .\networks\45bff022a3d87c09d4f8151757fc4bd200b86115f1825c1016afcc2943cf21
ef

And I can then type in things like uci or isready or go and see the appropriate uci responses.

I think you are missing the -w flag with the name of the weight you downloaded. (it must be decompressed) So its not just double click currently.

@JackThomson2
Copy link
Contributor

When working on the distributed training I hit an error running two clients, They seem to sometimes collide causing one to throw an error with 'exit status 3221226505' Any idea how this could be combatted as I have some more compute power to throw!

@JackThomson2
Copy link
Contributor

Fixed this issue with recompiling the Go client ;)

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 9, 2018

@JackThomson2 Hopefully you mean chess client. Glad you fixed though. Updated exe link.

@JackThomson2
Copy link
Contributor

No there was a problem with the Go client in the download it tried to save the game to the same location. I downloaded the source and recompiled, and all is fine.

@bpgbcg
Copy link

bpgbcg commented Mar 9, 2018

I have client.exe, libopenblas.dll, OpenCL.dll, start.bat, and lczero.exe in a folder together. When I double-click start.bat a black box pops up briefly (looks like cmd?) for a fraction of a second and then immediately disappears. I'm probably doing something wrong but I'm not sure what...?

@jjoshua2
Copy link
Contributor Author

Updated lczero.exe

@jjoshua2
Copy link
Contributor Author

jjoshua2 commented Mar 14, 2018

I found a possible error that can cause a weird exit code for client.exe when it tries to run lczero. Sometimes windows smartscreen blocks a downloaded exe, and you have to right click it and go to properties, and uncheck the blocked box.

@mooskagh
Copy link
Contributor

mooskagh commented Mar 14, 2018 via email

@jjoshua2
Copy link
Contributor Author

Updated lczero. This one is a nice speed boost.

@Error323
Copy link
Collaborator

Awesome man! Thanks for doing this!

@jjoshua2
Copy link
Contributor Author

@Error323 Your welcome. But really, client should download new lczero automatically, because people like me and those who run won't always have this much patience to always be on top of everything and work on it.

@jkiliani
Copy link
Contributor

I'm not sure that's practical... even for Leela Zero which is a far more mature project, people have to update their client manually. I think most developers hesitate to program code that automatically downloads and runs binaries from the internet, since this has security implications and would also be considered malware by many Virus scanners.

@jjoshua2
Copy link
Contributor Author

I get your point, but programs like BOINC do this. Maybe it is better to just switch to that network and get all of its benefits like checkpointing, resuming, auto start, instead of implementing things all over.

@jjoshua2
Copy link
Contributor Author

Leela chess updated with a bugfix for 50 move rule, among other things

@MathAndreas
Copy link

Thank you for making installation easier.
I am a big fan of this project, but I didnt succeed to get the client running for some time,
until I discovered that there were two required DLLs still missing which are not installed on
many Windows computers, because they are not part of a normal Windows installation:
vcruntime140.dll and msvcp140.dll
These are part of Visual C++ Redistributable for Visual Studio 2015.
There were several other programs on my computer which installed these DLLs, but only in their directory, not in the system dir. They are not installed by LeelaZero.
I wonder if I am the first one to discover that.
We should of course install these two DLLs in the LeelaChessZero dir, as part of the installation package.

@panNorton
Copy link

@MathAndreas tried this also with different versions of vcredist and I still get an exit status 3221226505. How did you troubleshoot to discover that these two DLLs are missing?

@glinscott
Copy link
Owner

This is fantastic. Can someone update the wiki page here: https://github.com/glinscott/leela-chess/wiki/Getting-Started with this information? Then I will link it from the main page. I don't really want to link to a specific github issue.

@MathAndreas
Copy link

I used the tool Listdlls64.exe

@Uriopass
Copy link
Contributor

@glinscott I just updated the wiki page with windows instructions :
https://github.com/glinscott/leela-chess/wiki/Getting-Started
I think you can link it from lczero.org now.

@MathAndreas
Copy link

@glinscott What is fantastic? The instructions given here?
Sorry, but it would be much more user friendly to offer a download of one zip-file, like
leela-zero does: https://github.com/gcp/leela-zero/releases
This should of course contain all needed DLLs, but at least two other DLLs are still missing, see my post above. And also panNorton's problem posted above must be solved.

This project is great, and thank you for all your work. But we should win more people running the client,
therefore we need to make it very easy to download and run it, even for people with only basic IT knowledge.
The v2 client is great, a big step forward.

It is quite easy to assemble the installation zip-file. I could do it for you. By the way I am an experienced software developer, and I could do other work for the project as well.

@Uriopass
Copy link
Contributor

By the way I am an experienced software developer, and I could do other work for the project as well

Nothing is stopping you :-)

@killerducky
Copy link
Collaborator

@MathAndreas looking forward to your first pull request. :)

Seriously we can really use some more developers. There are many good ideas in these threads and not enough people to implement them.

@pw31
Copy link

pw31 commented Mar 27, 2018

Was anyone successful to run LCzero on Windows7? I followed the instructions to put latest lczero.exe and all .dll into a directory:

27/03/2018 19:58 739,840 lczero.exe
23/03/2018 08:37 120,334 libgcc_s_dw2-1.dll
23/03/2018 08:37 30,533,118 libopenblas.dll
23/03/2018 08:37 1,540,622 libstdc++-6.dll
23/03/2018 08:37 79,360 libwinpthread-1.dll
23/03/2018 08:37 2,983,837 msys-2.0.dll
23/03/2018 08:37 112,382 msys-gcc_s-1.dll
22/03/2018 21:07 53,644,453 network_ID22
27/03/2018 16:32 54,035,359 network_ID45
23/03/2018 08:37 103,424 OpenCL.dll
23/03/2018 08:37 6,097,408 Qt5Core.dll

when I run it like this in a command line: lczero -w network_ID45 I get

Generated 1924 moves
Detecting residual layers...v1...64 channels...6 blocks.
Initializing OpenCL.
Detected 1 OpenCL platforms.
Platform version: OpenCL 1.1 CUDA 6.0.1
Platform profile: FULL_PROFILE
Platform name: NVIDIA CUDA
Platform vendor: NVIDIA Corporation
Device ID: 0
Device name: GeForce GT 525M
Device type: GPU
Device vendor: NVIDIA Corporation
Device driver: 334.89
Device speed: 1200 MHz
Device cores: 2 CU
Device score: 1111
Selected platform: NVIDIA CUDA
Selected device: GeForce GT 525M
with OpenCL 1.1 capability.
Loaded existing SGEMM tuning.
Wavefront/Warp size: 32
Max workgroup size: 1024
Max workgroup dimensions: 1024 1024 64
BLAS Core: Sandybridge

and then nothing happens, lczero stays as an active job - looks good, doesn't it?
(how can I check it's working under command line?)

But when I try to use lczero as an engine under Scid:
command: C:/Users/pw31/Documents/Schach/LCzero/lczero.exe
parameter -w network_ID45
parameter: C:/Users/pw31/Documents/Schach/LCzero/
UCI: unchecked

it takes about 10sec, then error message "lczero.exe. has stopped working"
apperars. Any idea? Thanks

@pw31
Copy link

pw31 commented Mar 27, 2018

addition: under command line I get same problem:

C:\Users\pw31\Documents\Schach\LCzero>lczero.exe -w network_ID45
Generated 1924 moves
Detecting residual layers...v1...64 channels...6 blocks.
Initializing OpenCL.
Detected 1 OpenCL platforms.
Platform version: OpenCL 1.1 CUDA 6.0.1
Platform profile: FULL_PROFILE
Platform name: NVIDIA CUDA
Platform vendor: NVIDIA Corporation
Device ID: 0
Device name: GeForce GT 525M
Device type: GPU
Device vendor: NVIDIA Corporation
Device driver: 334.89
Device speed: 1200 MHz
Device cores: 2 CU
Device score: 1111
Selected platform: NVIDIA CUDA
Selected device: GeForce GT 525M
with OpenCL 1.1 capability.
Loaded existing SGEMM tuning.
Wavefront/Warp size: 32
Max workgroup size: 1024
Max workgroup dimensions: 1024 1024 64
BLAS Core: Sandybridge

isready
readyok
go

leads to "lczero.exe has stopped working"

@brianprichardson
Copy link

after the BLAS core message try the "uci" command and wait (before the "isready"), although it might not matter.

Then is the "isready" command and wait for the readyok.

Then "go" should work, although it make take quite some time.

@pw31
Copy link

pw31 commented Mar 29, 2018

I downloaded release v0.4 files, did the "uci", "isready", and "go" commands:
...
BLAS Core: Sandybridge
uci
id name lczero
uciok
isready
readyok
go

still the result is a crash:
Problem signature:
Problem Event Name: APPCRASH
Application Name: lczero.exe
Application Version: 0.0.0.0
Application Timestamp: 5abc5dd0
Fault Module Name: ucrtbase.DLL
Fault Module Version: 10.0.10586.788
Fault Module Timestamp: 5879ab76
Exception Code: 40000015
Exception Offset: 000000000006990f
OS Version: 6.1.7601.2.1.0.768.3
Locale ID: 2057
Additional Information 1: 517f
Additional Information 2: 517fec20d81876aeb4aaeaa3665497e2
Additional Information 3: 515b
Additional Information 4: 515bc60433f443fe9ea8ea3d79a4d02c

@Uriopass
Copy link
Contributor

Did you install the VC Redist ?

@pw31
Copy link

pw31 commented Mar 29, 2018

What is VC Redist and how do I install it, please? I am usually a Linux person, so I have little experience with Windows. (to explain, my Linux Ubuntu 14.04 has too old gcc to compile under Linux, so I thought I try windows ...)

@Uriopass
Copy link
Contributor

On the wiki, there's a section about this, in the getting started ;)

@pw31
Copy link

pw31 commented Mar 30, 2018

@Uriopass : thanks, unfortunately my problem isn't solved yet.

  • I dowloaded https://go.microsoft.com/fwlink/?LinkId=746572 and ran the executable
    to install the VC Redistributable (I think it installed 2017 version contary to what is said in wiki)
  • There are other VC Redistrbutables on my system: 2008, 2010, 2013, is this problem?
  • I rebooted my computer
  • I can run "lczero -w network_ID61 --tune-only" no problem, it creates leelaz_opencl_tuning
  • I ran "lczero -w network_ID61 --noponder"
    ...
    BLAS Core: Sandybridge
    uci
    uciok
    isready
    readyok
    go
    -> crash with same report on fault in ucrtbase.DLL

I used LoadedDllsView to find where that DLL is coming from and saw that there is a newer version in C:\Program Files (x86)\Mozilla Firefox\ucrtbase.dll. So I copied it to the lczero directory and tried again. Error message now is

Problem signature:
Problem Event Name: APPCRASH
Application Name: lczero.exe
Application Version: 0.0.0.0
Application Timestamp: 5abc5dd0
Fault Module Name: ucrtbase.DLL
Fault Module Version: 10.0.16299.15
Fault Module Timestamp: 70f70cc4
Exception Code: 40000015
Exception Offset: 000000000006b71f
OS Version: 6.1.7601.2.1.0.768.3
Locale ID: 2057
Additional Information 1: 517f
Additional Information 2: 517fec20d81876aeb4aaeaa3665497e2
Additional Information 3: 478f
Additional Information 4: 478fdf61c4505df0e040dc3e302399dc

which shows that the newer version of ucrtbase.dll was actually used, but no success, alas!

@pw31
Copy link

pw31 commented Mar 30, 2018

Addition: I can run the CPU-only version fine with scid.

@pw31
Copy link

pw31 commented May 2, 2018

Addition: after a long struggle, I can run the default version with GPU-support now after updating the NVIDIA driver from http://www.nvidia.co.uk/Download/index.aspx?lang=en-uk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests