On-line engine blitz tourney June

Discussion of chess software programming and technical issues.

Moderator: Ras

brtzsnr
Posts: 433
Joined: Fri Jan 16, 2015 4:02 pm

Re: On-line engine blitz tourney June

Post by brtzsnr »

Interesting. So my engine prints a `info string` before `bestmove`. Is this tripping xboard/polyglot? Normally `info string` lines should be ignored, they are just debug info.
User avatar
hgm
Posts: 28480
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: On-line engine blitz tourney June

Post by hgm »

Polyglot translates 'info string' commands to CECP Thinking Output lines with time = nodes = score = 0 and the latest depth, where the string then is placed in the PV field. Like

info string give extra time due to fail low

would be passed on to the GUI as

11 0 0 0 give extra time due to fail low

XBoard would then print that message in the Engine Output window over the full width of the line (i.e. suppressing the score, time and nodes output, and left-aligning the string to the column that normally displays the score).

I am not sure whether such a line could accidentally be kibitzed to the ICS instead of 'true' Thinking Output; I vaguely remember I took measures to prevent that. But in any case this would be a pure GUI matter, and thus has nothing to do with your problem. Which is that your engine apparently does something that makes Polyglot decide to terminate the engine and exit.
Henk
Posts: 7251
Joined: Mon May 27, 2013 10:31 am

Re: On-line engine blitz tourney June

Post by Henk »

hgm wrote:Oh, you are right. What I wrote is the order WinBoard displays them in the Engine Output window. But indeed this exchanges the nodes and time.

For -autoKibitz to work you should print the thinking output before the move. Auto-kibitzing uses the last line of thinking output before the move to build the kibitz command it sends to the ICS. (Usually there is a line for every depth.) If you see a normal progression of PVs in WinBoard's Engine Output window, auto-kibitzing must work.
I get the error Can't open "|autoKibitz" . "het system kan het opgegeven bestand niet vinden".

By the way instead of | before autokibitz it shows a rare vertical bar.

I always get this error when connecting. So I have to enable autokibitz manually using menu 'options|ICS'.
Henk
Posts: 7251
Joined: Mon May 27, 2013 10:31 am

Re: On-line engine blitz tourney June

Post by Henk »

Wait a minute if I remove the '-' before autokibitz and add it again it seems to work. So the command in the word document that I always use stores a different character instead of '-' but displays it as '-'.
User avatar
hgm
Posts: 28480
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: On-line engine blitz tourney June

Post by hgm »

This is an error message you would get when an option does not start with a hyphen (-) or slash (/). WinBoard then assumes it is a file, and imagines the necessecary option (-lgf, -lpf, -tf, -opt, depending on the filename extension) before it. It then tries to open the file for the indicated purpose, and when no file of that name exists, you get this error message. This because double-clicking a file named XXX that is associated with WinBoard in the system registry (or dragging an arbitrary file icon XXX on top of the winboard.exe icon) will make Windows issue the command "winboard.exe XXX".

Note that you can also switch on the auto-kibitz option by ticking a checkbox in the ICS Options menu dialog, if the command line causes you problems.
Henk
Posts: 7251
Joined: Mon May 27, 2013 10:31 am

Re: On-line engine blitz tourney June

Post by Henk »

hgm wrote:This is an error message you would get when an option does not start with a hyphen (-) or slash (/). WinBoard then assumes it is a file, and imagines the necessecary option (-lgf, -lpf, -tf, -opt, depending on the filename extension) before it. It then tries to open the file for the indicated purpose, and when no file of that name exists, you get this error message. This because double-clicking a file named XXX that is associated with WinBoard in the system registry (or dragging an arbitrary file icon XXX on top of the winboard.exe icon) will make Windows issue the command "winboard.exe XXX".

Note that you can also switch on the auto-kibitz option by ticking a checkbox in the ICS Options menu dialog, if the command line causes you problems.
It is already solved. See my previous message. I copy the command from a word document. But if I look closely it contains a wrong dash. A dash that is slightly bigger than the normal one.

This character: –
Which is not: -
User avatar
hgm
Posts: 28480
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: On-line engine blitz tourney June

Post by hgm »

Yes, our last messages crossed.
op12no2
Posts: 558
Joined: Tue Feb 04, 2014 12:25 pm
Location: Gower, Wales
Full name: Colin Jenkins

Re: On-line engine blitz tourney June

Post by op12no2 »

It'll be great to see Skipper kibitzing...
Joost Buijs
Posts: 1693
Joined: Thu Jul 16, 2009 10:47 am
Location: Almere, The Netherlands

Re: On-line engine blitz tourney June

Post by Joost Buijs »

Nice! I will be there on Saturday.

Hopefully it will go better then the last few times.
My engine was plagued by a bug I couldn't find for a long time.
It seems I introduced a race condition in my SMP search which made it play a bad move now and then, very unpredictable and difficult to find.
30 minutes ago I finally found the problem (at least I hope so).
When I was searching for that particular bug I also found a flaw in my time control function.
All these bugs are killing me!

Your tournament is always a good place to test things.
brtzsnr
Posts: 433
Joined: Fri Jan 16, 2015 4:02 pm

Re: On-line engine blitz tourney June

Post by brtzsnr »

So I tried playing two instances of zurichess one with autoKibitz and one without. This worked fine and I can see the kibitz so the output is fine and can be interpreted by xboard/poluglot.

Then I tried two instances both kibitzing. White moved but black crashed once the kibitz was received. Here is the input and output for the crashing instance (Xboard crashed):

Code: Select all

< zurichess (devel), build with go1.4 at (just now), running on amd64
> uci
< id name zurichess
< id author Alexandru Moșoi
< 
< option name UCI_AnalyseMode type check default false
< option name Hash type spin default 128 min 1 max 8192
< uciok
> isready
< readyok
> setoption name Hash value 2052
> ucinewgame
> position startpos moves e2e4
> go wtime 120000 btime 120000 winc 12000 binc 12000
< info depth 1 score cp 0 nodes 41 time 66 nps 612 pv e7e5
< info depth 2 score cp -21 nodes 458 time 419 nps 1092 pv d7d5 d2d3
< info depth 3 score cp 0 nodes 1107 time 894 nps 1238 pv d7d5 b1c3 e7e6
> stop
> quit

I produced a log of polyglot to see what happens:
For zurichess

Code: Select all

(snip)
1433447447.915 GUI->Adapter: ucinewgame
1433447447.915 Adapter->Engine: ucinewgame
1433447476.070 GUI->Adapter: position startpos moves e2e4
1433447476.071 Adapter->Engine: position startpos moves e2e4
1433447476.071 GUI->Adapter: go wtime 120000 btime 120000 winc 12000 binc 12000
1433447476.071 Adapter->Engine: go wtime 120000 btime 120000 winc 12000 binc 12000
1433447476.074 Engine->Adapter: info depth 1 score cp 0 nodes 41 time 2 nps 14247 pv e7e5
1433447476.074 Adapter->GUI: info depth 1 score cp 0 nodes 41 time 2 nps 14247 pv e7e5
1433447476.089 Engine->Adapter: info depth 2 score cp -21 nodes 458 time 17 nps 25731 pv d7d5 d2d3
1433447476.089 Adapter->GUI: info depth 2 score cp -21 nodes 458 time 17 nps 25731 pv d7d5 d2d3
1433447476.107 Engine->Adapter: info depth 3 score cp 0 nodes 1107 time 36 nps 30340 pv d7d5 b1c3 e7e6
1433447476.107 Adapter->GUI: info depth 3 score cp 0 nodes 1107 time 36 nps 30340 pv d7d5 b1c3 e7e6
1433447476.285 GUI->Adapter: stop
1433447476.285 Adapter->Engine: stop
1433447476.285 GUI->Adapter: quit
1433447476.285 POLYGLOT *** "quit" from GUI ***
1433447476.285 POLYGLOT *** QUIT ***
1433447476.285 Adapter->Engine: quit
1433447476.285 POLYGLOT Closing engine.
1433447476.285 Adapter->Engine: EOF
(snip)
For stockfish

Code: Select all

(snip)
1433448276.119 Engine->Adapter: info depth 11 seldepth 17 score cp -32 nodes 139196 nps 1277027 time 109 multipv 1 pv e7e5 g1f3 b8c6 f1b5 g8f6 e1g1 f8c5 d2d3 e8g8 b1c3 d7d6 b5c6 b7c6 c
1433448276.119 Adapter->GUI: 11 -32 11 139196 e5 Nf3 Nc6 Bb5 Nf6 O-O Bc5 d3 O-O Nc3 d6 Bxc6 bxc6 Be3 Bb6
1433448276.222 GUI->Adapter: EOF
1433448276.222 POLYGLOT *** QUIT ***
1433448276.222 POLYGLOT STOP SEARCH
1433448276.222 Adapter->Engine: stop
1433448276.222 Adapter->Engine: quit
1433448276.222 POLYGLOT Closing engine.
1433448276.222 Adapter->Engine: EOF
1433448276.222 POLYGLOT Engine does not reply. Sleeping 100ms.
1433448276.322 Engine->Adapter: info nodes 283363 time 212
1433448276.322 Engine->Adapter: bestmove e7e5 ponder g1f3
1433448276.322 Engine->Adapter: EOF
1433448276.322 POLYGLOT Waiting for child process to exit.
1433448276.322 POLYGLOT Child exited with status 0.
1433448276.522 POLYGLOT Calling exit

So the GUI (Xboard) sends stop and quit to polyglot which forwards the commands to the engine. Why?? I mananged to reproduce the xboardcrash with stockfish too (see above). The crash only happens when Xboard receives a kibitz and -autokibitz is enabled.

If this helps

Code: Select all

$ ~/xboard-4.8.0/xboard --version
xboard version 4.8.0

  configure options: prefix=NONE; datarootdir=/usr/local/share; datadir=/usr/local/share; gamedatadir=/usr/local/share/games/xboard; desktopdir=/usr/local/share/applications; mimedir=/usr/local/share/mime/packages; iconsdir=/usr/local/share/icons/hicolor/48x48/apps; svgiconsdir=/usr/local/share/icons/hicolor/scalable/apps; infodir=/usr/local/share/info; sysconfigdir=; update_mimedb=yes; NLS=yes; GKT=no; Xaw3d=no; Xaw=yes; ptys=pipes; zippy=yes; sigint=yes

$ polyglot
PolyGlot 1.4.67b by Fabien Letouzey.