1 / 23

Quantifying Uncertainty II Session 9

Course : Artificial Intelligence Effective Period : September 2018. Quantifying Uncertainty II Session 9. Learning Outcomes. At the end of this session, students will be able to: LO 4: Apply various techniques to an agent when acting under certainty. Outline.

paulpeters
Download Presentation

Quantifying Uncertainty II Session 9

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Course : Artificial Intelligence Effective Period : September 2018 Quantifying Uncertainty IISession 9

  2. Learning Outcomes At the end of this session, students will be able to: • LO 4: Apply various techniques to an agent when acting under certainty

  3. Outline Inference using Full-Joint Distribution Independence Bayes Theorem Exercise

  4. Inference Using Full Joint Distributions • Probabilistic Inference • Given observed evidence, estimate the posterior probability! • Full-joint distribution = Knowledge base

  5. Inference Using Full Joint Distributions • Probabilistic Inference • To measure the probability of Cavity = True, we use marginalization (or summing out)

  6. Inference Using Full Joint Distributions • Full Joint Distribution for the Toothache, Cavity, Catch • Four possible world in which cavity holds: • P(cavity) = 0.108 + 0.012 + 0.016 + 0.064 = 0.2

  7. Inference Using Full Joint Distributions • Full Joint Distribution for the Toothache, Cavity, Catch • Six possible world in which cavity  toothacheholds: • P(cavity  toothache) • = 0.108 + 0.012 + 0.072 + 0.008 + 0.016 + 0.064 = 0.28

  8. Inference Using Full Joint Distributions • Full Joint Distribution for the Toothache, Cavity, Catch • Can also compute conditional probabilities: • P(cavity | toothache) • = P(cavity toothache) / P(toothache) • = (0.016+0.064) / (0.108 + 0.012 + 0.016 + 0.064) • = 0.4

  9. Independence • How are P(toothache, catch, cavity, cloudy) and P(toothache, catch, cavity) related? • Use the product rule : • P(toothache, catch, cavity, cloudy) = P(cloudy | toothache, catch, cavity) P(toothache, catch, cavity) • However, the weather does not influence the dental variables, therefore : (independence) • P(cloudy | toothache, catch, cavity) = P(cloudy)

  10. Independence • 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)

  11. Independence

  12. Independence • Conditional independence • P(X, Y | Z) = P(X | Z)P(Y | Z) • As example, let’s take a look at toothache and catch probabilities, given cavity • P(toothache ∧ catch | Cavity) = P(toothache | Cavity)P(catch | Cavity) • These variables are independent, give the presence or the absence of a cavity

  13. Probability and Bayes’ Theorem • Bayes’ rule or Bayes’ theorem • Why use this? • We perceive as evidence the effectof some unknown causeand we would like to determine that cause

  14. Probability and Bayes’ Theorem For example, a doctor knows that the disease meningitis causes the patient to have a stiff neck, say, 70% of the time The doctor also knows some unconditional facts: the prior probability that a patient has meningitis is 1/50,000, and the prior probability that any patient has a stiff neck is 1%.

  15. Probability and Bayes’ Theorem Vany had onset of symptoms such as spots on the face. Doctor diagnose that Vany got chicken pox with the possibility: Probability appearance of spots on the face, if Vany got chicken pox, p (spots/chicken pox) = 0,8 Probability Vany got chicken pox without notice any symptoms, p(chicken pox) = 0,4 Probability appearance of spots on the face, if Vany got allergy, p(spots/allergy) = 0,3 Probability Vany got allergy without notice any symptoms, p(allergy) = 0,7

  16. Probability and Bayes’ Theorem Probability appearance of spots on the face, if Vany got pimples, p(spots/pimples) = 0,9 Probability that Vany got pimples without notice any symptoms, p(pimples) = 0,5 Calculate the probability of each symptoms stated above!

  17. Probability and Bayes’ Theorem Problem : Marie is getting married tomorrow, at an outdoor ceremony in the desert. In recent years, it has rained only 5 days each year. Unfortunately, the weatherman has predicted rain for tomorrow. When it actually rains, the weatherman correctly forecasts rain 90% of the time. When it doesn't rain, he incorrectly forecasts rain 10% of the time. What is the probability that it will rain on the day of Marie's wedding?

  18. Probability and Bayes’ Theorem • Solution: The sample space is defined by two mutually-exclusive events - it rains or it does not rain. Additionally, a third event occurs when the weatherman predicts rain. Notation for these events appears below. • Event A1. It rains on Marie's wedding. • Event A2. It does not rain on Marie's wedding. • Event B. The weatherman predicts rain.

  19. Probability and Bayes’ Theorem • P( A1 ) = 5/365 = 0.0136985 [It rains 5 days out of the year.] • P( A2 ) = 360/365 = 0.9863014 [It does not rain 360 days out of the year.] • P( B | A1 ) = 0.9 [When it rains, the weatherman predicts rain 90% of the time.] • P( B | A2 ) = 0.1 [When it does not rain, the weatherman predicts rain 10% of the time.]

  20. Probability and Bayes’ Theorem We want to know P( A1 | B ), the probability it will rain on the day of Marie's wedding, given a forecast for rain by the weatherman. The answer can be determined from Bayes' theorem, as shown below.

  21. References Stuart Russell, Peter Norvig. 2010. Artificial Intelligence : A Modern Approach. Pearson Education. New Jersey. ISBN:9780132071482 http://aima.cs.berkeley.edu

  22. Exercise

  23. Exercise Bayes Theorem There are three boxes each containing two balls. Box I contains two red balls, box II contains one red ball and one white ball, while box III contains two white balls. Without looking, you are asked to take one box randomly, and then take one ball randomly from the chosen box. You are told that the ball is red. Question: What is the probability of the ball being taken from each boxes?

More Related