cutechess-cli

Discussion about chess-playing software (engines, hosts, opening books, platforms, etc...)
quantum
Posts: 28
Joined: Mon Dec 19, 2011 12:19 am

cutechess-cli

Post by quantum » Fri May 04, 2012 10:40 pm

I wanted to do some testing between two stockfish versions. I therefore downloaded precompiled packages of cutchess-cli 32/64bit Linux.

When I try to run any of them I get the following message. However the missing lib can be found in the lib subdirectory.

Can somebody tell me what I am doing wrong so far?

tobias@brutus:~/Downloads/cutechess-cli$ ./cutechess-cli
./cutechess-cli: error while loading shared libraries: libcutechess.so.1: cannot open shared object file: No such file or directory

BB+
Posts: 1484
Joined: Thu Jun 10, 2010 4:26 am

Re: cutechess-cli

Post by BB+ » Sat May 05, 2012 7:39 am

However the missing lib can be found in the lib subdirectory.
This is not easy to debug remotely... Maybe the program checks /usr/lib rather than /lib or something? I would probably run strace and see where it is looking for the lib, though I'd guess there's a better utility for dependency-checking (such as ldd -v, somehow?).

Indeed, I downloaded cutechess myself, and got the same problem:
$ ldd cutechess-cli
	libcutechess.so.1 => not found
So it seems the loader doesn't know to look in the local lib directory. There are various ways to fix this, such as including lib in something like the LD_LIBRARY_PATH environment variable. Or by copying the cutechess libs into a standard place (like /lib, or /usr/lib).

Ilari Pihlajisto
Posts: 4
Joined: Thu Jun 10, 2010 6:54 am

Re: cutechess-cli

Post by Ilari Pihlajisto » Sat May 05, 2012 5:21 pm

There's a file named cutechess-cli.sh included in the package. If you run that instead of the binary, it should work. Alternatively you can set LD_LIBRARY_PATH to "./lib" like BB+ said.

quantum
Posts: 28
Joined: Mon Dec 19, 2011 12:19 am

Re: cutechess-cli

Post by quantum » Sat May 05, 2012 9:54 pm

I run strace and copied the libraries to one of the suggested places. Now cutechess does a nice job :)

quantum
Posts: 28
Joined: Mon Dec 19, 2011 12:19 am

Re: cutechess-cli

Post by quantum » Sun May 20, 2012 11:55 am

Hi,

my computer stands near my bed. I hate the fan noises so I shut it down everytime I go to bed.

I want to now if there is a way to pause a match with cutechess and resume the next day.

Greetings

Ilari Pihlajisto
Posts: 4
Joined: Thu Jun 10, 2010 6:54 am

Re: cutechess-cli

Post by Ilari Pihlajisto » Mon May 21, 2012 10:22 am

quantum wrote:Hi,

my computer stands near my bed. I hate the fan noises so I shut it down everytime I go to bed.

I want to now if there is a way to pause a match with cutechess and resume the next day.

Greetings
Unfortunately cutechess-cli doesn't save the progress of the match anywhere but the PGN file, so it's not possible to resume a tournament. But if you're running a match between two engines you can always terminate the match cleanly with CTRL+C and later start a new one with the same PGN output file.

ThinkingALot
Posts: 144
Joined: Sun Jun 13, 2010 7:32 am
Contact:

Re: cutechess-cli

Post by ThinkingALot » Sat Jul 13, 2013 10:45 am

I encountered the following problem running matches with cutechess-cli 0.6.0.
I use a .bat file to run cutechess-cli (Server 2008 R2 x64 OS):

Code: Select all

cutechess-cli -engine name=Gull cmd=Gull.exe -engine name=GullR491 cmd=GullR491.exe -each proto=uci tc=inf depth=7 option.Hash=16 option.Contempt=0 option.Threads=1 restart=off -draw movenumber=20 movecount=3 score=0 -resign movecount=2 score=350 -repeat -openings file=op.epd format=epd -pgnout games.pgn min -rounds 80000 -concurrency 4 -ratinginterval 1
Restart=off. Nevertheless some of the engine instances keep restarting. How to fix this?

lucasart
Posts: 201
Joined: Mon Dec 17, 2012 1:09 pm
Contact:

Re: cutechess-cli

Post by lucasart » Sun Jul 14, 2013 3:37 am

quantum wrote:I wanted to do some testing between two stockfish versions. I therefore downloaded precompiled packages of cutchess-cli 32/64bit Linux.

When I try to run any of them I get the following message. However the missing lib can be found in the lib subdirectory.

Can somebody tell me what I am doing wrong so far?

tobias@brutus:~/Downloads/cutechess-cli$ ./cutechess-cli
./cutechess-cli: error while loading shared libraries: libcutechess.so.1: cannot open shared object file: No such file or directory
The easiest solution is to make static compiles (ie. cutechess-cli and cutechess GUI will both include cutechess-lib in the executable, so you avoid the problem of declaring where the lib is). Step by step instruction:

Code: Select all

$ git clone https://github.com/cutechess/cutechess.git
$ cd cutechess
$ qmake -config static
$ make
This will compile both cutechess-cli and cutechess (GUI).

Pre-requisite: You need to have the following packages installed before
* git
* qt4-dev-tools (a bulky download unfortunately)
* g++ and make (if not already included by qt4-dev-tools)

It is best to compile yourself, because anytime a bugfix is available you can just use a 'git pull' and recompile with qmake and make, rather than wait for months/years for an official compile to come out.
"Talk is cheap. Show me the code." -- Linus Torvalds.

H.G.Muller
Posts: 190
Joined: Sun Jul 14, 2013 10:00 am
Real Name: H.G. Muller

Re: cutechess-cli

Post by H.G.Muller » Sun Jul 14, 2013 11:17 am

quantum wrote:Hi,

my computer stands near my bed. I hate the fan noises so I shut it down everytime I go to bed.

I want to now if there is a way to pause a match with cutechess and resume the next day.

Greetings
Note that WinBoard / XBoard does allow such interruption and resumption of a match when you run it as a tournament (i.e. specify a tournament file when you set it up through the Tournament Options dialog). You can interrupt a running tourney by cliking the 'Mode->Machine Match' menu item, in which case it drops out of match mode after the current game, or by simply closing XBoard (in which case you lose the game in progress).

The next day you can then simply restart the tourney by double-clicking the tourney file.

If you were using concurrency, you would have to do that multiple times (as many times as the number of playing agents you want), just like you had to do to get the concurrency in the first place.

For doing ultra-fast games, XBoard should be run with the option -noGUI, or it would be significantly slower that cutechess-cli.

Note the most recent XBoard also has a Pause mode during a game for when you leave power on (for if you quickly want to do something that requires heavy CPU) using the P button or 'Pause' key.

ChessDrone
Posts: 78
Joined: Mon Jan 28, 2013 10:56 am

Re: cutechess-cli

Post by ChessDrone » Mon Jul 15, 2013 4:35 pm

Anyway to have a graphical interface to configure and launch it on windows?

Post Reply