Chess Tools for Android

Moderators: Elijah, Igbo, timetraveller

Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

Skynet
Points: 0,00 
Status: Offline (Active 3 Hours, 10 Minutes ago)
Topics: 

Chess Tools for Android

Post by Skynet »

Archimedes wrote:https://github.com/MichaelB7/bayeselo

Latest version from GitHub.

Bayeselo 0058:
https://app.box.com/s/ou4fj4tmkxfm9tvjxuvjb9d0pjqg7foa
Hello! Is there any instructions how to use it on android? :roll:
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

Skynet wrote:Hello! Is there any instructions how to use it on android? :roll:
https://www.remi-coulom.fr/Bayesian-Elo/#usage

It's a command-line tool. You can start it within Termux or with the help of SManager (should work with all apps providing a terminal session where you can start executables).
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

Lately, i wrote a small script for (hopefully) better handling tournaments with c-chess-cli and Bayeselo on Android. It's moreover a working directory, containing all necessary files (start script, executables, opening files, configuration file and so on). Written and tested on Termux.

CETSA 2021.05.20:
https://app.box.com/s/4st1g2eg1nvju4ff2lwddvq5ofsganf6

The following (very) short description assumes that you have already installed Termux and you are aware with basic linux stuff.

Download CETSA (Chess Engine Tournament Script for Android), start Termux and copy the tar archive to the home directory (change the command line for your needs).

Code: Select all

cp /storage/emulated/0/Download/cetsa_2021.05.20.tar.gz ./
Now extract the tar archive as follow.

Code: Select all

tar -xf ./cetsa_2021.05.20.tar.gz
Now you have a directory cetsa in your home directory.

Preparing and starting a tournament can be done in three simple steps now.

1. Copy the engines to the uci directory.

2. Edit the script cetsa.sh and change the parameters in the c-chess-cli section.

Code: Select all

# ----------------------------------------
# c-chess-cli
# ----------------------------------------
../bin/c-chess-cli/$ABI/c-chess-cli -each \
  tc=10+0.1 \
  option.Hash=16 \
  option.Threads=1 \
  -engine cmd=../uci/Arasan "option.OwnBook=false" \
  -engine cmd=../uci/Texel \
  -games 1 \
  -concurrency 1 \
  -openings file=../epd/5mvs_30k_analyzed.epd order=random -repeat \
  -resign number=100 count=5 score=900 \
  -draw number=100 count=5 score=5 \
  -pgn cetsa.pgn 1
# ----------------------------------------
As you can see, each engine has its own command line. About the meaning of the parameters in the c-chess-cli section, please read the documentation on the GitHub site of c-chess-cli at https://github.com/lucasart/c-chess-cli.

3. Start the tournament by executing the script cetsa.sh.

When finished, all generated files will be located in the log directory. The ratings from Bayeseleo, the games in pgn format and some log files (if log is activated). Additionally, all these files will be copied outside the Termux folder to the CETSA_HOME directory (default: /storage/emulated/0/Download).

There are two environment variables used in the script. With ABI you define, what device you are using (only necessary for finding the right executables for c-chess-cli and Bayeselo). With CETSA_HOME you define where the output files will be copied outside of Termux. This is optional. When CETSA_HOME variable is defined and there is an uci folder in that directory, just copy the engines you want to test to that folder. When you execute the script cetsa.sh all engines in that folder will be copied to the uci folder in Termux before the tournament starts. Same principle with the opening files. Create a directory epd in the CETSA_HOME directory and all necessary opening files to it. When starting the script, all files will be copied to the epd folder in Termux. There is no need for a special copy command within Termux for copying this kind of files to the cetsa directory. Use the uci and epd directory in the CETSA_HOME directory for easier file handling.

The cetsa directory contains the following directories.

bin: Contains the executables for c-chess-cli and Bayeselo.
epd: Contains the opening files used by c-chess-cli.
etc: Contains the configuration (command) file for Bayeselo.
log: Contains the output files (rating, games and log files).
uci: Contains the chess engines.
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

Small update. Bayeselo should be computed with mm 0 1 as parameter and i've introduced a new environment variable.

CETSA 2021.05.21:
https://app.box.com/s/vdr01ocyhc04yc1s7mzm0yuawy1o5qug
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

There are some changes in the script. Now you are able to prepare a tournament completely outside of Termux.

When you already have installed CETSA as described above (just extract the tar archive in the home directory of Termux), start Termux and copy the cetsa directory outside of Termux.

Code: Select all

cp -r ./cetsa /storage/emulated/0
Finally, edit the script "start.sh" on Termux as following.

Code: Select all

CETSA_HOME=/storage/emulated/0/cetsa
CETSA_SYNC=true
Preparing a tournament can now be done completely with your favorite tools on Android.

1. Copy the engines you want to test to /storage/emulated/0/cetsa/uci.
2. Edit the configuration file etc/c-chess-cli.conf for your needs (the parameters for c-chess-cli).
3. Start Termux and start the tournament by executing the script "start.sh".

Code: Select all

cd ./cetsa
./start.sh
Preparing a tournament can completely done outside of Termux now. The only thing you have to do in Termux is, starting the tournament.

CETSA 2021.05.23:
https://app.box.com/s/mlwgcopqmp3xnafps1v8mfe7ufs9m89f
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

Installation is much easier now.

Start Termux and copy the tar archive to the home directory (change command line for your needs).

Code: Select all

cp /storage/emulated/0/Download/cetsa_2021.05.24.tar.gz ./
Extract the tar archive.

Code: Select all

tar -xf ./cetsa_2021.05.24.tar.gz
Go to the cetsa directory and start the script.

Code: Select all

cd ./cetsa
./start.sh
Start CETSA and let the script create the CETSA_HOME directory for you.

CETSA 2021.05.24:
https://app.box.com/s/wl5uu6nvmnw52g4ehztkxy3j652ob795
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

New description of CETSA can be found here:
http://talkchess.com/forum3/viewtopic.php?f=2&t=77372
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

CETSA 2021.05.27:
https://app.box.com/s/2bc35bgw8beagv3ptokampqqsd6duxh4

Now with a version number in the script. Added the wake lock feature from Termux (needs a permission when activated). Can be disabled (by disabling the CETSA_WAKE_LOCK environment variable) in the case it doesn't work for you or you want to use other possibilities to prepare Termux from sleeping when screen is off. If enabled (true), tournament is running in the background when screen is off. If disabled (false), tournament is pausing in the background when screen is off (this is a normal behavior on Android). Without the wake lock feature, you have to change some settings in Android for proper running a chess engine tournament in the background as you already know. wink
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

Log files are now archived in separate folders (naming scheme: "yymmdd_HHMMSS") when tournament is over (can be disabled by disabling the CETSA_ARCHIVE variable).

CETSA 2021.05.30:
https://app.box.com/s/3tyzpbbc6nh4zzbt9lebuvltv0chk6cw
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

Small Update. When a tournament is finished, you will see statistic information about the tournament (e. g. number of time forfeits). An additional file c-chess-cli.txt will be created in the log directory with this information.

c-chess-cli.txt:

Code: Select all

3-fold repetition: 16
50 moves rule: 1
Adjudication: 0
Checkmate: 78
Insufficient material: 4
Stalemate: 1
Time forfeit: 0
CETSA 2021.06.11:
https://app.box.com/s/36kl865d97d8at1t4ihg5phka2rfh2rd
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Chess Tools for Android

Post by Archimedes »

Statistic information was not complete. Through c-chess-cli there are two more termination reasons possible ("rules infraction" and "unterminated"). I also included the new version of c-chess-cli.

CETSA 2021.06.12:
https://app.box.com/s/g3bifsza5ykvwhye2mvnsoh2i818xb1m
Walkot
Forum Contributions
Points: 9 587,00 
Posts: 41
Joined: 25/01/2020, 7:24
Status: Offline (Active 10 Months, 3 Days, 22 Hours, 2 Minutes ago)
Topics: 1
Reputation: 14
Been thanked: 17 times

Re: Chess Tools for Android

Post by Walkot »

A good program for working with pgn files. I had an old compilation from Hagtorp, but unfortunately it was gone. PGN—EXTRACT:https://github.com/MichaelB7/pgn-extract.git. And here is a detailed description:https://www.cs.kent.ac.uk/people/staff/djb/pgn-extract/changes.html
Archimedes

Android Engines Top Active Users
Forum Contributions
Points: 42 582,00 
Posts: 2059
Joined: 04/11/2019, 21:13
Status: Offline (Active 6 Hours, 23 Minutes ago)
Medals: 2
Topics: 158
Reputation: 7111
Been thanked: 6477 times

Re: Chess Tools for Android

Post by Archimedes »

Walkot wrote: 09/10/2021, 14:50 A good program for working with pgn files. I had an old compilation from Hagtorp, but unfortunately it was gone. PGN—EXTRACT:https://github.com/MichaelB7/pgn-extract.git. And here is a detailed description:https://www.cs.kent.ac.uk/people/staff/djb/pgn-extract/changes.html
I'm using that tool too, but not on Android, on Windows, as a preparation for making polyglot opening books. First, for checking errors in pgn files (the source files), then, for removing duplicate and unwanted games. For generating polyglot opening books, played by humans, over the board at long time controls. Most opening books out there, are a mixture of human and computer games.

Need to be tested.

pgn-extract 21-02:
https://app.box.com/s/joc3jjvl3hwl3gk8fvykk1n97majdaho
hagtorp
Forum Contributions
Points: 19 796,00 
Posts: 159
Joined: 04/11/2019, 3:15
Status: Offline (Active 6 Months, 3 Weeks, 6 Days, 2 Hours, 43 Minutes ago)
Topics: 3
Reputation: 30
Has thanked: 9 times
Been thanked: 24 times

Re: Chess Tools for Android

Post by hagtorp »

link is dead
Post Reply

Return to “Mobile Chess Software, Engines”