Re: [computer-go] Position Rich in Lessons

2009-06-23 Thread Magnus Persson

Quoting Brian Sheppard :


What komi did you use? It is nice to have the sgf in addition to the

position.

It is 7.5, and I do not have the SGF. I will try to create SGF for future
posts, to make reproduction easier for all.



Could it be that Pebbles have trouble seeing that the semeai is won
after white C9.


Yes, exactly. Pebbles has no code (in either search or playouts) for winning
semeais of more than one move. No pattern that identifies C9 as a good
move for O.

There is code that finds C9 for X: it is a winning snapback. There is
no code that tries to play the opponent's move, so the knowledge does not
transfer from one color to the other.

What rule proposes C9 in Many Faces or Valkyria?


C9 is not treated in a special way. I guess in this case it is AMAF  
that finds it and play at te root level. I use the same code to bias  
the tree part as I use for the playouts. In the playouts a lot of  
tactical code for pruning bad suicidal moves and playing forced moves  
(when the number of liberties in the semeai is 2 or less) are used.


I can also be that Valkyria finds C9 for X quickly if O does not play it.



  1 2 3 4 5 6 7 8 9
A - - - - - - - - -
B - O O O O X X X O
C - X X X O O X O -
D - O - X O X O O -
E O - O O X X O X X
F - O X X X X X O -
G - X X - - O X O -
H X O O O - - X X O
J - - - - - - - O -

On the face of it, C9 doesn't put O ahead in any semeai. After C9, O is
behind X's B8 string by 3 liberties to 2, and O is behind X's E8 string
by 2 liberties to 2 with X to move.



Anyway I entered the position manually with komi 7.5, and Valkyria
plays C9 right away winning the semeai in the upper right corner and
after that white wins 0.5 even if black gets everything else.



C9 is winning, but it isn't so obvious as Magnus suggests. There are
several complexities to see through.


Your analysis is correct. And to me it just appears quite obvious. And  
as David point out it is not physical liberties that are counted but  
the move necessary to play.



1) O wins the semeai on top only if O moves first. After X's A8, O must
find A6, A5, and A7. Those moves must be played in that order, because if
X plays A8 and A6 then X wins the semeai because O cannot play A9, which
is self-atari.

2) If O tenukis at any time, then X wins by playing F9 or G9, followed
by capturing O's F8/G8 string, and atari with D9.

3) In a random-play game, the fact that X has 2 sequences versus 1 (i.e.,
F9 or G9 for X versus only A6 for O) makes up for the fact that O gets to
move first. So it is vitally important to have code in the playouts that
handle the semeai more accurately for O than purely random.

4) Magnus says "wins by 0.5 even if Black gets everything else" but that's
not right. O must also win the semeai at left. In a random-play game, O
would lose that battle fairly often. The principal way to lose is X C1,
O tenuki, X D3 (atari), O E2, X F1 (atari), O G1 and a Ko fight for life.


The O must win the semeai is also obvious. What I meant is that O can  
let X start ko fights and win them as long O just captures the large X  
block.



5) The Ko fight there is a picnic for X, since X was counting on losing
anyway. It follows that X will gain a move in the battle of his choice,
so O will only win if his tenuki was played in the semeai at upper right.

I think that to play this situation completely right you must have playout
policies that specifically drive success in semeais and/or ko.


Valkyria does nothing intelligent when it comes to ko and wins always  
in this position. But this is because white can let black win all  
small ko fight as long as all important semeais is won. So in this  
position only semeai knowledge is necessary.


But you might try to decrease the komi, because then white will have  
to win with a larger margin! That could make the position much harder  
to read out correctrly.



Those successful policies do not have to be right for the right reason.
For example, if you play C9 because you believe that it is the only move
that has a chance of winning the semeai against E8/E9, then you are right
for the wrong reason, because there is no way to win against E8/E9;
C9 just happens to win against another string.



Without heuristics that specifically drive success, the combination of
multiple battles make matters combinatorially worse.

For example, the dynamic in Pebbles is for the moves that win the semeais to
be
the second, third, fourth or higher move generated. This is not so bad
if there is only one battle. But when multiple battles are joined, X can
play a forcing move for a turn in another battles, and then return
to the other side. It is a dynamic version of the horizon effect, where bad
effects are first pushed out, and then delayed by bad move ordering.

I think that working on this position will yield several advances in
move ordering. I have already found the snapbacks, and I think there
will be others.


Are you talking about move ordering in the tree or the playouts

RE: [computer-go] Position Rich in Lessons

2009-06-22 Thread David Fotland
There is a book (2nd Book of Go, I think) that teaches how to count
liberties in a semeai.  Once O plays C9 it has far more than two liberties,
since black has to play approach moves on either side to win the semeai.
For example, black has to play 3 times to fill the liberty at D9, and black
can never fill the liberty at A9.  So O has at least 4 liberties after C9 is
played.  

If you count "semeai liberties" correctly, it's obvious that white C9 group
has more liberties than the black group (after C9 is played).  So Many Faces
can see directly that O wins the semeai after C9 is played.  So a one ply
search finds that C9 is a good move.  Many Faces' heuristics then encourage
the UCT search to try this move first, and it holds up well in the playouts.

David

> -Original Message-
> From: computer-go-boun...@computer-go.org [mailto:computer-go-
> boun...@computer-go.org] On Behalf Of Brian Sheppard
> Sent: Monday, June 22, 2009 3:01 PM
> To: computer-go@computer-go.org
> Subject: [computer-go] Position Rich in Lessons
> 
> 
> What rule proposes C9 in Many Faces or Valkyria?
> 
>   1 2 3 4 5 6 7 8 9
> A - - - - - - - - -
> B - O O O O X X X O
> C - X X X O O X O -
> D - O - X O X O O -
> E O - O O X X O X X
> F - O X X X X X O -
> G - X X - - O X O -
> H X O O O - - X X O
> J - - - - - - - O -
> 
> On the face of it, C9 doesn't put O ahead in any semeai. After C9, O is
> behind X's B8 string by 3 liberties to 2, and O is behind X's E8 string
> by 2 liberties to 2 with X to move.
> 


___
computer-go mailing list
computer-go@computer-go.org
http://www.computer-go.org/mailman/listinfo/computer-go/


RE: [computer-go] Position Rich in Lessons

2009-06-22 Thread David Fotland
Many Faces also plays c9 right away, with about 66% win for O, expecting A8
then A6.

> -Original Message-
> From: computer-go-boun...@computer-go.org [mailto:computer-go-
> boun...@computer-go.org] On Behalf Of Magnus Persson
> Sent: Monday, June 22, 2009 7:05 AM
> To: computer-go@computer-go.org
> Subject: Re: [computer-go] Position Rich in Lessons
> 
> Quoting Brian Sheppard :
> 
> >
> > Further analysis convinced me that O is actually winning this game. My
> > current
> > engine likes A8 for O until iteration 7000, and then F9 for O, and
> switches
> > to the winning move only on iteration 143,000. But it doesn't really
> "see"
> > the win, because the evaluation remains around 50.3% no matter how long
> > Pebbles
> > searches.
> 
> What komi did you use? It is nice to have the sgf in addition to the
> position.
> 
> Anyway I entered the position manually with komi 7.5, and Valkyria
> plays C9 right away winning the semeai in the upper right corner and
> after that white wins 0.5 even if black gets everything else.
> 
> Could it be that Pebbles have trouble seeing that the semeai is won
> after white C9. Valkyria expects black A8 after C9 which delays the
> capture of the white stones. Sometimes Valkyria has (or used to)
> problems evaluating such semeais.
> 
> -Magnus
> 
> 
> --
> Magnus Persson
> Berlin, Germany
> ___
> computer-go mailing list
> computer-go@computer-go.org
> http://www.computer-go.org/mailman/listinfo/computer-go/

___
computer-go mailing list
computer-go@computer-go.org
http://www.computer-go.org/mailman/listinfo/computer-go/


Re: [computer-go] Position Rich in Lessons

2009-06-22 Thread Magnus Persson

Quoting Brian Sheppard :



Further analysis convinced me that O is actually winning this game. My
current
engine likes A8 for O until iteration 7000, and then F9 for O, and switches
to the winning move only on iteration 143,000. But it doesn't really "see"
the win, because the evaluation remains around 50.3% no matter how long
Pebbles
searches.


What komi did you use? It is nice to have the sgf in addition to the position.

Anyway I entered the position manually with komi 7.5, and Valkyria  
plays C9 right away winning the semeai in the upper right corner and  
after that white wins 0.5 even if black gets everything else.


Could it be that Pebbles have trouble seeing that the semeai is won  
after white C9. Valkyria expects black A8 after C9 which delays the  
capture of the white stones. Sometimes Valkyria has (or used to)  
problems evaluating such semeais.


-Magnus


--
Magnus Persson
Berlin, Germany
___
computer-go mailing list
computer-go@computer-go.org
http://www.computer-go.org/mailman/listinfo/computer-go/