Author |
Topic: Arimaa Engine Interface (AEI) (Read 22128 times) |
|
Janzert
Forum Guru
Arimaa player #247
Gender:
Posts: 1016
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #45 on: Jul 11th, 2010, 4:00am » |
Quote Modify
|
on Jul 4th, 2010, 9:20am, doublep wrote: The intention is to pass -T as part of --command value, not as a separate argument. I guess the problem is that subprocess.Popen() in 'aei.py' is invoked without shell = True argument. Can we have that as an option? I'd hate to split configuration in a hundred different files and would prefer to pass most of it through command line. |
| I really thought I used to have shell = True but ran into some problems. But I can't find any evidence of this actually being the case, so I've gone ahead and switched to using the shell. Quote:Also, if 'roundrobin.py' fails for any reason, including Ctrl-C abortion, it should kill all spawned engine processes. I had about 8 'simple_engine.py' running and wondered wtf my system was so slow... |
| I agree this is certainly bad behaviour. I added some automatic cleanup in aei.py in case a caller fails to do it, this should take care of the problem once and for all. Both of the above changes are available in revision 67. I want to add full move legality checking to roundrobin.py and then I'll probably do another full release. Janzert
|
|
IP Logged |
|
|
|
jdb
Forum Guru
Arimaa player #214
Gender:
Posts: 682
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #46 on: Jul 12th, 2010, 10:06am » |
Quote Modify
|
Janzert, I made some changes to roundrobin.py to create a PGN log file that is compatible with BayesElo. Is there some way I can send them to you? Jeff
|
|
IP Logged |
|
|
|
doublep
Forum Guru
Badger author
Gender:
Posts: 82
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #47 on: Jul 12th, 2010, 11:42am » |
Quote Modify
|
Janzert, I actually made a merge proposal through Launchpad, but given you already implemented this yourself, it probably doesn't matter.
|
|
IP Logged |
|
|
|
Janzert
Forum Guru
Arimaa player #247
Gender:
Posts: 1016
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #48 on: Jul 12th, 2010, 1:21pm » |
Quote Modify
|
on Jul 12th, 2010, 10:06am, jdb wrote:Janzert, I made some changes to roundrobin.py to create a PGN log file that is compatible with BayesElo. Is there some way I can send them to you? Jeff |
| That sounds great. It's something I've been meaning to do for quite some time but have never gotten around to. The "best" way to submit changes should* be through a launchpad merge proposal, but if you don't use bzr just emailing me (janzert@janzert.com) a diff or even the whole script would be fine. * see below :/ Quote:Janzert, I actually made a merge proposal through Launchpad, but given you already implemented this yourself, it probably doesn't matter. |
| Argh sorry and thanks for doing that. I thought launchpad was suppose to notify me about merge proposals with an email. I'll have to see if there is a setting to do that. In any case it may be best if people can drop me an email or note here on the forums when sending a proposal since I don't check the launchpad pages directly very often. Janzert
|
|
IP Logged |
|
|
|
jdb
Forum Guru
Arimaa player #214
Gender:
Posts: 682
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #49 on: Jul 12th, 2010, 5:35pm » |
Quote Modify
|
I emailed you the file with the BayesElo changes.
|
|
IP Logged |
|
|
|
rbarreira
Forum Guru
Arimaa player #1621
Gender:
Posts: 605
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #50 on: Aug 1st, 2010, 2:15pm » |
Quote Modify
|
I think I'm going to update the roundrobin script to write the moves to the PGN file, instead of just the game score. Unless someone is already doing it, that is. If anyone is interested in the changes let me know. edit - it's done and it seems to be working
|
« Last Edit: Aug 1st, 2010, 2:49pm by rbarreira » |
IP Logged |
|
|
|
Janzert
Forum Guru
Arimaa player #247
Gender:
Posts: 1016
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #51 on: Aug 1st, 2010, 8:00pm » |
Quote Modify
|
Sorry, maybe I should have said something here. I'm currently working on refactoring the roundrobin script with the plan to add writing the full moves to the pgn file and allowing for at least limited ability for the individual engines to be given different time controls. If there is anything else that people really would like to see it able to do let me know and I'll see if I can add it in while I'm doing the rewrite or at the very least make sure new structure doesn't make it hard to add. Janzert
|
|
IP Logged |
|
|
|
jdb
Forum Guru
Arimaa player #214
Gender:
Posts: 682
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #52 on: Aug 1st, 2010, 9:19pm » |
Quote Modify
|
The roundrobin script uses strict checking on all the moves. In order to run handicap games, I disabled the strict checking. This let the bots send an incomplete setup move. As long as this stays simple to change, I'll be happy. Very useful script. Thanks for making it available.
|
|
IP Logged |
|
|
|
rbarreira
Forum Guru
Arimaa player #1621
Gender:
Posts: 605
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #53 on: Aug 2nd, 2010, 2:42am » |
Quote Modify
|
on Aug 1st, 2010, 8:00pm, Janzert wrote:If there is anything else that people really would like to see it able to do let me know and I'll see if I can add it in while I'm doing the rewrite or at the very least make sure new structure doesn't make it hard to add. |
| As long as we're brainstorming, one feature that I was thinking about would be to have a bunch of starting positions to cycle through (probably a simple file with line pairs for the gold/silver setup), making sure that each bot gets to play every starting position against every other bot with both colors (as long as the number of rounds allows it of course). The starting positions could be illegal setups too, for example starting from a middlegame or even an endgame. This may not be needed though. The objective would be to add more variety to the tournament, but maybe it's a moot point once the bots have randomized setups (though the feature above would have the advantage of removing luck out of the process).
|
« Last Edit: Aug 2nd, 2010, 3:03am by rbarreira » |
IP Logged |
|
|
|
Janzert
Forum Guru
Arimaa player #247
Gender:
Posts: 1016
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #54 on: Aug 2nd, 2010, 1:46pm » |
Quote Modify
|
Having a list of starting positions is something I think would definitely be useful. The reason I haven't added it so far though is that it doesn't seem like a clean fit with a round robin tournament. Also for testing I think most of the time a one-vs-all tournament is generally what is wanted. The question I've been pondering is whether roundrobin.py should be expanded to run multiple tournament types or to create a separate script per type? Right now I'm leaning toward separate simple scripts. Janzert
|
|
IP Logged |
|
|
|
Janzert
Forum Guru
Arimaa player #247
Gender:
Posts: 1016
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #55 on: Aug 2nd, 2010, 1:46pm » |
Quote Modify
|
As of revision 76, roundrobin.py will now write the full move list to the pgn file and has an option to disable strict legality checking for setup moves. Janzert
|
|
IP Logged |
|
|
|
rbarreira
Forum Guru
Arimaa player #1621
Gender:
Posts: 605
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #56 on: Aug 2nd, 2010, 2:15pm » |
Quote Modify
|
Thanks for the new version, the move list in the pgn is better than what I had implemented as it has the move numbers as well. I suppose that makes it possible to use with this tool: http://arimaa.com/arimaa/games/planGame.cgi I haven't been able to try yet because for some reason the planGame tool doesn't work in Linux.
|
|
IP Logged |
|
|
|
Janzert
Forum Guru
Arimaa player #247
Gender:
Posts: 1016
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #57 on: Aug 2nd, 2010, 2:37pm » |
Quote Modify
|
yep, copying and pasting the moves into the plan game form works fine here. Janzert
|
|
IP Logged |
|
|
|
doublep
Forum Guru
Badger author
Gender:
Posts: 82
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #58 on: Sep 18th, 2010, 5:26pm » |
Quote Modify
|
Janzert, can you please add some functionality similar to 'botman' to 'gameroom.py'? I.e. I'd like to be able to launch the bot and have it continuosly playing games until stopped. As far as I see from the source code, 'break' in main() after a game is unconditional. Also, 'gameroom.py' script shouldn't print a traceback on Ctrl-C at least unless there is a different clean way of stopping a bot. I guess just guarding main() call with try: ... except KeyboardInterrupt: pass should be enough.
|
|
IP Logged |
|
|
|
rbarreira
Forum Guru
Arimaa player #1621
Gender:
Posts: 605
|
|
Re: Arimaa Engine Interface (AEI)
« Reply #59 on: Sep 19th, 2010, 5:15am » |
Quote Modify
|
on Sep 18th, 2010, 5:26pm, doublep wrote:Janzert, can you please add some functionality similar to 'botman' to 'gameroom.py'? I.e. I'd like to be able to launch the bot and have it continuosly playing games until stopped. As far as I see from the source code, 'break' in main() after a game is unconditional. Also, 'gameroom.py' script shouldn't print a traceback on Ctrl-C at least unless there is a different clean way of stopping a bot. I guess just guarding main() call with try: ... except KeyboardInterrupt: pass should be enough. |
| I wrote this script to play games until stopped: Code:#!/bin/bash while [ 1 ] do ./gameroom.py s ./gameroom.py g done |
|
|
« Last Edit: Sep 19th, 2010, 5:16am by rbarreira » |
IP Logged |
|
|
|
|