Games with Chance Other Search Algorithms

Slides:



Advertisements
Similar presentations
Adversarial Search Reference: “Artificial Intelligence: A Modern Approach, 3 rd ed” (Russell and Norvig)
Advertisements

Games & Adversarial Search
Adversarial Search 對抗搜尋. Outline  Optimal decisions  α-β pruning  Imperfect, real-time decisions.
Minimax and Alpha-Beta Reduction Borrows from Spring 2006 CS 440 Lecture Slides.
Lecture 13 Last time: Games, minimax, alpha-beta Today: Finish off games, summary.
Games with Chance Other Search Algorithms CPSC 315 – Programming Studio Spring 2008 Project 2, Lecture 3 Adapted from slides of Yoonsuck Choe.
Optimization via Search CPSC 315 – Programming Studio Spring 2008 Project 2, Lecture 4 Adapted from slides of Yoonsuck Choe.
1 Adversary Search Ref: Chapter 5. 2 Games & A.I. Easy to measure success Easy to represent states Small number of operators Comparison against humans.
Game Trees: MiniMax strategy, Tree Evaluation, Pruning, Utility evaluation Adapted from slides of Yoonsuck Choe.
Minimax Trees: Utility Evaluation, Tree Evaluation, Pruning CPSC 315 – Programming Studio Spring 2008 Project 2, Lecture 2 Adapted from slides of Yoonsuck.
Game Playing. Introduction One of the earliest areas in artificial intelligence is game playing. Two-person zero-sum game. Games for which the state space.
Lecture 3: Uninformed Search
CSCI 4310 Lecture 6: Adversarial Tree Search. Book Winston Chapter 6.
Game Playing Revision Mini-Max search Alpha-Beta pruning General concerns on games.
Graph Search II GAM 376 Robin Burke. Outline Homework #3 Graph search review DFS, BFS A* search Iterative beam search IA* search Search in turn-based.
Search: Games & Adversarial Search Artificial Intelligence CMSC January 28, 2003.
Chapter 3 Solving problems by searching. Search We will consider the problem of designing goal-based agents in observable, deterministic, discrete, known.
Artificial Intelligence Solving problems by searching.
Lecture 3 Problem Solving through search Uninformed Search
Lecture 3: Uninformed Search
Optimization via Search
Announcements Homework 1 Full assignment posted..
By: Casey Savage, Hayley Stueber, and James Olson
Stochastic tree search and stochastic games
Data Structures Lab Algorithm Animation.
Last time: search strategies
Problem Solving Agents
Adversarial Search and Game Playing (Where making good decisions requires respecting your opponent) R&N: Chap. 6.
For Monday Chapter 6 Homework: Chapter 3, exercise 7.
Lecture 7 Constraint Satisfaction Problems
Problem Solving by Searching
CS 188: Artificial Intelligence Fall 2007
Artificial Intelligence (CS 370D)
Expectimax Lirong Xia. Expectimax Lirong Xia Project 2 MAX player: Pacman Question 1-3: Multiple MIN players: ghosts Extend classical minimax search.
CSCI 5582 Artificial Intelligence
Games & Adversarial Search
Games with Chance Other Search Algorithms
Games with Chance Other Search Algorithms
Finding Heuristics Using Abstraction
Artificial Intelligence
Artificial Intelligence and Searching
Announcements Homework 3 due today (grace period through Friday)
Alpha-Beta Search.
Problem Solving and Searching
Games & Adversarial Search
Graphs.
Games & Adversarial Search
NIM - a two person game n objects are in one pile
Artificial Intelligence
Problem Solving and Searching
Alpha-Beta Search.
Introduction to Artificial Intelligence Lecture 9: Two-Player Games I
Alpha-Beta Search.
Pruned Search Strategies
More on Search: A* and Optimization
Game Playing Fifth Lecture 2019/4/11.
Alpha-Beta Search.
Mini-Max search Alpha-Beta pruning General concerns on games
UNINFORMED SEARCH -BFS -DFS -DFIS - Bidirectional
Lecture 4: Matching Algorithms
Search.
CS 416 Artificial Intelligence
Search.
CMSC 471 Fall 2011 Class #4 Tue 9/13/11 Uninformed Search
Games & Adversarial Search
Alpha-Beta Search.
Games & Adversarial Search
Artificial Intelligence and Searching
Games & Adversarial Search
Minimax Trees: Utility Evaluation, Tree Evaluation, Pruning
Presentation transcript:

Games with Chance Other Search Algorithms CSCE 315 – Programming Studio Fall 2017 Project 2, Lecture 3 Adapted from slides of Yoonsuck Choe, John Keyser

Game Playing with Chance Minimax trees work well when the game is deterministic, but how about games with an element of chance Solitaire: Shuffles are random Monopoly: Next move depends on die rolling outcome How do we analyze games with chance? Include Chance nodes in tree Try to maximize/minimize the expected value Or, play pessimistic/optimistic approach

… Tree with Chance Nodes Max Chance … Min Chance For each die roll (red lines), evaluate each possible move (blue lines)

Expected Value For variable x, the Expected Value is: where Pr(x) is the probability of x occurring Example 1: When you roll a dice, what is average value on the face? Example 2: How about rolling a pair of dice?

… Evaluating Tree Choosing a Maximum (same idea for Minimum): Chance … Min Chance Choosing a Maximum (same idea for Minimum): Evaluate same move from ALL chance nodes Find Expected Value for that move Choose largest expected value

More on Chance Rather than expected value, could use another approach Maximize worst case value Avoid catastrophe Give high weight if a very good position is possible “Knockout” move Form hybrid approach, weighting all of these options Note: time complexity increased to O(bmnm) where n is the number of possible choices (m is depth)

AI in Larger-Scale and Modern Computer Games The idealized situations described often don’t extend to extremely complex, and more continuous games. Even just listing possible moves can be difficult Example: Walking 10 steps to the right or 11, or 1000 Larger situation can be broken down into subproblems Hierarchical approach Use of state diagrams Some subproblems are more easily solved e.g. path planning

General State Diagrams List of possible states one can reach in the game (nodes) Can be abstracted, general conditions Describe ways of moving from one state to another (edges) Not necessarily a set of move, could be a general approach Forms a directed (and often cyclic) graph Our minimax tree is a state diagram, but we hide any cycles Sometimes want to avoid repeated states

General State Diagrams

State Diagram State C State I State A State B State D State J State E State H State G State K State F

Exploring the State Diagram Explore for solutions using BFS, DFS Depth limited search: DFS but to limited depth in tree Iterative Deepening search: As described before, but with DFS on graph, not just tree If a specific goal state, can use bidirectional search Search forward from start and backward from goal – try to meet in the middle. Think of maze puzzles

Path Planning What would your design be?

More Informed Search Traversing links, goal states not always equal Can have a heuristic function: h(x) = how close the state x is to the “goal” state. Kind of like board evaluation function/utility function in game play Can use this to: order other searches create greedy approaches