Python engines with WinBoard 4.8.0 GUI - CuteChess 1.0.0

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Harvey Williamson, bob

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
Post Reply
Norbert Raimund Leisner
Posts: 1572
Joined: Tue May 20, 2008 2:57 pm
Location: Augsburg - Germany

Python engines with WinBoard 4.8.0 GUI - CuteChess 1.0.0

Post by Norbert Raimund Leisner » Tue Jun 04, 2019 7:14 pm

Hello,

I want to embed the following open-source engines into WinBoard 4.8.0 GUI http://www.open-aurec.com/wbforum/viewt ... 19&t=51528 respectively CuteChess 1.0.0 https://github.com/cutechess/cutechess/releases

https://github.com/flok99/feeks

https://github.com/ElliotVilhelm/IZII

https://github.com/stannous/shatranj

https://github.com/thomasahle/sunfish

Except of the first engine, I created batch.files (python -u....) that works with Arena, but not for WinBoard 4.8.0 and/or CuteChess 1.0.0

Python 2.7.16 - 3.7.3 for Windows MSI https://www.python.org/downloads/windows/ are installed on drive C:\

Which data must contain the rows engine(.exe) and commandline-parameters, please? A step-by-step explanation with screenshots would be useful.

Thank you in advance! I ask you because of another Python-Crazyhouse-engine https://github.com/QueensGambit/CrazyAra/releases

pip 19.1.1 and cython 0.29.10 are installed - python-chess (author Niklas Fiekas) too

Norbert

User avatar
hgm
Posts: 23231
Joined: Fri Mar 10, 2006 9:06 am
Location: Amsterdam
Full name: H G Muller
Contact:

Re: Python engines with WinBoard 4.8.0 GUI - CuteChess 1.0.0

Post by hgm » Wed Jun 05, 2019 11:07 am

So what command exactly do you use to run these engines from the command prompt?

Norbert Raimund Leisner
Posts: 1572
Joined: Tue May 20, 2008 2:57 pm
Location: Augsburg - Germany

Re: Python engines with WinBoard 4.8.0 GUI - CuteChess 1.0.0

Post by Norbert Raimund Leisner » Wed Jun 05, 2019 12:32 pm

For Feeks exists a Windows binary - IZII and Sunfish: python -u xboard.py - Shatranj: python -u shatranj.py -xboard

But the command prompt to use Python for Windows MSI is e.g. the problem:

Python 3.7.3 C:\Benutzer \NRL\AppData\Local\Programs\Python\Python37..... - but where can the executable Python file be found? Instead of Python.exe appear now the directories Lib respectively Scripts. Or it is necessary that the missing python.exe file must be copied into this place?

The installation guide of CrazyAra https://github.com/QueensGambit/CrazyAr ... tion-Guide seems to be a mystery...

User avatar
hgm
Posts: 23231
Joined: Fri Mar 10, 2006 9:06 am
Location: Amsterdam
Full name: H G Muller
Contact:

Re: Python engines with WinBoard 4.8.0 GUI - CuteChess 1.0.0

Post by hgm » Wed Jun 05, 2019 2:04 pm

If the plain 'python' command does not work from the command line, then the problem indeed boils down to figuring out where it is. Then you can apply the normal embedding procedure to it: via the Load 1st/2nd Engine dialog of WinBoard browse to python.exe for the exe file, and specify as' command-line parameters' the

-u xboard.py

or the

-u shatranj.py -xboard

For the directory you would have to browse through the directory where the engine script (xboard.py or shatranj.py) is, or it would try to look for those in the same folder as python.exe.

Norbert Raimund Leisner
Posts: 1572
Joined: Tue May 20, 2008 2:57 pm
Location: Augsburg - Germany

Re: Python engines with WinBoard 4.8.0 GUI - CuteChess 1.0.0

Post by Norbert Raimund Leisner » Sun Jun 09, 2019 11:40 am

only Sunfish https://github.com/thomasahle/sunfish works correctly with Engine (.exe) C:\Users\NRL\Downloads\Python37\python.exe and commandline-parameter -u xboard.py, all other engines exited unexpectedly:

Shatranj https://github.com/stannous/shatranj , but batch-file python -u shatranj.py -xboard is o.k. with Arena 3.5.1 GUI

IZII https://github.com/ElliotVilhelm/IZII, but batch-file python -u xboard.py is o.k. with Arena 3.5.1 GUI

What can be done in your opinion? Could HGM enhance WinBoard AA-beta http://hgm.nubati.net/WinBoard-AA.zip or v4.8.0 in a way that batch-files can be used like executables and jar?

By the way: the same error message with WinBoard 4.8.0 http://www.open-aurec.com/wbforum/viewt ... 19&t=51528

For Python programmers: It is possible to build Windows binaries of Sunfish, Shatranj and IZII with PyInstaller https://github.com/pyinstaller/pyinstaller , please?

Norbert

Norbert Raimund Leisner
Posts: 1572
Joined: Tue May 20, 2008 2:57 pm
Location: Augsburg - Germany

Re: Python engines with WinBoard 4.8.0 GUI - CuteChess 1.0.0

Post by Norbert Raimund Leisner » Fri Jun 14, 2019 5:54 pm

Hello, except of Feeks https://github.com/flok99/feeks I was able to run now other Python engines with Python 3.7.3 win32 www.python.org including pip install python-chess (v0.28.0) on WinBoard AA-beta (protocol autodetect) http://hgm.nubati.net/WinBoard-AA.zip (cf. survey below)
Engine (.exe) C:\Users\NRL\Dowsloads\Python3.7.3\python.exe
command-line parameters-u main.py - but nothing happened
Which data must contain the commandline-parameter and exists a possibility to create a new Windows binary (.exe) of Feeks again?
The complete data of the extracted Feeks folder and python.exe are situated into the same directory.

Regards,
Norbert


Elliot´s IZII
"python.exe -u xboard.py" -fd "C:\Users\NRL\Downloads\Python3.7.3"
Engine (.exe)
C:\Users\NRL\Dowsloads\Python3.7.3\python.exe
command-line parameters
-u xboard.py

Julien´s chess3 0.2
"python.exe -u chess3.py" -fd "C:\Users\NRL\Downloads\Python3.7.3"
C:\Users\NRL\Downloads\Python3.7.3\python.exe
command-line parameters
-u chess3.py

PyTuroChamp
"python.exe -u ptc_xboard.py" -fd "C:\Users\NRL\Downloads\Python3.7.3"
Engine (.exe)
C:\Users\NRL\Downloads\Python3.7.3\python.exe
command-line parameters
-u ptc_xboard.py

Shatranj1.18
"python.exe -u shatranj.py -xboard" -fd: "C:\Users\NRL\Downloads\Python2.7.16"
Engine (.exe)
C:\Users\NRL\Downloads\Python2.7.16\python.exe
commandline-parameters
-u shatranj.py -xboard

Sunfish
"python.exe -u xboard.py" -fd "C:\Users\NRL\Downloads\Python3.7.3"
Engine (.exe)
C:\Users\NRL\Dowsloads\Python3.7.3\python.exe
command-line parameters
-u xboard.py

Norbert Raimund Leisner
Posts: 1572
Joined: Tue May 20, 2008 2:57 pm
Location: Augsburg - Germany

Re: Python engines with WinBoard 4.8.0 GUI - CuteChess 1.0.0

Post by Norbert Raimund Leisner » Fri Jun 14, 2019 8:30 pm

CrazyAra 0.4.0 Crazyhouse UCI
"python.exe -u crazyara.py" - fd "C:\Users\NRL\Downloads\Python37" -fUCI
Engine (.exe) C:\Users\NRL\Downloads\Python37\python.exe
commandline-parameter -u crazyara.py

GUI WinBoard AA-beta http://hgm.nubati.net/WinBoard-AA.zip, Windows 7 64-bit

Post Reply