30
An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd , 1869. Lecture of October 2 nd , 2001

An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

  • View
    221

  • Download
    0

Embed Size (px)

Citation preview

Page 1: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2nd, 1869.

Lecture of October 2nd, 2001

Page 3: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

Game Playing (Adversarial Search)

Page 4: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 5: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 6: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 7: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 8: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 9: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 10: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

2

<= 2

Cut

14

<= 14

5

<= 5

2

<= 2

•Whenever a node gets its “true” value, its parent’s bound gets updated

•When all children of a node have been evaluated (or a cut off occurs below that node), the current bound of that node is its true value

•Two types of cutoffs:

•If a min node n has bound <=k, and a max ancestor of n, say m, has a bound >=l, then cutoff occurs as long as l >=k

•If a max node n has bound >=k, and a min ancestor of n, say m, has a bound <=l, then cutoff occurs as long as l <=k

Page 11: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

Von Neuman(Min-Max theorem)

Claude Shannon(finite look-ahead)

Chaturanga, India (~550AD)(Proto-Chess)

John McCarthy (pruning)

Donald Knuth(analysis)

Lecture of 4th October, 2001

Page 12: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

Searching Tic Tac Toe using Minmax

Page 14: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 15: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 16: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 17: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 18: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

Evaluation Functions: TicTacToe

If win for Max +inftyIf lose for Max -inftyIf draw for Max 0Else # rows/cols/diags open for Max - #rows/cols/diags open for Min

Page 19: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 20: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 21: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 22: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

Why is “deeper” better?

• Possible reasons– Taking mins/maxes of the evaluation values of

the leaf nodes improves their collective accuracy

– Going deeper makes the agent notice “traps” thus significantly improving the evaluation accuracy

• All evaluation functions first check for termination states before computing the non-terminal evaluation

Page 23: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 24: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

RTA*

S n

m

k

G

S

n mG=1H=2F=3

G=1H=2F=3

kG=2H=3F=5

infty

--Grow the tree to depth d --Apply f-evaluation for the leaf nodes--propagate f-values up to the parent nodes f(parent) = min( f(children))

Page 25: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001

Multi-player Games

Page 26: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 27: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 28: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 29: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001
Page 30: An eye for eye only ends up making the whole world blind. -Mohandas Karamchand Gandhi, born October 2 nd, 1869. Lecture of October 2 nd, 2001