Adversarial Search

12
Adversarial Search Board games

description

Adversarial Search. Board games. Games. 2 player zero-sum games Utility values at end of game – equal and opposite Games that are easy to represent Chess – average branching factor 35 Games need to make decisions even when optimal decisions are infeasible in limited time. - PowerPoint PPT Presentation

Transcript of Adversarial Search

Page 1: Adversarial Search

Adversarial Search

Board games

Page 2: Adversarial Search

Games

2 player zero-sum games Utility values at end of game – equal and

opposite Games that are easy to represent Chess – average branching factor 35 Games need to make decisions even when

optimal decisions are infeasible in limited time

Page 3: Adversarial Search

Evaluation fn for Tic-Tac-Toe

if position p is win for MAX– E(p) = 100

If position p is win for MIN– E(p) = -100

If not win position for either – E(p) = open lines for MAX – open lines for MIN

Page 4: Adversarial Search

Alpha - beta

Backed up Lower bound is alpha value Backed up upper bound is beta value Alpha at max can never decrease Beta at MIN can never increase

Page 5: Adversarial Search

pruning

If beta at any MIN

<= alpha of any of its MAX ancestors

final backed up value = its beta value

If alpha at any MAX

>= beta at any of its MIN ancestors

final backed up value = its alpha value

Page 6: Adversarial Search

Updating alpha and beta

Alpha at MAX node = current largest final backed up value of its successors

Beta at MIN node = current smallest final backed up value of its successors

Page 7: Adversarial Search

Search efficiency

In time alpha-beta search proceeds to depth d, simple minimax just proceeds to depth d/2

Search reduces effective branching factor from b to √b

Page 8: Adversarial Search

Good heuristics

Examine best moves first– Capture piece– take care of threats– Move forward– Move backward

Use Iterative deepening– Evaluate best moves for one ply– Evaluate best moves for 2 ply…– Abort search if time constraint enforced

Page 9: Adversarial Search

More efficiency

Take care of repeated states, resulting from different permutations

Use Transposition table Read 6.6 for state of art news

Page 10: Adversarial Search

State of the art

IBM’s Deep Blue defeated grandmaster Gary Kasparov in 1997, in a 6 game match

30 processors with 480 custom VLSI chess processors

Average search speed – 126 million nodes per second

Evaluation function had 8000 features Database of 700,000 grandmaster games were used

Page 11: Adversarial Search

Power?

IBM contributed the success to hardware Developers maintained that search

extensions and evaluation functions more critical

Deep blue team declined a chance for a rematch with Kasparov.

Page 12: Adversarial Search

Chess on PCs

2002 FRITZ program on a PC against Vladimir Karamnik. The 8 game match ended in a draw