solving tsumego on computers m2 hirokazu ishii chikayama & taura lab

34
Solving Tsumeg o on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Upload: charlotte-hunt

Post on 17-Jan-2018

249 views

Category:

Documents


0 download

DESCRIPTION

Agenda 1. Introduction 2. Related Work GoTools 3. Tsumego Solver Df-pn (Depth-First Proof-Number Search) Df-pn+ (Depth-First Proof-Number Search+) 4. Conclusion & Future Work

TRANSCRIPT

Page 1: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Solving Tsumego on Computers

M2 Hirokazu IshiiChikayama & Taura Lab

Page 2: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Agenda

1. Introduction2. Related Work

GoTools3. Tsumego Solver

Df-pn (Depth-First Proof-Number Search) Df-pn+ (Depth-First Proof-Number Search+)

4. Conclusion & Future Work

Page 3: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Agenda

1. Introduction2. Related Work

GoTools3. Tsumego Solver

Df-pn (Depth-First Proof-Number Search) Df-pn+ (Depth-First Proof-Number Search+)

4. Conclusion & Future Work

Page 4: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Computer Game Players Have been studied for many years

Easy to evaluateSuitable to try out various basic technologies

Were successful in some gamesOthello, backgammon, chess…

Great challenges remain in some gamesShogi, Go…

I study on Go, especially tsumego.

Page 5: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Game Rule Go is a 2-players game. A move is played on a line intersection. If one or more stones are completely surrounded

by other stones, they are captured. The purpose of Go is to conquer a larger part of

the board than the opponent.

Page 6: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Game Rule Eye

An eye is an area within a group of stones which is completely surrounded by stones of the group.

If the group gets two eyes, they are absolutely alive.

Page 7: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Definition of Tsumi

Variation of TsumiSemeai problemEscape and Disconnect problemLife and Death problem

Goal is to distinguish whether there are two eyes or not.

Page 8: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Method AND/OR tree search

OR NODE It corresponds to a first player’s move. In order to prove tsumi of this node, we must prove

that one node of child nodes has tsumi.AND NODE

It corresponds to a second player’s move. In order to disprove this node, we must disprove th

at all nodes of child nodes are tsumi.

Page 9: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Agenda

1. Introduction2. Related Work

GoTools3. Tsumego Solver

Df-pn (Depth-First Proof-Number Search) Df-pn+ (Depth-First Proof-Number Search+)

4. Conclusion & Future Work

Page 10: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

GoTools

Has been the best tsume-go solver for 15 years.

Uses a depth-first search. Specializes in completely enclosed positio

ns.

Page 11: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Heuristics Static rules

Most of the heuristic rules are static. It is at a particular auspicious point. It completes one or more eyes.・・・

Static rules rate moves lower or higher. Dynamic rules

The moves refuting opponent moves at subsequent positions also get some credit .

Page 12: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Dynamic Rules Number

The sequence in which the moves are made.

LetterThe field where

the stone is placed.

○:OR NODE□:AND NODE

1A

2B

3B

4C

5D

6D

Page 13: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Agenda

1. Introduction2. Related Work

GoTools3. Tsumego Solver

Df-pn (Depth-First Proof-Number Search) Df-pn+ (Depth-First Proof-Number Search+)

4. Conclusion & Future Work

Page 14: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Tsumego Solver

Important factors are to Recognize the position Generate candidate moves Evaluate these moves and select the next move

Evaluation of a tsumego is strictly determined life or death.

The only method of finding a strict solution is to search.

Page 15: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn Search

Depth-First SearchMemory and time are used efficiently. It is necessary to set a threshold.

Proof number Disproof number        Best-First search

Iterative DeepeningSearches are tried iteratively increasing the

threshold.

Page 16: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Proof Number Proof number is the minimum number of

descendant nodes which must be proven in order to prove the node.

We can see proof number of the node as the minimum resource required for search.

Proof number is effective for search because we want to search the most promising node.

Page 17: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Disproof Number Disproof number is the minimum number o

f descendant nodes that must be disproven in order to disprove the node.

Disproof number is effective for search as well as the proof number.

Page 18: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn Search

)(,0)( ndnnpn

0)(,)( ndnnpn

1)(,1)( ndnnpn

If n is a leaf nodewhen the value is true

when the value is false

When n is an uninspected nodeThe node might be proven or disproven imme

diately when inspected

Page 19: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn Search

)(min)( CpnnpnnofchildlenC

nofchildrenC

Cdnndn )()(

)(min)( CdnndnnofchildlenC

nofchildrenC

cnpnnpn )()(

If n is an internal nodewhen n is an OR node

when n is an AND node

Page 20: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn Search

Is a depth-first search. Uses two kinds of threshold (proof number

and disproof number)

1 .Assign

where r is the root node

dp thrthr .,.

Page 21: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn Search

2 .At each node n, the search process continues to search below n until

(We call it the ending condition)

pthnnpn .)(

dthnndn .)( or

Page 22: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn Search

3 .If n is an OR nodeAt each node n, select the child nc with the mi

nimum proof number and the child n2 with the second minimum proof number. Search below nc with assigning

)1.,.min(. 2 pnnthnthn ppc

nofchildrenC

cddc dnCdnnthnthn ....

Page 23: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn Search

4 .If n is an AND nodeAt each node n, select the child nc and the child

n2 . Search below nc with assigning

5 .If the ending condition holds, the search process returns to the parent node.

)1.,.min(. 2 dnnthnthn ddc

nofchildrenC

cppc pnCpnnthnthn ....

Page 24: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

A

Df-pn Search

R

D

I

E

H

B C

F

J

(∞,∞) ),(],[

dp ththdnpn○:OR NODE

□:AND NODE

G・・・

[1,1]

[1,1] [1,1] [1,1]

[1,3]

[1,1] [1,1] [1,1]

[30,1]

30 nodes

(2,∞-2)

[0,∞]

[2,1]

[1,3]

(2,∞-2)

[1,1] [1,1]

[1,3]

(3,∞-2)

[0,∞] [∞,0]

[∞,0]

[2,2]

(31,∞-1)

(30,2)

[0,∞]

[0,∞]

[1,1]

(31,∞-1)

[∞,0] [0,∞]

[0,∞]

[0,∞]

Page 25: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn+

Intends to distinguish promising moves more accurately and to search them much more deeper.

Uses two kinds of additional information during search.

Page 26: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn+

Two kinds of informationcost(dis)proof(n, nchild)

The cost of inspection of nchild starting from n.

h(dis)proof(n) Heuristic estimate of the cost to reach any proof so

lution from position n.

Page 27: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn+

The formula for calculating proof number and disproof number are modified from df-pn.

If node n is an uninspected node

)(npn )(nhproof)(ndn )(nhdisproof

Page 28: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Df-pn+ If n is an internal node

At each node n, search below nc with assigning

)((min)( CpnnpnnofchildlenC

),(cost Cnproof )

nofchildrenC

Cdnndn )(()( ),(cost Cndisproof )

dnndnnthnthn childcddc .(... )),(cos cdisproof nnt

),(cos cproof nntpnnthnthn ppc .,.min(. 2 ),(cos 2nnt proof )1

Page 29: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Bouzy’s 5/21 Algorithm

Dilation If the intersection is not surrounding

opponent’s stones, then add to the intersection the number of own interim territory and stones.

ErosionSubtract the number of intersections

with opponent’s stones or vacant.

Page 30: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Bouzy’s 5/21 Algorithm

41

1

1

1

2

2

2

2

Page 31: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

4 Dilation + 2 Erosion

1

7 9

5 6

5

8

5

2

8

2

1 2

10

10 12

11 12

102

6

8

2

6

5

Page 32: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Bouzy’s 5/21 Algorithm

In GNU Go ver. 2.6, it was extensively used 5 Dilation and 21 Erosion are used for territory. 5 Dilation and 10 Erosion are used for moyo. 4 Dilation and 0 Erosion are used for area.

Higher Bouzy value means higher expectation to form an eye.

Because two eyes are required to live, the second maximum Bouzy value may give a good criterion.

Page 33: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Agenda

1. Introduction2. Related Work

GoTools3. Tsumego Solver

Df-pn (Depth-First Proof-Number Search) Df-pn+ (Depth-First Proof-Number Search+)

4. Conclusion & Future Work

Page 34: Solving Tsumego on Computers M2 Hirokazu Ishii Chikayama & Taura Lab

Conclusion & Future Work

I showed… Definition of tsumi Feature of tsumego solver ‘GoTools’ Df-pn+ Bouzy’s 5/21 algorithm and its use in tsumego.

Firstly, I have to finish implementing the program. I also plan to apply the combinatorial game theory

to the program.