It is currently Thu Apr 18, 2024 6:14 am

All times are UTC - 8 hours [ DST ]




Post new topic Reply to topic  [ 26 posts ]  Go to page Previous  1, 2
Author Message
Offline
 Post subject: Re: Compiling some engines for linux
Post #21 Posted: Sat Mar 16, 2019 3:02 am 
Lives with ko
User avatar

Posts: 284
Liked others: 94
Was liked: 153
Rank: OGS 7 kyu
xela wrote:
Phoenix Go

I gave up on this one. I tried following the instructions at https://github.com/Tencent/PhoenixGo The problem is that it uses bazel as its build system, which is new to me, so I'm not well qualified to troubleshoot the problems. Bazel will download a few hundred megabytes of stuff, then try to build TensorFlow configured according to the selected PhoenixGo options, spit out a bunch of compiler warnings, then fail on one of the TensorFlow components. I didn't want to keep retrying it because it's downloading an awful lot of stuff each time. I did find some old forum posts saying that TensorFlow won't work with bazel version 12 or 13, so you should use bazel 11. I tried that, as well as the newest bazel (version 17), with the same results each time.
This is just to mention that the instructions for compilation were added on the github project page. Easy enough for me to be able to compile and run it.

_________________
I am the author of GoReviewPartner, a small software aimed at assisting reviewing a game of Go. Give it a try!

Top
 Profile  
 
Offline
 Post subject: Re: Compiling some engines for linux
Post #22 Posted: Sat Mar 16, 2019 3:44 am 
Lives in gote

Posts: 586
Location: Adelaide, South Australia
Liked others: 208
Was liked: 265
Rank: Australian 2 dan
GD Posts: 200
pnprog wrote:
This is just to mention that the instructions for compilation were added on the github project page. Easy enough for me to be able to compile and run it.

Glad to hear that it worked for you! The instructions don't seem to have changed since I tried in September, except that the current version of bazel is now 19 not 17. Maybe a bazel update has fixed the problem?

Top
 Profile  
 
Offline
 Post subject: Re: Compiling some engines for linux
Post #23 Posted: Sat Mar 16, 2019 7:53 am 
Lives with ko
User avatar

Posts: 284
Liked others: 94
Was liked: 153
Rank: OGS 7 kyu
xela wrote:
pnprog wrote:
This is just to mention that the instructions for compilation were added on the github project page. Easy enough for me to be able to compile and run it.

Glad to hear that it worked for you! The instructions don't seem to have changed since I tried in September, except that the current version of bazel is now 19 not 17. Maybe a bazel update has fixed the problem?

Here are the condensed instructions that are working for me: https://github.com/Tencent/PhoenixGo/blob/master/docs/FAQ.md/#b0-it-is-too-hard-to-install-bazel-or-start-bazel

It tells how to install bazel which is useful to install AQ (i am on it right now).

_________________
I am the author of GoReviewPartner, a small software aimed at assisting reviewing a game of Go. Give it a try!

Top
 Profile  
 
Offline
 Post subject: Re: Compiling some engines for linux
Post #24 Posted: Sat Mar 16, 2019 10:01 am 
Lives with ko
User avatar

Posts: 284
Liked others: 94
Was liked: 153
Rank: OGS 7 kyu
I also went again through the compilation of Ray. One thing is different now, git needs the --recursive option to fetch some code for the src/lz/Eigen folder.

Code:
sudo apt install libatlas-base-dev #there are other dependancy, but that one in particular was missing for me
git clone --recursive https://github.com/zakki/Ray.git --branch lz --single-branch .
make


The compilation will still fail, with errors such as:
Code:
src/UctSearch.cpp:1694:41: error: no matching function for call to ‘atomic_fetch_add(std::atomic<long unsigned int>*, int&)’
     atomic_fetch_add(&depth_sum, c.depth);
...
                                         ^
src/UctSearch.cpp:1695:37: error: no matching function for call to ‘atomic_fetch_add(std::atomic<long unsigned int>*, int)’
     atomic_fetch_add(&depth_count, 1);
                                     ^
...
Makefile:24: recipe for target 'src/UctSearch.o' failed
make: *** [src/UctSearch.o] Error 1

I found out that replacing lines 219/220 in src/UctSearch.cpp as follow fixes the issue:
Before:
Code:
static std::atomic<uint64_t> depth_count;
static std::atomic<uint64_t> depth_sum;

After:
Code:
static std::atomic<double> depth_count;
static std::atomic<double> depth_sum;

This also work, but I have no idea what the difference mean:
Code:
static std::atomic<double_t> depth_count;
static std::atomic<double_t> depth_sum;

It's used to calculate and display the average tree search depth, so nothing critical I guess. Anyway, I sent a PR to the project.

_________________
I am the author of GoReviewPartner, a small software aimed at assisting reviewing a game of Go. Give it a try!

Top
 Profile  
 
Offline
 Post subject: Re: Compiling some engines for linux
Post #25 Posted: Sat Mar 16, 2019 9:04 pm 
Lives with ko
User avatar

Posts: 284
Liked others: 94
Was liked: 153
Rank: OGS 7 kyu
pnprog wrote:
It tells how to install bazel which is useful to install AQ (i am on it right now).

I must admit I could not make that one work. I can compile, but the binary crashes when issuing genmove b command :(
Maybe I should try with an older version of bazel (I have been using version 19)

_________________
I am the author of GoReviewPartner, a small software aimed at assisting reviewing a game of Go. Give it a try!

Top
 Profile  
 
Offline
 Post subject: Re: Compiling some engines for linux
Post #26 Posted: Sat Oct 19, 2019 8:48 pm 
Lives in gote

Posts: 586
Location: Adelaide, South Australia
Liked others: 208
Was liked: 265
Rank: Australian 2 dan
GD Posts: 200
Not an engine as such, but just as useful: I've just installed the fantastic q5Go version 9. Getting the source code from GitHub was easy, and it should build and install exactly as per the instructions, except for one minor but annoying detail.

q5Go relies on Qt version 5.10, but the official Ubuntu repositories only have Q5 version 5.9, and there are conflicting and confusing instructions on how to upgrade. It turns out that you can install Qt 5.12 into its own folder without messing up your "official" Ubuntu installation.

  • Download the Qt installer from http://download.qt.io/official_releases/qt/5.12/5.12.5/
  • Run the installer (chmod a+x longfilename.run, then ./longfilename.run). When it asks you to create/sign in to an account, just skip that step. Create a new directory to install into: let's say you've put it into /opt/qt5.12
  • Create a file called ~/.config/qtchooser/qt5.12.conf. The file should contain two lines with the bin and lib directories of your new installation -- e.g. they might be /opt/qt5.12/5.12.5/gcc_64/bin and /opt/qt5.12/5.12.5/gcc_64/lib
  • Test: type the command
    Code:
    qmake -qt=qt5.12 -v
    It should show you the version number that you installed (5.12.5 at the time of writing) and the (stuff)/lib directory name.
  • When you're building q5Go, replace
    Code:
    qmake
    with
    Code:
    qmake -qt=qt5.12
    For other projects, if you use plain qmake without the -qt bit, it will fall back to using your standard Qt installation.

From here you should be able to follow the instructions on GitHub.

Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 26 posts ]  Go to page Previous  1, 2

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group