Dirk
--
You received this message because you are subscribed to the Google Groups "PicoChess" group.
To unsubscribe from this group and stop receiving emails from it, send an email to picochess+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Dirk

But then the description:
# XBoard/UCI interface to PyTuroChamp
and the variable
is_uci
are somehow misleading.
Anyway - I give up, it was a nice try.
Thanks for helping, Shiv!
Regards
Dirk
--
You received this message because you are subscribed to the Google Groups "PicoChess" group.
To unsubscribe from this group and stop receiving emails from it, send an email to picochess+...@googlegroups.com.
Regards
Dirk
To unsubscribe from this group and stop receiving emails from it, send an email to picochess+...@googlegroups.com.
So in principle I am sure it would work somehow but as I have written it seems to be in an endless loop or crashed when choosing this engine.
But anyway - I am no expert and stop trworking on this and just user Arena with windows version.
Thank you all for helping.
Dirk
Found this issue thread on Github for PyTuroChamp regarding the issue calling a "shell script engine" (with the real engine running in python like pico chess itself).
"Interfacing an UCI Python chess engine to python-chess on Linux #261"
https://github.com/niklasf/python-chess/issues/261
Seems like the shell script communication does not support the UCI interface communication but I don not really understand the problem and what could be a fix.
Dirk
I am finally able to call the (python) PyTuroChamp engine from Picochess and could play the first moves again the world famous "paper engine" by Alan Turing (think of that: it took Turing multiple hours to calculate and execute the next move with his algorithm on paper ;-) although the python implementation of TuroChamp is also not the fastest one...
The solution is quite easy (after lots of try & errors):
Instead of using a shell script (I even tried to transfer the shell script to C and then compile this generated C code to get an executable engine for picochess!) we can directly use the python uci wrapper file after renaming and adding a soft link to this file in the picochess engines directory (here armv7l).
Then the python file can be used like a native executable chess engine for picochess (and not only the TuroChamp engine but python engines in general).
So far so good.
But...
Unfortunately I can only play two moves (starting as white - with black even only one move) before the engine stops working.
The clock suddenly stops without any information and I have to reboot.
Maybe someone can give me a hint what the real cause can be I only have a guess because I can't really read & understand the picochess log file.
My guess is that some UCI commands are just not fully implemented in the ici wrapper file ptc_xboard.py.
It must have something to do with the communication transfer of the human reply move after the initial one (first one when playing white is fine).
I assume there must be a difference how the first move is giving to the engine and all the follow up moves because with the first follow up move the engine stops working.
When playing interactively with the engine I can play a game without any problem by entering the moves one by one:
pi@DGTPi:~ $ /home/pi/PyTuroChamp/ptc_xboard.py
uci
uciok
ucinewgame
e2e4
# -5.40 ['e7e6']
bestmove e7e6
d2d4
# -2.80 ['h7h5']
bestmove h7h5
g1f3
# -2.80 ['a7a5']
bestmove a7a5
ucinewgame
go
# 23.80 ['e2e3']
bestmove e2e3
e7e5
# 2.80 ['h2h4']
bestmove h2h4
quit
pi@DGTPi:~ $
But within picochess I can play only one move, get the response move and when trying to play second move the engine stops after a while.
The picochess error in the log says something like
ValueError("illegal uci: {0} in {1}".format(repr(uci), self.fen()))
ValueError: illegal uci: 'd2d4' in rnbqkbnr/pppp1ppp/4p3/8/3PP3/8/PPP2PPP/RNBQKBNR b KQkq - 0 2
After playing e2e4 and getting the answer e7e6 and playing the next move d2d4 the log looks fine to me:
2018-06-23 15:45:33.404 DEBUG board - _read_board_message: (ser) board get [DgtMsg.DGT_MSG_BOARD_DUMP] length: 64
2018-06-23 15:45:33.451 DEBUG board - _process_board_message:
rnbqkbnr
pppp.ppp
....p...
........
...PP...
........
PPP..PPP
RNBQKBNR
2018-06-23 15:45:33.453 DEBUG board - _process_board_message: raw fen [rnbqkbnr/pppp1ppp/4p3/8/3PP3/8/PPP2PPP/RNBQKBNR]
2018-06-23 15:45:33.456 DEBUG display - run: received message from msg_queue: MSG_DGT_FEN
2018-06-23 15:45:33.464 DEBUG display - _process_fen: DGT-Fen [rnbqkbnr/pppp1ppp/4p3/8/3PP3/8/PPP2PPP/RNBQKBNR]
2018-06-23 15:45:33.469 DEBUG picochess - main: received event from evt_queue: EVT_FEN
But after a while the picochess stops (I assume when engine comes back with the answer move).
Maybe someone has an idea what could be the cause for that and why the first move could be played without any problems and from second on the problem occurs (although interactively I could play without any problem).
Thanks for helping
Dirk
It seems I was right with my assumption (although I have no python or "inner" picochess knowledge - maybe I should join the circle of picochess developer ;-)
I have asked Martin (author of PyTuroChamp) to include the UCI command "position fen moves" - he just updated the code of ptc_xboard.py.
I have downloaded it again and tried it:
Now it works like expected.
I am so happy know to have this engine - although it is really slow (but not as the original paper engine ;-)
If you want the original Turing machine (also the same algorithm Kasparov played, see here: Alan Turing's 60-year-old chess program takes on Garry Kasparov
https://www.theverge.com/2012/6/26/3119022/alan-turing-60-year-old-chess-program-garry-kasparov) and get a faster Turochamp engine you should modify the pyturochamp.py file change at the beginning of the file:
MAXPLIES = 2 # maximum search depth
QPLIES = MAXPLIES + 4
PSTAB = 0 # influence of piece-square table on moves, 0 = none
Cheers
Dirk
sudo nano "turing.uci"
[TuroChamp]
maxplies = 2
pstab = 0
[normal]
maxplies = 3
pstab = 5
Maybe this will be added to Github later...
Alan Mathison Turing OBE FRS (/ˈtjʊərɪŋ/; 23 June 1912 – 7 June 1954) was an English computer scientist, mathematician, logician, cryptanalyst, philosopher, and theoretical biologist.[2] Turing was highly influential in the development of theoretical computer science, providing a formalisation of the concepts of algorithm and computation with the Turing machine, which can be considered a model of a general purpose computer.[7][8][9] Turing is widely considered to be the father of theoretical computer science and artificial intelligence.[10]
During the Second World War, Turing worked for the Government Code and Cypher School (GC&CS) at Bletchley Park, Britain's codebreaking centre that produced Ultra intelligence. For a time he led Hut 8, the section which was responsible for German naval cryptanalysis. Here he devised a number of techniques for speeding the breaking of German ciphers, including improvements to the pre-war Polish bombe method, an electromechanicalmachine that could find settings for the Enigma machine. Turing played a pivotal role in cracking intercepted coded messages that enabled the Allies to defeat the Nazis in many crucial engagements, including the Battle of the Atlantic, and in so doing helped win the war.[11][12] Counterfactual history is difficult with respect to the effect Ultra intelligence had on the length of the war,[13] but at the upper end it has been estimated that this work shortened the war in Europe by more than two years and saved over fourteen million lives.[11]
After the war, Turing worked at the National Physical Laboratory, where he designed the ACE, among the first designs for a stored-program computer. In 1948 Turing joined Max Newman's Computing Machine Laboratory at the Victoria University of Manchester, where he helped develop the Manchester computers[14] and became interested in mathematical biology. He wrote a paper on the chemical basis of morphogenesis,[3] and predicted oscillating chemical reactions such as the Belousov–Zhabotinsky reaction, first observed in the 1960s.
Turing was prosecuted in 1952 for homosexual acts, when by the Labouchere Amendment, "gross indecency" was a criminal offence in the UK. He accepted chemical castration treatment, with DES, as an alternative to prison. Turing died in 1954, 16 days before his 42nd birthday, from cyanide poisoning. An inquest determined his death as suicide, but it has been noted that the known evidence is also consistent with accidental poisoning.[15] In 2009, following an Internet campaign, British Prime Minister Gordon Brown made an official public apology on behalf of the British government for "the appalling way he was treated." Queen Elizabeth II granted him a posthumous pardon in 2013.[16][17][18] The Alan Turing law is now an informal term for a 2017 law in the United Kingdom that retroactively pardoned men cautioned or convicted under historical legislation that outlawed homosexual acts.[19]
Dirk
oh that's strange because that's exactly what I did.
Hmmm - I have always tested the engines directly with either calling
/opt/picochess/engines/armv7l/turing
and
/home/pi/PyTuroChamp/ptc_xboard.py
When both work fine, picochess should also be able too call it (turing)!?
Maybe I just changed write authorization for armv7l and PyTuroChamp - but that was just for the PyTuroChamp logs and shouldn't cause a crash.
Hmmm....
Yes for the uci ini File with the option to work you need to enhance the pytyrochamp.py file because the original file does not support any options.
I have changed the fiel and added the options to ptc_xboard.py:
after lines:
elif l == 'new':
newgame()
insert:
elif 'setoption name maxplies value' in l:
p.MAXPLIES = int(l.split()[4])
print("maxplies:", p.MAXPLIES)
elif 'setoption name pstab value' in l:
p.PSTAB = int(l.split()[4])
print("pstab:", p.PSTAB)
I really suggest to set maxplies = 2 and stab = 0 in order to have good respond times and the most accurate Turochamp engine.
my turing.uci now looks like
[easy]
maxplies = 1
pstab = 0
[TuroChamp]
maxplies = 2
pstab = 0
[hard]
maxplies = 3
pstab = 5
The option TuroChamp is the original algorithm (almost).
But you can just wait because with the really kind help of Martin from PyTurochamp these options will be added to the original code so that in near future you can just copy from Github again.
Thank you so much Martin (he is really a helpful guy like our picochess group)
Dirk
You can just copy the repository again.
elif l == 'uci':
is_uci = True
print("id name PyTuroChamp")
print("id author Martin C. Doege")
print("option name maxplies type spin default 3 min 0 max 1024")
print("option name qplies type spin default 7 min 0 max 1024")
print("option name pstab type spin default 5 min 0 max 1024")
Thanks, Martin!
these were just lines from original coding: they define the technical possible values for these parameters.
If you don't set them explicitly via the new uci parameters the default values are
MAXPLIES 3
QPLIES = MAXPLIES + 4 = 7 (to avoid horizon effect -> unbelievable that turing already thought about this in his paper engine)
PSTAB = 5 (influences use of additional piece square tables)
From Martin's Github page:
"PyTuroChamp is closest to the chess engine in Turing's paper, but adds piece-square tables that can be tuned with the PSTAB parameter. A higher parameter means more aggressive forward movement. With PSTAB = 0, e3 is favored like Turing's algorithm would."
*************************
Keep in mind that these parameters should not be set like in a modern chess engine because of the Turing heuristic itself and how it is implemented in the python language.
MAXPLIES over 4 will last very long for one single move, original Turing paper engine was executed with MAXPLIES 2 (according to some sources).
As QPLIES is now also supported I will integrate it into my turing.uci setting file (eg lower QPLIES for "easy" mode etc.)
Dirk
oh the "top" command is new to me - nice to know ;-)
When choosing turing as I engine, I see already one python3 process.
During "think"time of the engine I see a second python3 process.
So you think that is strange!?
Dirk
My turing.uci Looks now like this and it works:
[easy]
maxplies = 1
qplies = 4
pstab = 0
[TuroChamp]
maxplies = 2
qplies = 6
pstab = 0
[strong]
maxplies = 3
qplies = 7
pstab = 5
Yeah, I tried similar.
The point is, mine is not picking up the right engine?
Can you check my folders against yours and post your armv7l and PyTuruChamp folders here?
Thanks,
Al.
Hmm - unfortunately can't help why the engine processes gets mixed up on your system - really strange.
thats my running processes during wait time of turing (I think this is the picochess python process)
Unknown command - try 'h' for help
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
879 pi 20 0 8216 3280 2732 R 100.0 0.3 0:14.98 top
333 root 20 0 229776 37204 9472 S 25.0 3.9 1:26.37 python3
1 root 20 0 26992 6008 4892 S 0.0 0.6 0:01.83 systemd
2 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kthreadd
3 root 20 0 0 0 0 S 0.0 0.0 0:00.04 ksoftirqd/0
4 root 20 0 0 0 0 S 0.0 0.0 0:00.24 kworker/0:0
5 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 kworker/0:0H
6 root 20 0 0 0 0 S 0.0 0.0 0:00.41 kworker/u8:0
7 root 20 0 0 0 0 S 0.0 0.0 0:00.30 rcu_sched
8 root 20 0 0 0 0 S 0.0 0.0 0:00.00 rcu_bh
9 root rt 0 0 0 0 S 0.0 0.0 0:00.00 migration/0
10 root 0 -20 0 0 0 S 0.0 0.0 0:00.00 lru-add-drain
11 root 20 0 0 0 0 S 0.0 0.0 0:00.00 cpuhp/0
and when Turing is thinking I get the python process of TuroChamp:
tasks: 126 total, 2 running, 123 sleeping, 0 stopped, 1 zombie
%Cpu(s): 25.3 us, 0.3 sy, 0.0 ni, 74.4 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
KiB Mem : 949572 total, 784320 free, 62420 used, 102832 buff/cache
KiB Swap: 102396 total, 102396 free, 0 used. 831628 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
683 root 20 0 13516 9680 5172 R 99.0 1.0 1:14.60 python3
333 root 20 0 229776 37208 9472 S 4.0 3.9 2:23.12 python3
3216 pi 20 0 8208 3360 2820 R 0.7 0.4 0:00.08 top
1 root 20 0 26992 6008 4892 S 0.0 0.6 0:01.84 systemd
2 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kthreadd
3 root 20
pi@DGTPi:/opt/picochess/engines/armv7l $ ls -all
total 51976
drwxr-xr-x 2 root root 4096 Jun 25 09:38 .
drwxr-xr-x 7 pi root 4096 Jun 24 08:26 ..
lrwxrwxrwx 1 root root 32 Jun 25 08:05 alphabeta -> /home/pi/PyTuroChamp/ptc_bare.py
-rw-r--r-- 1 root root 100 Jun 25 08:36 alphabeta.uci
-rwxr-xr-x 1 root root 1154200 Jun 16 22:54 andscacs0921
-rwxr-xr-x 1 root root 280700 Jun 16 22:54 a-stockf
-rw-r--r-- 1 root root 716 Jun 16 22:54 a-stockf.uci
-rwxr-xr-x 1 root root 278752 Jun 16 22:54 brainfish230518
-rw-r--r-- 1 root root 599 Jun 16 22:54 brainfish230518.uci
-rwxr-xr-x 1 root root 925836 Jun 16 22:54 b-texel
-rw-r--r-- 1 root root 294 Jun 16 22:54 b-texel.uci
-rwxr-xr-x 1 root root 694624 Jun 16 22:54 c-arasan
-rw-r--r-- 1 root root 1093 Jun 16 22:54 c-arasan.uci
-rwxr-xr-x 1 root root 289220 Jun 16 22:54 cct800_V1.30_x32
-rwxr-xr-x 1 root root 1050604 Jun 16 22:54 cheese192
-rw-r--r-- 1 root root 1093 Jun 21 22:53 cheese192.uci
-rwxr-xr-x 1 root root 289056 Jun 16 22:54 corchessextended
-rw-r--r-- 1 root root 1692 Jun 16 22:54 corchessextended.uci
-rwxr-xr-x 1 root root 289220 Jun 21 22:25 ct800
-rw-r--r-- 1 root root 106 Jun 22 14:57 ct800.uci
-rwxr-xr-x 1 root root 210900 Jun 16 22:54 defenchess12
-rwxr-xr-x 1 root root 247516 Jun 16 22:54 delocto06
-rwxr-xr-x 1 root root 657172 Jun 16 22:54 d-rodent
-rwxr-xr-x 1 root root 174636 Jun 16 22:54 d-rodent2
-rw-r--r-- 1 root root 39580 Jun 16 22:54 d-rodent2.uci
-rwxr-xr-x 1 root root 661272 Jun 16 22:54 d-rodent3
-rw-r--r-- 1 root root 94369 Jun 16 22:54 d-rodent3.uci
-rw-r--r-- 1 root root 89042 Jun 16 22:54 d-rodent.uci
-rwxr-xr-x 1 root root 440208 Jun 16 22:54 embla
-rw-r--r-- 1 root root 28550 Jun 25 08:22 engines.ini
-rw-r--r-- 1 root root 28130 Jun 16 22:54 engines.ini.al
-rw-r--r-- 1 root root 23486 Jun 16 22:54 engines.ini.old
-rw-r--r-- 1 root root 28454 Jun 23 09:39 engines.ini.turing
-rw-r--r-- 1 root root 790 Jun 16 22:54 engines.uci
-rwxr-xr-x 1 root root 2730231 Jun 16 22:54 e-zurich
-rw-r--r-- 1 root root 661 Jun 16 22:54 e-zurich.uci
-rw-r--r-- 1 root root 2268 Jun 21 22:53 fruit.log
-rwxr-xr-x 1 root root 809872 Jun 16 22:54 fruit-reloaded171208
-rw-r--r-- 1 root root 1093 Jun 16 22:54 fruit-reloaded171208.uci
-rwxr-xr-x 1 root root 138448 Jun 16 22:54 f-wyld
-rw-r--r-- 1 root root 1066 Jun 16 22:54 f-wyld.uci
-rw-r--r-- 1 root root 0 Jun 21 22:53 games.pgn
-rwxr-xr-x 1 root root 428068 Jun 16 22:54 g-galjoe
-rw-r--r-- 1 root root 573 Jun 16 22:54 g-galjoe.uci
-rwxr-xr-x 1 root root 292608 Jun 16 22:54 glaurung
-rwxr-xr-x 1 root root 4938464 Jun 16 22:54 h-sayuri
-rwxr-xr-x 1 root root 102860 Jun 16 22:54 i-floyd
-rwxr-xr-x 1 root root 218856 Jun 16 22:54 j-marvin
-rwxr-xr-x 1 root root 153396 Jun 16 22:54 k2v091
-rwxr-xr-x 1 root root 420480 Jun 16 23:08 lc0
-rwxr-xr-x 1 root root 420480 Jun 16 23:08 lczero
-rwxr-xr-x 1 root root 132756 Jun 16 22:54 l-ethereal
-rwxr-xr-x 1 root root 202724 Jun 16 22:54 l-laser
-rwxr-xr-x 1 root root 264376 Jun 16 22:54 matefinder9
-rw-r--r-- 1 root root 633 Jun 16 22:54 matefinder9.uci
-rwxr-xr-x 1 root root 278744 Jun 16 22:54 McBrain-92
-rw-r--r-- 1 root root 1229 Jun 16 22:54 McBrain-92.LS.uci
-rw-r--r-- 1 root root 2746 Jun 16 22:54 McBrain-92-MB.uci
-rw-r--r-- 1 root root 2891 Jun 16 22:54 McBrain-92.MB.uci
-rw-r--r-- 1 root root 1229 Jun 16 22:54 McBrain-92.normal.uci
-rw-r--r-- 1 root root 736 Jun 16 22:54 McBrain-92.SL.uci
-rw-r--r-- 1 root root 2439 Jun 16 22:54 McBrain-92.uci
-rwxr-xr-x 1 root root 878340 Jun 16 22:54 m-cinnam
-rwxr-xr-x 1 root root 945332 Jun 16 22:54 n-danasah
-rwxr-xr-x 1 root root 872240 Jun 16 22:54 nemorino416
-rwxr-xr-x 1 root root 951636 Jun 16 22:54 o-amoeba
-rwxr-xr-x 1 root root 1322204 Jun 16 22:54 o-dragon
-rwxr-xr-x 1 root root 102892 Jun 16 22:54 old-floyd.x7da0e241
-rwxr-xr-x 1 root root 432456 Jun 16 22:54 opental10
-rwxr-xr-x 1 root root 436552 Jun 16 22:54 opental11
-rwxr-xr-x 1 root root 706052 Jun 16 22:54 pedone17
-rw-r--r-- 1 root root 312 Jun 16 22:54 pedone17.uci
-rw-r--r-- 1 root root 42643 Jun 16 22:54 personality_all
-rwxr-xr-x 1 root root 677248 Jun 16 22:54 q-demolito
-rw-r--r-- 1 root root 10172160 Jun 16 22:54 rodent.bin
-rwxr-xr-x 1 root root 108152 Jun 16 22:54 r-roboci
-rwxr-xr-x 1 root root 104284 Jun 16 22:54 rubiChess-Board88
-rwxr-xr-x 1 root root 141044 Jun 16 22:54 r-zevra
-rwxr-xr-x 1 root root 177264 Jun 16 22:54 sctr
-rwxr-xr-x 1 root root 104360 Jun 16 22:54 senpai20
-rwxr-xr-x 1 root root 92144 Jun 16 22:54 shallowblue110
-rwxr-xr-x 1 root root 190444 Jun 16 22:54 snowy022
-rwxr-xr-x 1 root root 308497 Jun 16 22:54 stf-Human
-rw-r--r-- 1 root root 716 Jun 16 22:54 stf-Human.uci
-rwxr-xr-x 1 root root 271792 Jun 16 22:54 stingSF999
-rw-r--r-- 1 root root 599 Jun 16 22:54 stingSF999.uci
-rwxr-xr-x 1 root root 259528 Jun 16 22:54 stockfish191
-rwxr-xr-x 1 root root 243892 Jun 16 22:54 stockfish231
-rw-r--r-- 1 root root 599 Jun 16 22:54 stockfish231.uci
-rwxr-xr-x 1 root root 268468 Jun 16 22:54 stockfish3
-rw-r--r-- 1 root root 599 Jun 16 22:54 stockfish3.uci
-rwxr-xr-x 1 root root 280768 Jun 16 22:54 stockfish4
-rw-r--r-- 1 root root 599 Jun 16 22:54 stockfish4.uci
-rwxr-xr-x 1 root root 276776 Jun 16 22:54 stockfish5
-rw-r--r-- 1 root root 599 Jun 16 22:54 stockfish5.uci
-rwxr-xr-x 1 root root 243988 Jun 16 22:54 stockfish6
-rw-r--r-- 1 root root 599 Jun 16 22:54 stockfish6.uci
-rwxr-xr-x 1 root root 227752 Jun 16 22:54 stockfish7
-rw-r--r-- 1 root root 598 Jun 16 22:54 stockfish7.uci
-rwxr-xr-x 1 root root 239780 Jun 16 22:54 stockfish8
-rw-r--r-- 1 root root 1449 Jun 16 22:54 stockfish8.uci
-rwxr-xr-x 1 root root 264376 Jun 16 22:54 stockfish9al
-rw-r--r-- 1 root root 739 Jun 16 22:54 stockfish9al.uci
-rwxr-xr-x 1 root root 280820 Jun 16 22:54 stockfishdd
-rw-r--r-- 1 root root 599 Jun 16 22:54 stockfishdd.uci
-rwxr-xr-x 1 root root 297248 Jun 16 22:54 sugaR
-rw-r--r-- 1 root root 599 Jun 16 22:54 sugaR.uci
-rwxr-xr-x 1 root root 178516 Jun 16 22:54 teki2
-rwxr-xr-x 1 root root 104620 Jun 16 22:54 t-fruit
-rwxr-xr-x 1 root root 129684 Jun 16 22:54 togaII401
-rw-r--r-- 1 root root 5010 Jun 21 22:53 trace.log
lrwxrwxrwx 1 root root 34 Jun 24 14:45 turing -> /home/pi/PyTuroChamp/ptc_xboard.py
-rw-r--r-- 1 root root 135 Jun 25 05:54 turing.uci
-rwxr-xr-x 1 root root 4938464 Jun 16 22:54 u-sayuri
-rwxr-xr-x 1 root root 373976 Jun 16 22:54 v-vajole
-rwxr-xr-x 1 root root 1718052 Jun 16 22:54 zurichess-jura
-rw-r--r-- 1 root root 599 Jun 16 22:54 zurichess-jura.uci
-rwxr-xr-x 1 root root 1718148 Jun 16 22:54 zuri-luzern
-rw-r--r-- 1 root root 661 Jun 16 22:54 zuri-luzern.uci
-rwxr-xr-x 1 root root 1784548 Jun 16 22:54 zuri-Neuchatel
-rw-r--r-- 1 root root 662 Jun 16 22:54 zuri-Neuchatel.uci
-rwxr-xr-x 1 root root 1669492 Jun 16 22:54 zuriNidwalden
-rw-r--r-- 1 root root 662 Jun 16 22:54 zuriNidwalden.uci
pi@DGTPi:~/PyTuroChamp $ ls -all
total 1132
drwxr-xr-x 5 root root 4096 Jun 25 08:02 .
drwxr-xr-x 7 pi pi 4096 Jun 24 21:35 ..
-rwxr-xr-x 1 root root 78 Jun 24 21:35 bare
-rwxr-xr-x 1 root root 4204 Jun 24 21:35 bare.py
-rw-r--r-- 1 root root 978087 Jun 24 21:35 chess-eco.pos.txt
drwxr-xr-x 8 root root 4096 Jun 24 21:35 .git
drwxr-xr-x 2 root root 4096 Jun 24 21:35 icons
-rwxr-xr-x 1 root root 898 Jun 24 21:35 movetest.py
-rwxr-xr-x 1 root root 78 Jun 24 21:35 newt
-rwxr-xr-x 1 root root 6628 Jun 24 21:35 newt.py
-rwxr-xr-x 1 root root 3182 Jun 24 21:35 pst.py
-rwxr-xr-x 1 root root 74 Jun 24 21:35 ptc
-rwxr-xr-x 1 root root 3225 Jun 25 08:02 ptc_bare.py
-rw-r--r-- 1 root root 891 Jun 24 21:35 ptc-bare-stockfish.pgn
-rw-r--r-- 1 root root 131 Jun 24 21:35 ptc.bat
-rwxr-xr-x 1 root root 711 Jun 24 21:35 ptc-host.py
-rwxr-xr-x 1 root root 3475 Jun 24 21:35 ptc_xboard.py
drwxr-xr-x 2 root root 4096 Jun 25 08:20 __pycache__
-rwxr-xr-x 1 root root 7410 Jun 24 21:35 pyturochamp.py
-rw-r--r-- 1 root root 6255 Jun 24 21:35 README.md
-rw-r--r-- 1 root root 79027 Jun 24 21:35 Screenshot_20171123_102423.png
-rwxr-xr-x 1 root root 1955 Jun 24 21:35 xboard-host.py
glad you figured it out again - as usual ;-)
By the way I think there is a big bug in Version 0.9N when choosing an engine which will lead to an error - so no "engine ok" confirmation.
In this case (at least when I have experimented with the PyTuroChamp engines) it still shows the faulty engine as selected in the menu but in reality it is running the previous engine which was not faulty (you can double check in log that this is the fallback and by checking with this this great top command the running processes ;-)
So that would have been my guess for your problem (although yours was different cause)- so we just should keep that in mind when something strange is happening in our neighborhood ;-)
Dirk
This is the PDF link to Turings original paper - a very interesting read!
https://docs.google.com/file/d/0B0xb4crOvCgTNmEtRXFBQUIxQWs/edit
Enjoy!
Dirk
the new turing engine is (because it's implemented in python) relativly slow especially when the game for stronger players should also be fun.
Try a game against turing with the following setting
MAXPLIES = 4
QPLIES = 8
PSTAB = 5
and you will be surprised (at least I was)!
Martin suggested to install "pypy" in addition to python3 which would gain some big performance improvement compared to python 3.5/3.6.
But then I think we would get again problems by starting python scripts with the pypy command from within picochess unless the new pypy command would be assigned by default to process python *.py scripts.
Is there a reason why even picochess is running under python 3 instead of pypy with better performance?
Ok - another solution would be a multi core version of pyturochmp.py.
Guess what????
Martin just has implemented it and I test it during the soccer game - it looks like it is 3-4 times faster than the single core version on my DGT PI (it looks like DGT Pi supports at least 5 core processes?).
At he moment it does not support the options to change MAXPLIES, QPLIES and PSTAB but maybe this will also added in near future (up to then you would have to change parameters directly in source coding (MAXPLIES = 4 QPLIES = 8 PSTAB = 5 are default)
I will add turing_multi (have to create new python ici wrapper script to be able of being called by picochess) later and inform Al.
Dirk
top - 18:50:25 up 15 min, 1 user, load average: 4.79, 4.23, 2.49
Tasks: 131 total, 5 running, 125 sleeping, 0 stopped, 1 zombie
%Cpu(s): 99.6 us, 0.4 sy, 0.0 ni, 0.0 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
KiB Mem : 949572 total, 777176 free, 73628 used, 98768 buff/cache
KiB Swap: 102396 total, 102396 free, 0 used. 820420 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
633 root 20 0 26592 10196 4464 R 100.0 1.1 8:23.52 python3
626 root 20 0 26592 12644 6944 R 99.3 1.3 8:46.80 python3
631 root 20 0 26592 10196 4464 R 99.3 1.1 8:33.19 python3
634 root 20 0 26592 10180 4456 R 95.5 1.1 8:43.91 python3
361 root 20 0 229792 37412 9564 S 5.8 3.9 1:04.47 python3
1429 pi 20 0 8236 3296 2732 R 0.4 0.3 0:04.37 top
87 root -51 0 0 0 0 S
Also Martin and I have found out that some default setting (like PSTAB = 5 are not optimal).
The multi Turing engine will use max. possible cores and is at least 2 times faster.
Will post settings upon my return from my vacation trip.
Dirk
indeed Martin just suggested to change the default settings so that the engines will not so "easy" overlook direct material losses etc.
For this we would have to use odd numbers for the plies parameter.
As with MAXPLIES = 3 PyTuroChamp already needs long thinking times we would have to use MAXPLIES = 1 and QPLIES = 3.
Because of less plies Martin changes behavior so that more moves will be "considerable" according to Turing's original description.
So we now have the almost original Turochamp with
MAXPLIES = 1
QPLIES = 3
PSTAB = 0
and I changed my personal other level settings to:
1- easy
MAXPLIES = 1
QPLIES = 3
PSTAB = 2
1- normal
MAXPLIES = 3
QPLIES = 5
PSTAB = 2
1- harder
MAXPLIES = 3
QPLIES = 7
PSTAB = 2
Regards
Dirk
Regards
Dirk
Should we not Change alphabeta.uci maxplies to 1, 3 & 5 (from 2, 3 & 4) in Easy, Normal & Stronger respectively?
Al.
yep because alphabeta is based on the same principle - and you already did it I assume ;-)
Dirk