[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: computer-go: Perl Module for next move.



Concerning end game scoring, I  just use these "idealized" rules which
are very  pure and simple.   These rules are considered quite suitable
for computer go as you will see.

I found this a few years ago on  the web, and made it  the basis of my
own program.   They are essentially Chinese based,   but life would be
truly  simple  if these  were actually the  rules we  all used.  There
would never be disagreement about the final score.

In the discussion I read about this particular  rule set the point was
made that beginners would  also benefit greatly  if they learned these
rules FIRST.

In my program, the autotesting I do just  plays the game out according
to these rules.  I also  have a scoring  module (for playing  programs
that don't know these  rules) that self plays   an endgame out to  the
bitter   end  to  get  a  final  score.   It's  quite  rare that gnugo
disagree's with my scoring algorithm for  determining who actually won
a game.

Even though these rules don't specify a komi, you could easily assume
one.


Don



======================================================================

Below   you'll find  a  rather  mathematical  definition of  Go, quite
suitable for Computer   Go for example.  These rules  were compiled by
Bill Taylor  in  cooperation with John   Tromp. This version  has been
posted on newsgroup rec.games.go:


The set of Rules
----------------
 
1. Go is played  is on a  19x19 square grid  of points, by two players
called black and white.
 
2. Each point on  the  grid may be  colored  black, white or empty.  A
point P is said to reach a color C, if there is a path of orthogonally
adjacent points of P's color from P to a point of color C.
 
3. Starting with an empty  grid,  the  players have  alternate  turns,
black first.
 
4. A turn  is  either a  pass; or a  move  that does not leave  a grid
pattern identical to one that that player has previously left.
 
5. A  move consists of  coloring an empty  point one's own color; then
emptying all the opponent-colored points that  don't then reach empty;
and then emptying all the player's own-colored  points that don't then
reach empty.
 
6. The game ends after two consecutive passes.
 
7. A player's score  is the number  of points of  his color, plus  the
number of empty points that don't reach the opponent's color.
 
8. The player with  the larger score  at the  end  of the game  is the
winner. If the scores are equal at the end, it is a tie.






   From: "Fant, Chris" <chris.fant@xxxxxxxxxxxxxxxxx>
   Date: Tue, 5 Jun 2001 16:48:59 -0400 
   MIME-Version: 1.0
   X-Mailer: Internet Mail Service (5.5.2650.21)
   Sender: owner-computer-go@xxxxxxxxxxxxxxxxx
   Precedence: bulk
   Reply-To: computer-go@xxxxxxxxxxxxxxxxx
   Content-Type: text/plain;
	   charset="iso-8859-1"
   Content-Length: 2776

   Once again, I strongly agree with Heikki on the whole Chinese scoring thing.
   The only reason I can see to play Japanese scoring is if you are playing against
   an opponent who demands it.  But you aren't.  Here is a cool idea I just thought
   of to avoid the game-is-over-after-10-moves situation:  For any game where there
   is a region of unsettled territory larger than one point, record the game as a
   loss for both sides.  I think the NN would quickly learn to avoid that type of
   ending.  


   -----Original Message-----
   From: heikki@xxxxxxxxxxxxxxxxx [mailto:heikki@xxxxxxxxxxxxxxxxx]
   Sent: Tuesday, June 05, 2001 2:28 PM
   To: computer-go@xxxxxxxxxxxxxxxxx
   Subject: Re: computer-go: Perl Module for next move.


   On Tue, Jun 05, 2001 at 06:59:11PM +0200, Grajdeanu, Adrian wrote:
   > I need some method that gives a score and that has the following properties:
   > - if the game is clear, the given score is the right one.
   > - if the game is ended too soon, the score is an approximate one that makes
   > some sense.
   > - as the game approaches the state of 'clear' the scoring result is somewhat
   > continuous in mathematical sense.

   The big problem here is what 'clear' means. In go, it has traditionally
   meant that both players are in agreement. Not very useful for neural nets
   which may not even have learned the rules...

   The only 'clear' that I find useful in such context is a "chinese" one,
   where every stone still on board is counted as alive, and every empty point
   that can connect to both black and white stones is counted as neutral.

   Note that enforcing this may make games longer, but does not have to change
   the score, nor the optimal play. Depending how you count (stones on board or
   prisoners in addition to clearly defined territories), you may have to award
   a point for each pass.

   I think implementing this simple scoring from the scratch would be easier
   than getting fully reliable "ordinary" scoring from GnuGo, mostly because
   gnuGo's scoring is aimed at scoring the game at a point when human players
   can see the end, wish not to spend time playing on, and want GnuGo to come
   with a decent score.

   You also state you need GnuGo for enumerating all legal moves. Again, a
   simple go board manager that enforces a super-ko rule (no position may be
   repeated) whould be fairly simple thing to code. You might probably not want
   to allow suicides (also trivial to code), as they can produce some
   pathologically long games, and have (practically) no relevance, even where
   allowed (chinese rules).


   I remain quite sceptical about the possibility of such a network ever
   learning to deal with even simple tactical considerations, like reading a
   ladder. But I wish you best of luck, and hope you'll keep us posted.


   - Heikki

   -- 
   Heikki Levanto  LSD - Levanto Software Development   <heikki@xxxxxxxxxxxxxxxxx>