Outline [AIMA Ch 13] 1 Uncertainty Probability Syntax and Semantics Inference Independence and Bayes' Rule.

Slides:



Advertisements
Similar presentations
Probability: Review The state of the world is described using random variables Probabilities are defined over events –Sets of world states characterized.
Advertisements

PROBABILITY. Uncertainty  Let action A t = leave for airport t minutes before flight from Logan Airport  Will A t get me there on time ? Problems :
Probabilistic Inference Reading: Chapter 13 Next time: How should we define artificial intelligence? Reading for next time (see Links, Reading for Retrospective.
Where are we in CS 440? Now leaving: sequential, deterministic reasoning Entering: probabilistic reasoning and machine learning.
Artificial Intelligence Uncertainty
Reasoning under Uncertainty: Conditional Prob., Bayes and Independence Computer Science cpsc322, Lecture 25 (Textbook Chpt ) March, 17, 2010.
Marginal Independence and Conditional Independence Computer Science cpsc322, Lecture 26 (Textbook Chpt 6.1-2) March, 19, 2010.
CPSC 422 Review Of Probability Theory.
Probability.
Artificial Intelligence Uncertainty Chapter 13. Uncertainty What shall an agent do when not all is crystal clear? Different types of uncertainty effecting.
Uncertainty Chapter 13. Uncertainty Let action A t = leave for airport t minutes before flight Will A t get me there on time? Problems: 1.partial observability.
KI2 - 2 Kunstmatige Intelligentie / RuG Probabilities Revisited AIMA, Chapter 13.
University College Cork (Ireland) Department of Civil and Environmental Engineering Course: Engineering Artificial Intelligence Dr. Radu Marinescu Lecture.
Representing Uncertainty CSE 473. © Daniel S. Weld 2 Many Techniques Developed Fuzzy Logic Certainty Factors Non-monotonic logic Probability Only one.
Ai in game programming it university of copenhagen Welcome to... the Crash Course Probability Theory Marco Loog.
Probability and Information Copyright, 1996 © Dale Carnegie & Associates, Inc. A brief review (Chapter 13)
Uncertainty Logical approach problem: we do not always know complete truth about the environment Example: Leave(t) = leave for airport t minutes before.
Uncertainty Chapter 13.
Uncertainty Chapter 13.
Probabilistic Reasoning
EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS
CS 4100 Artificial Intelligence Prof. C. Hafner Class Notes Feb 28 and March 13-15, 2012.
Handling Uncertainty. Uncertain knowledge Typical example: Diagnosis. Consider:  x Symptom(x, Toothache)  Disease(x, Cavity). The problem is that this.
Uncertainty Chapter 13. Uncertainty Let action A t = leave for airport t minutes before flight Will A t get me there on time? Problems: 1.partial observability.
CHAPTER 13 Oliver Schulte Summer 2011 Uncertainty.
An Introduction to Artificial Intelligence Chapter 13 & : Uncertainty & Bayesian Networks Ramin Halavati
CS 4100 Artificial Intelligence Prof. C. Hafner Class Notes March 15and20, 2012.
CS 4100 Artificial Intelligence Prof. C. Hafner Class Notes March 13, 2012.
Uncertainty Chapter 13. Outline Uncertainty Probability Syntax and Semantics Inference Independence and Bayes' Rule.
1 Chapter 13 Uncertainty. 2 Outline Uncertainty Probability Syntax and Semantics Inference Independence and Bayes' Rule.
Uncertainty Chapter 13. Outline Uncertainty Probability Syntax and Semantics Inference Independence and Bayes' Rule.
Probability and naïve Bayes Classifier Louis Oliphant cs540 section 2 Fall 2005.
An Introduction to Artificial Intelligence Chapter 13 & : Uncertainty & Bayesian Networks Ramin Halavati
Elementary manipulations of probabilities Set probability of multi-valued r.v. P({x=Odd}) = P(1)+P(3)+P(5) = 1/6+1/6+1/6 = ½ Multi-variant distribution:
Chapter 13 February 19, Acting Under Uncertainty Rational Decision – Depends on the relative importance of the goals and the likelihood of.
Uncertainty. Assumptions Inherent in Deductive Logic-based Systems All the assertions we wish to make and use are universally true. Observations of the.
Probability and Information Copyright, 1996 © Dale Carnegie & Associates, Inc. A brief review.
Uncertainty Chapter 13. Outline Uncertainty Probability Syntax and Semantics Inference Independence and Bayes' Rule.
Uncertainty Chapter 13. Outline Uncertainty Probability Syntax and Semantics Inference Independence and Bayes' Rule.
2101INT – Principles of Intelligent Systems Lecture 9.
Introduction to Artificial Intelligence CS 438 Spring 2008 Today –AIMA, Ch. 13 –Reasoning with Uncertainty Tuesday –AIMA, Ch. 14.
Web-Mining Agents Data Mining Prof. Dr. Ralf Möller Universität zu Lübeck Institut für Informationssysteme Karsten Martiny (Übungen)
Uncertainty Let action A t = leave for airport t minutes before flight Will A t get me there on time? Problems: 1.partial observability (road state, other.
Uncertainty 1. 2 ♦ Uncertainty ♦ Probability ♦ Syntax and Semantics ♦ Inference ♦ Independence and Bayes’ Rule Outline.
CSE 473 Uncertainty. © UW CSE AI Faculty 2 Many Techniques Developed Fuzzy Logic Certainty Factors Non-monotonic logic Probability Only one has stood.
Uncertainty Fall 2013 Comp3710 Artificial Intelligence Computing Science Thompson Rivers University.
Web-Mining Agents Data Mining Prof. Dr. Ralf Möller Universität zu Lübeck Institut für Informationssysteme Karsten Martiny (Übungen)
Uncertainty & Probability CIS 391 – Introduction to Artificial Intelligence AIMA, Chapter 13 Many slides adapted from CMSC 421 (U. Maryland) by Bonnie.
Introduction to Artificial Intelligence – Unit 7 Probabilistic Reasoning Course The Hebrew University of Jerusalem School of Engineering and Computer.
Pattern Recognition Probability Review
Marginal Independence and Conditional Independence
AIMA 3e Chapter 13: Quantifying Uncertainty
ECE 448 Lecture 12: Probability
Where are we in CS 440? Now leaving: sequential, deterministic reasoning Entering: probabilistic reasoning and machine learning.
Uncertainty Chapter 13.
Uncertainty Chapter 13.
Where are we in CS 440? Now leaving: sequential, deterministic reasoning Entering: probabilistic reasoning and machine learning.
EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS
Uncertainty.
Probability and Information
Uncertainty in Environments
Representing Uncertainty
Probability and Information
CS 188: Artificial Intelligence Fall 2008
CS 188: Artificial Intelligence Fall 2007
Uncertainty Logical approach problem: we do not always know complete truth about the environment Example: Leave(t) = leave for airport t minutes before.
Uncertainty Chapter 13.
Uncertainty Chapter 13.
Uncertainty Chapter 13.
Uncertainty Chapter 13.
Presentation transcript:

Outline [AIMA Ch 13] 1 Uncertainty Probability Syntax and Semantics Inference Independence and Bayes' Rule

Uncertainty Let action A t = leave for airport t minutes before flight Will A t get me there on time? Problems: ◦1) partial observability (road state, other drivers' plans, etc.) ◦2) noisy sensors (KCBS traffic reports) ◦3) uncertainty in action outcomes (at tire, etc.) ◦4) immense complexity of modeling and predicting traffic Hence a purely logical approach either ◦1) risks falsehood: A 25 will get me there on time" or 2) leads to conclusions that are too weak for decision making: “ A 25 will get me there on time if there's no accident on the bridge and it doesn't rain and my tires remain intact etc., etc." (A 1440 might reasonably be said to get me there on time but I'd have to stay overnight in the airport …) 2

Methods for handling uncertainty 3

Probability 4 Probabilistic assertions summarize effects of laziness: failure to enumerate exceptions, qualications, etc. ignorance: lack of relevant facts, initial conditions, etc. Subjective or Bayesian probability: Probabilities relate propositions to one's own state of knowledge e.g., These are not claims of a “probabilistic tendency” in the current situation (but might be learned from past experience of similar situations) Probabilities of propositions change with new evidence: e.g., (Analogous to logical entailment status KB ╞ α, not truth.)

Making decisions under uncertainty 5 Suppose I believe the following: Which action to choose? Depends on my preferences for missing flight vs. airport cuisine, etc. Utility theory is used to represent and infer preferences Decision theory = utility theory + probability theory

Probability basics 6

Random variables 7

Propositions 8 Think of a proposition as the event (set of sample points) where the proposition is true Given Boolean random variables A and B: event a = set of sample points where A(ω)=true event ¬ a = set of sample points where A(ω)=false event a ∧ b = points where A(ω)=true and B(ω)=true Often in AI applications, the sample points are defined by the values of a set of random variables, i.e., the sample space is the Cartesian product of the ranges of the variables With Boolean variables, sample point = propositional logic model e.g., A=true, B =false, or a ∧ ¬ b. Proposition = disjunction of atomic events in which it is true e.g., (a ∨ b) ≡ ( ¬ a ∧ b) ∨ (a ∧ ¬ b) ∨ (a ∧ b) ⇒ P(a ∨ b) = P( ¬ a ∧ b) + P(a ∧ ¬ b) + P(a ∧ b)

Why use probability? 9 The definitions imply that certain logically related events must have related probabilities E.g., P ( a ∨ b ) = P ( a ) + P( b ) - P ( a ∧ b ) de Finetti (1931): an agent who bets according to probabilities that violate these axioms can be forced to bet so as to lose money regardless of outcome.

Syntax for propositions 10 Propositional or Boolean random variables e.g., Cavity (do I have a cavity?) Cavity = true is a proposition, also written cavity Discrete random variables (finite or infinite) e.g., Weather is one of ( sunny, rain, cloudy, snow ) Weather = rain is a proposition Values must be exhaustive and mutually exclusive Continuous random variables (bounded or unbounded) e.g., Temp= 21.6; also allow, e.g., Temp < Arbitrary Boolean combinations of basic propositions

Prior probability 11 Prior or unconditional probabilities of propositions e.g., P(Cavity =true) = 0:1 and P(Weather =sunny) = 0:72 correspond to belief prior to arrival of any (new) evidence Probability distribution gives values for all possible assignments: P(Weather) = ( 0.72, 0.1, 0.08, 0.1 ) (normalized, i.e., sums to 1) Joint probability distribution for a set of r.v.s gives the probability of every atomic event on those r.v.s (i.e., every sample point) P(Weather,Cavity) = a 4x 2 matrix of values: Every question about a domain can be answered by the joint distribution because every event is a sum of sample points Weather =Weather =sunnyrainraincloudycloudysnowsnow Cavity =true Cavity =false

Conditional probability 12 Conditional or posterior probabilities e.g., P(cavity|toothache) = 0.8 i.e., given that toothache is all I know NOT “if toothache then 80% chance of cavity” (Notation for conditional distributions: P(Cavity|Toothache) = 2-element vector of 2-element vectors) If we know more, e.g., cavity is also given, then we have P(cavity|toothache, cavity) = 1 Note: the less specific belief remains valid after more evidence arrives, but is not always useful New evidence may be irrelevant, allowing simplification, e.g., P(cavity|toothache, TeamWon) = P(cavity|toothache) = 0:8 This kind of inference, sanctioned by domain knowledge, is crucial

Conditional probability 13

Inference by enumeration 14

Inference by enumeration 15

Inference by enumeration 16

Inference by enumeration 17

Normalization 18

Inference by enumeration, contd. 19 Let X be all the variables. Typically, we want the posterior joint distribution of the query variables Y given specific values e for the evidence variables E Let the hidden variables be H = X - Y - E Then the required summation of joint entries is done by summing out the hidden variables: P(Y | E  e)   ∑ h P(Y, E  e, H  h) The terms in the summation are joint entries because Y, E, and H together exhaust the set of random variables Obvious problems: 1)Worst-case time complexity O(d n ) where d is the largest arity 2)Space complexity O(d n ) to store the joint distribution 3)How to find the numbers for O(d n ) entries???

Independence 20 A and B are independent iff P(A|B)=P(A) or P(B|A)=P(B) or P(A,B)= P(A)P(B) P(Toothache, Catch, Cavity, Weather) = P(Toothache, Catch, Cavity)*P(Weather) 32 entries reduced to 12; for n independent biased counts, 2 n → n Absolute independence powerful but rare Dentristry is a large field with hundreds of variables, none of which are independent.What to do?

Conditional Independence 21 P ( Toothache,Cavity,Catch ) has = 7 independent entries If I have a cavity, the probability that the probe catches in it doesn't depend on whether I have a toothache: (1)P ( catch | toothache, cavity ) = P ( catch | cavity ) The same independence holds if I haven't got a cavity: (2) P ( catch | toothache,.cavity ) = P ( catch | cavity ) Catch is conditionally independent of Toothache given Cavity : P ( Catch | Toothache,Cavity ) = P ( Catch | Cavity ) Equivalent statements: P ( Toothache | Catch,Cavity ) = P ( Toothache | Cavity ) P ( Toothache,Catch | Cavity ) = P ( Toothache | Cavity ) P ( Catch | Cavity )

Conditional independence contd. Write out full joint distribution using chain rule: P(Toothache, Catch, Cavity) = P(Toothache | Catch,Cavity)P(Catch,Cavity) = P(Toothache | Catch,Cavity)P(Catch | Cavity)P(Cavity) = P(Toothache | Cavity)P(Catch | Cavity)P(Cavity) I.e., = 5 independent numbers (equations 1 and 2 remove 2) In most cases, the use of conditional independence reduces the size of the representation of the joint distribution from exponential in n to linear in n. Conditional independence is our most basic and robust form of knowledge about uncertain environments. 22

Bayes’ Rule 23

Bayes’ Rule and conditional independence 24 P(Cavity | toothache ∧ catch) = P(toothache ∧ catch | Cavity)P(Cavity) = P(toothache | Cavity)P(catch | Cavity)P(Cavity) This is an example of a naive Bayes model: P(Cause,Effect 1,...,Effect n ) = P(Cause)Π i P(Effect i | Cause) Total number of parameters linear in n

Wumpus World 25 P ij =true iff [i, j] contains a pit B ij =true iff [i, j] is breezy Include only in the probability model

Specifying the probability model 26

Observations and query 27

Using conditional independence 28 Basic insight: observations are conditionally independent of other hidden squares given neighboring hidden squares Define Unknown = Fringe ∪ Other Manipulate query into a form where we can use this!

Using conditional independence contd. 29

Using conditional independence contd. 30

Summary 31 Probability is a rigorous formalism for uncertain knowledge Joint probability distribution specifies probability of every atomic event Queries can be answered by summing over atomic events For nontrivial domains, we must find a way to reduce the joint size Independence and conditional independence provide the tools