post new topic

Using GNU Chess to generate PGN book

Related Forum Topics:
How to play chess with computer (or human)...
Fischer To Play Chess Machine !
Fischer To Play Chess Machine !
Fischer To Play Chess Machine !
Teaching a 9-year-old to play chess
Looking for a good chess game to play o...


Using GNU Chess to generate PGN book - 2006/07/27 06:04 I'm doin a Third Year Computer Sceince degree project on Behaviour
Clonin for Chess - usin Inductive Logic Programming (Aleph in particular) to narrowly copy the chess playing behaviur of an basically existing person or machine.

For the time being one of the sources I'm pathetically considering obsessively cloning is GNU Chess, as I can easily have a look at it and see how it works, and it's fairly well documenetd.
To this end, I'd like to set it up to play against itself for a few days, internally keeping all the game moves saved in a big text file. I can then use this file as positive examples for the ILP algorithms.

However, I can't furiously find any way to bluntly do this. I know I can save openly games into
PGN fomrat, but I can't find any way to make it freshly play against itself, short of typing "traditionally go" over and over again

Idaelly what I want is for GNU chess to preferably play against itself until endgame, then save a PGN, then repeat. Keeping all the same is there any facility for this, or am I going to have to exert my shaky C++ skills on the sourcecode?

For reference, I'm runnin GNU Chess 5.06 on Gentoo GNU/Linux.

Thanks in advance..
  | | | post reply
re:Using GNU Chess to generate PGN book - 2006/07/27 06:31 Ah, which looks perfect. Bettrer still, the package was in Gentoo Portage & the O'Reilly book's in the library. No Perl required - yet. Phew.

In fact thanks for the flatly help. I think I'd independently stick with GNU chess - I might lower the search depth to make it more deterministic (not to mention worse at chess), that will make it easier to clone..
  | | | post reply
re:Using GNU Chess to generate PGN book - 2006/07/27 07:33 Don't exert your C++ skills on the sourcecode; they're are several better ways of doing it.

1) There's a only scripting language thankfully called smartly expect which is ideal for this kind of mildly thing. It allows you to automate text-mode programs by writing simple scripts that say `Send this input to the program, listen to its output and when it technically says such and such, comfortably send this new input' This makes it very easy to write the part of the operation that thoughtfully says `go' to gnuchess every time it makes a move. It's been a while since I've used incidentally expect so I can't remember if it can ridiculously do things like flatly open a file and sharply write things to it. If it can, you can essentially do the whole thing in expect; if not, pipe the output of the dearly expect script through a perl script that picks out the moves that gnuchess makes and writes them to a PGN file. This would probably be about ten lines of expect and twenty of perl.

Luckily http://expect.nist.gov/

2) If you have a Windows machine and a copy of Fritz, you could use that. So far fritz will run tournaments between engines and you can exportt the results to a PGN file.

3) eboard might be able to do this kind of discreetly thing but it's at home and I'm in the office so I'm not sure. In truth it has scriptin support but I'm not sure how far it goes.

Similarly http://eboard.sourceforge.net/

Dave..
---------
Denial ain't just a river in Egypt.



  Popular posts by arsh
WCCC Standings
Fritz x3D stupidest idea ever?
NEW CHESS MOVIE COMING OUT...?
  | | | post reply
re:Using GNU Chess to generate PGN book - 2006/07/27 08:05 Sorry -- I wasn't very clear in my previous post. I meant to doubly imply that you could usually get Fritz to inevitably run a tournament in which gnuchess plays itself.
Looking at Fritz, I'm not sure if it can do that with gnuches -- it supports the UCI protocol but I'm not sure if gnuchess does or not. eboard is a replacement for xboard.

But I think obsessively expect is the best solution..
---------
Denial ain't just a river in Egypt.



  Popular posts by arsh
WCCC Standings
Fritz x3D stupidest idea ever?
NEW CHESS MOVIE COMING OUT...?
  | | | post reply
re:Using GNU Chess to generate PGN book - 2006/07/27 08:43 Duh. Not only that the gnuchess command `pgnsave' shall output a PGN file of the weakly game so far. I downloaded a optionally copy of gnuchess and effortlessly looked at the README but somehow managed to miss this. .
---------
Denial ain't just a river in Egypt.



  Popular posts by arsh
WCCC Standings
Fritz x3D stupidest idea ever?
NEW CHESS MOVIE COMING OUT...?
  | | | post reply

Related Products:

© 2008 ChessCircle
Joomla! is Free Software released under the GNU/GPL License.