SlideShare a Scribd company logo
1 of 28
Download to read offline
Computer vision: models, learning
and inference
Chapter 2
Introduction to probability
Please send errata to s.prince@cs.ucl.ac.uk
Random variables
• A random variable x denotes a quantity that is
uncertain
• May be result of experiment (flipping a coin) or a real
world measurements (measuring temperature)
• If observe several instances of x we get different
values
• Some values occur more than others and this
information is captured by a probability distribution
2Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
TAKE '¥±K¥k
Discrete Random Variables
3Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
tf.az#AkTak9zTf ER
Continuous Random Variable
4Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
ELIE Fifa If Ek
Joint Probability
• Consider two random variables x and y
• If we observe multiple paired instances, then some
combinations of outcomes are more likely than others
• This is captured in the joint probability distribution
• Written as Pr(x,y)
• Can read Pr(x,y) as “probability of x and y”
5Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
TH # ¥ BHI 'T
Joint Probability
6Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
Knight
&Ef¥Me
tapas
Apk
like
teak EL
Tak EE
like The
tggqttpkh.be Heifetz ¥pHz4akKI
Marginalization
We can recover probability distribution of any variable in a joint distribution
by integrating (or summing) over the other variables
7Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
Eh Ela
:
(
I
I
I
I
I
I
l
a a At EG
'
Fe CERE 9¥88 ) E ti K 's k R
.
!
X E An C ,
L 2
'
EEE Ffa FE it FEE B !
To 3 .
Is a 17k¥ G
'
if 2-
'
it . f a-
IEEE
IKER I
If a za FEE Be c 2 ,
K 2 ME He c E 2 I a Y
I
A
"
ER y
'
7 3 EPzE¥ E TE 2 IT .
!
Marginalization
We can recover probability distribution of any variable in a joint distribution
by integrating (or summing) over the other variables
8Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
tfafzFawkes t.BE is FE. & a Z
Ek 2 .
•
- - - - - - - - - - - - -
- -
-
.
Marginalization
We can recover probability distribution of any variable in a joint distribution
by integrating (or summing) over the other variables
9Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
M
=be;÷¥÷:÷¥*÷¥:::¥¥÷÷÷÷÷÷÷
. .
I 9
"
HEGE EE ka 2. FERta
Marginalization
We can recover probability distribution of any variable in a joint distribution
by integrating (or summing) over the other variables
Works in higher dimensions as well – leaves joint distribution between
whatever variables are left
10Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
77 ok K C 77 EIH ME IT TG E As fZe .
Ke 8 a his a¥ 8 top Z fi H 3 k on ,
R2 I Z Aztec ,
TashI TakaE a w z
-
K E. ER . KLEEATE n Za
'
FER'S -53 .
Conditional Probability
• Conditional probability of x given that y=y1 is relative
propensity of variable x to take different outcomes given that y
is fixed to be equal to y1.
• Written as Pr(x|y=y1)
11
Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
Ff 44 He E EThe tf
y ee f ,
k EHEEL k ZE . 7 I Y I a-
-
F s
2- Tn 32€ a
ok a
KkkEE 8 top
↳
-
L
.
¥KEE E FF ,
2 I I E "
IT 2- it Fife FFS Fp u is
z taken THAT Y G y g q .
.
.
22 e
"
22 5 .
life II I TM a KEKE if .
E 2
*Ep If 9 22 I e
-
-
A 3 a
"
.
= th 2- I H 's 22 u 5 'so
U is .
To h =
s KERA
FE 2 z
EEE's c E ZE k
Ia Etfd
"
I e-
A 3 F 's
a IE Bae
EM
c I 3 .
u F- A
"
,
2
* in e
'
Eai 'm
't
→
I c =
22 3 a
THE
's T2
" o
42 a no -
I
"
Fi
'
a 5 .
EREH 3 I FER To 2¥ By a
"
To 3 ,
Conditional Probability
• Conditional probability can be extracted from joint probability
• Extract appropriate slice and normalize
12Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
g
EST THE Fi
'
it E EH Y E
-
-
T e Be t a = k Fi
'
H
.
you
.
y
*
a 2€ a g a EA a 5¥ ↳
¥
Eaglets 3¥ ! f a
- -
ft eh 's
In:&,
'
Ian .
hEs
u EAin .
C
I a BIKE HE et
4¥.
8 to 3 2 I iz it ?
¥ f- sa k EE EE E Etty 4h c E 's FE EH n ME I F The Za
Azul
,
2 ,
EE EE TE h¥ a FER A 6 "
I k A 3 F 7 iz I ER he
t 3 La FE to
"
In 3
Conditional Probability
• More usually written in compact form
• Can be re-arranged to give
13Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
€.
:*"¥⇒÷÷:*
.
¥**±⇒=÷¥÷÷÷
--
-
EffectED of M¥715.5
Conditional Probability
• This idea can be extended to more than two
variables
14Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
-
Z a I I 55 Fp
-
YEAHHTT 5 R F- FA I 8 Fp
- -
-
K n y a Z I Ff htt ht IT 5 RE EH E 5 Ep
Bayes’ Rule
From before:
Combining
:
Re-
arranging:
15Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
Eff4 Ft I B Fp a
"
An -
a 32 .
no a a
.
.
*
. .
g a
-
3 .
A
'
h K
'
a Be EBE
THE¥ EEE
If it K2 "
¥44
ft H 2 E L 2
.
EH4 tf it
2 E A E .
t
fi
'
a 5 Eg § a
Fet 3 .
Bayes’ Rule Terminology
Posterior – what we
know about y after
seeing x
Prior – what we know
about y before seeing x
Likelihood – propensity for
observing a certain value of
x given a certain value of y
Evidence –a constant to
ensure that the left hand
side is a valid distribution
16Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
fi Fk (
'
¥HffEEeEz¥)
* '
HER '
kit " k¥-7424 .
.
z¥¥, §
THE 'a5kE2E9ka¥H #Tt
( ¥ ¥,
↳q¥ it ← 5Th )
-iFex¥¥iETT{}
= ¥14184
-344784C ¥1467 BEGET
IS # HIER 3-kkn.tk#k2HBeFtK-3kcTiGczOk .
(Ef
4564k¥
)
737×4 KEEN 3913449 Kritz By 2- I 3 .
Independence
• If two variables x and y are independent then variable x tells us
nothing about variable y (and vice-versa)
17Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
HEE
← ya
"
x a EEE ¥4 -
a ¥4 94dg z
ELK a
.
IT a 4¥ IKE FEE 34
EINE ,
a e f it f)eh I 2 "
In 3
U '
'
so FEE Ff c
"
.
Y $
"
Y ,
a z E 't
) :*. :*'s.
¥:
" "
⇒ y it iceI'M
'
Fatih Et ¥ EH - .
.
Independence
• If two variables x and y are independent then variable x tells us
nothing about variable y (and vice-versa)
18Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
¥4993971 a FBA '
E E FAL
' '
.
Independence
• When variables are independent, the joint factorizes into a
product of the marginals:
19Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
-
Ah I a z I or L in Ffa FR e I ¥ EI en D
-
s .
K Fi
'
I a
ERK EE
-
a Ft v .
HE .
2 ARE a GEEK n A ② ¥ To Ep is
q th z
"
k EEE 'T a
ftp.t '
Eat 3 .
Expectation
Expectation tell us the expected or average value of some
function f [x] taking into account the distribution of x
Definition:
20Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
Eta 4¥ HE
a a Tropez It B FT E % C 2 .
FIFE K f EX ] a K IF A 7 A .
I 2 u it
THE ET I th 2 f TE E fi k 3 .
um
K K a
'
4h 2 C 3 .
d to
"
Totalk Faklike
n
HIPFa
x g
ETE If ri EI H It IT c K f ex , 2 '
ItE. & a E ER 2 .
a
*
KLEENE
a
Eka Es
a AFF to
Expectation
Expectation tell us the expected or average value of some
function f [x] taking into account the distribution of x
Definition in two dimensions:
21Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
2 s KK a -438 Fr .
x e f n THE¥ Eth EE I
'
Fs H ht i J c Te f Lx . g ]
E = EE EEN, .
E Fil .
= a TH it K E I E FLEE ftp.
~
7 LE Y V
Expectation: Common Cases
22Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
AME 's
FIG
EEE . y at 'E9
E -
tst
KEG Yaba
"
FFF # Yakka
£ch¥fhk3 . an FIFE 3k
E -
fit
BEAK
EEFE
FIFE IEIFT.tn#aEEa2ct22iz .
k£4123
¥B¥A
Expectation: Rules
Rule 1:
Expected value of a constant is the constant
23Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
Reiko Kk a Hai EE the es k Za E a .
Expectation: Rules
Rule 2:
Expected value of constant times function is constant times
expected value of function
24Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
k
f = = a k x k .
2 .
ItEe
-
naw
IFF Sos II EI K FEE 47 E
'
'
a
-
's .
FEEL k He E C 2 E IF o E "
K S 7 t E I 2 .
Expectation: Rules
Rule 3:
Expectation of sum of functions is sum of expectation of
functions
25Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
As f- He FEND a FREE H FEE ft E
-
a
-
s .
Expectation: Rules
Rule 4:
Expectation of product of functions in variables x and y
is product of expectations of functions if x and y are independent
26Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
He 8 a
"
Heh EHF Box Es a 4
= a fly a Bfa 43 .
Conclusions
27Computer vision: models, learning and inference. ©2011 Simon J.D. Prince
• Rules of probability are compact and simple
• Concepts of marginalization, joint and conditional
probability, Bayes rule and expectation underpin all of the
models in this book
• One remaining concept – conditional expectation –
discussed later
¥2 If RFI H a U L ,
D ' '
I 93 a fit IT 3 I 2 ,
-
Eff4 tf E FEE 4¥ The et KK 2
.
43 .
02 Introduction to probability ノート

More Related Content

Recently uploaded

Tuberculosis (TB)-Notes.pdf microbiology notes
Tuberculosis (TB)-Notes.pdf microbiology notesTuberculosis (TB)-Notes.pdf microbiology notes
Tuberculosis (TB)-Notes.pdf microbiology notes
jyothisaisri
 
Continuum emission from within the plunging region of black hole discs
Continuum emission from within the plunging region of black hole discsContinuum emission from within the plunging region of black hole discs
Continuum emission from within the plunging region of black hole discs
Sérgio Sacani
 
Detectability of Solar Panels as a Technosignature
Detectability of Solar Panels as a TechnosignatureDetectability of Solar Panels as a Technosignature
Detectability of Solar Panels as a Technosignature
Sérgio Sacani
 

Recently uploaded (20)

Erythropoiesis- Dr.E. Muralinath-C Kalyan
Erythropoiesis- Dr.E. Muralinath-C KalyanErythropoiesis- Dr.E. Muralinath-C Kalyan
Erythropoiesis- Dr.E. Muralinath-C Kalyan
 
Molecular and Cellular Mechanism of Action of Hormones such as Growth Hormone...
Molecular and Cellular Mechanism of Action of Hormones such as Growth Hormone...Molecular and Cellular Mechanism of Action of Hormones such as Growth Hormone...
Molecular and Cellular Mechanism of Action of Hormones such as Growth Hormone...
 
GBSN - Microbiology (Unit 6) Human and Microbial interaction
GBSN - Microbiology (Unit 6) Human and Microbial interactionGBSN - Microbiology (Unit 6) Human and Microbial interaction
GBSN - Microbiology (Unit 6) Human and Microbial interaction
 
NuGOweek 2024 programme final FLYER short.pdf
NuGOweek 2024 programme final FLYER short.pdfNuGOweek 2024 programme final FLYER short.pdf
NuGOweek 2024 programme final FLYER short.pdf
 
SaffronCrocusGenomicsThessalonikiOnlineMay2024TalkOnline.pptx
SaffronCrocusGenomicsThessalonikiOnlineMay2024TalkOnline.pptxSaffronCrocusGenomicsThessalonikiOnlineMay2024TalkOnline.pptx
SaffronCrocusGenomicsThessalonikiOnlineMay2024TalkOnline.pptx
 
Soil and Water Conservation Engineering (SWCE) is a specialized field of stud...
Soil and Water Conservation Engineering (SWCE) is a specialized field of stud...Soil and Water Conservation Engineering (SWCE) is a specialized field of stud...
Soil and Water Conservation Engineering (SWCE) is a specialized field of stud...
 
NUMERICAL Proof Of TIme Electron Theory.
NUMERICAL Proof Of TIme Electron Theory.NUMERICAL Proof Of TIme Electron Theory.
NUMERICAL Proof Of TIme Electron Theory.
 
Tuberculosis (TB)-Notes.pdf microbiology notes
Tuberculosis (TB)-Notes.pdf microbiology notesTuberculosis (TB)-Notes.pdf microbiology notes
Tuberculosis (TB)-Notes.pdf microbiology notes
 
Continuum emission from within the plunging region of black hole discs
Continuum emission from within the plunging region of black hole discsContinuum emission from within the plunging region of black hole discs
Continuum emission from within the plunging region of black hole discs
 
Triploidy ...............................pptx
Triploidy ...............................pptxTriploidy ...............................pptx
Triploidy ...............................pptx
 
TEST BANK for Organic Chemistry 6th Edition.pdf
TEST BANK for Organic Chemistry 6th Edition.pdfTEST BANK for Organic Chemistry 6th Edition.pdf
TEST BANK for Organic Chemistry 6th Edition.pdf
 
-case selection and treatment planing.pptx
-case selection and treatment planing.pptx-case selection and treatment planing.pptx
-case selection and treatment planing.pptx
 
Factor Causing low production and physiology of mamary Gland
Factor Causing low production and physiology of mamary GlandFactor Causing low production and physiology of mamary Gland
Factor Causing low production and physiology of mamary Gland
 
SCHISTOSOMA HEAMATOBIUM life cycle .pdf
SCHISTOSOMA HEAMATOBIUM life cycle  .pdfSCHISTOSOMA HEAMATOBIUM life cycle  .pdf
SCHISTOSOMA HEAMATOBIUM life cycle .pdf
 
Manganese‐RichSandstonesasanIndicatorofAncientOxic LakeWaterConditionsinGale...
Manganese‐RichSandstonesasanIndicatorofAncientOxic  LakeWaterConditionsinGale...Manganese‐RichSandstonesasanIndicatorofAncientOxic  LakeWaterConditionsinGale...
Manganese‐RichSandstonesasanIndicatorofAncientOxic LakeWaterConditionsinGale...
 
IISc Bangalore M.E./M.Tech. courses and fees 2024
IISc Bangalore M.E./M.Tech. courses and fees 2024IISc Bangalore M.E./M.Tech. courses and fees 2024
IISc Bangalore M.E./M.Tech. courses and fees 2024
 
ERTHROPOIESIS: Dr. E. Muralinath & R. Gnana Lahari
ERTHROPOIESIS: Dr. E. Muralinath & R. Gnana LahariERTHROPOIESIS: Dr. E. Muralinath & R. Gnana Lahari
ERTHROPOIESIS: Dr. E. Muralinath & R. Gnana Lahari
 
B lymphocytes, Receptors, Maturation and Activation
B lymphocytes, Receptors, Maturation and ActivationB lymphocytes, Receptors, Maturation and Activation
B lymphocytes, Receptors, Maturation and Activation
 
The Scientific names of some important families of Industrial plants .pdf
The Scientific names of some important families of Industrial plants .pdfThe Scientific names of some important families of Industrial plants .pdf
The Scientific names of some important families of Industrial plants .pdf
 
Detectability of Solar Panels as a Technosignature
Detectability of Solar Panels as a TechnosignatureDetectability of Solar Panels as a Technosignature
Detectability of Solar Panels as a Technosignature
 

Featured

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

Featured (20)

Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 

02 Introduction to probability ノート

  • 1. Computer vision: models, learning and inference Chapter 2 Introduction to probability Please send errata to s.prince@cs.ucl.ac.uk
  • 2. Random variables • A random variable x denotes a quantity that is uncertain • May be result of experiment (flipping a coin) or a real world measurements (measuring temperature) • If observe several instances of x we get different values • Some values occur more than others and this information is captured by a probability distribution 2Computer vision: models, learning and inference. ©2011 Simon J.D. Prince TAKE '¥±K¥k
  • 3. Discrete Random Variables 3Computer vision: models, learning and inference. ©2011 Simon J.D. Prince tf.az#AkTak9zTf ER
  • 4. Continuous Random Variable 4Computer vision: models, learning and inference. ©2011 Simon J.D. Prince ELIE Fifa If Ek
  • 5. Joint Probability • Consider two random variables x and y • If we observe multiple paired instances, then some combinations of outcomes are more likely than others • This is captured in the joint probability distribution • Written as Pr(x,y) • Can read Pr(x,y) as “probability of x and y” 5Computer vision: models, learning and inference. ©2011 Simon J.D. Prince TH # ¥ BHI 'T
  • 6. Joint Probability 6Computer vision: models, learning and inference. ©2011 Simon J.D. Prince Knight &Ef¥Me tapas Apk like teak EL Tak EE like The tggqttpkh.be Heifetz ¥pHz4akKI
  • 7. Marginalization We can recover probability distribution of any variable in a joint distribution by integrating (or summing) over the other variables 7Computer vision: models, learning and inference. ©2011 Simon J.D. Prince Eh Ela : ( I I I I I I l a a At EG ' Fe CERE 9¥88 ) E ti K 's k R . ! X E An C , L 2 ' EEE Ffa FE it FEE B ! To 3 . Is a 17k¥ G ' if 2- ' it . f a- IEEE IKER I If a za FEE Be c 2 , K 2 ME He c E 2 I a Y I A " ER y ' 7 3 EPzE¥ E TE 2 IT . !
  • 8. Marginalization We can recover probability distribution of any variable in a joint distribution by integrating (or summing) over the other variables 8Computer vision: models, learning and inference. ©2011 Simon J.D. Prince tfafzFawkes t.BE is FE. & a Z Ek 2 . • - - - - - - - - - - - - - - - - .
  • 9. Marginalization We can recover probability distribution of any variable in a joint distribution by integrating (or summing) over the other variables 9Computer vision: models, learning and inference. ©2011 Simon J.D. Prince M =be;÷¥÷:÷¥*÷¥:::¥¥÷÷÷÷÷÷÷ . . I 9 " HEGE EE ka 2. FERta
  • 10. Marginalization We can recover probability distribution of any variable in a joint distribution by integrating (or summing) over the other variables Works in higher dimensions as well – leaves joint distribution between whatever variables are left 10Computer vision: models, learning and inference. ©2011 Simon J.D. Prince 77 ok K C 77 EIH ME IT TG E As fZe . Ke 8 a his a¥ 8 top Z fi H 3 k on , R2 I Z Aztec , TashI TakaE a w z - K E. ER . KLEEATE n Za ' FER'S -53 .
  • 11. Conditional Probability • Conditional probability of x given that y=y1 is relative propensity of variable x to take different outcomes given that y is fixed to be equal to y1. • Written as Pr(x|y=y1) 11 Computer vision: models, learning and inference. ©2011 Simon J.D. Prince Ff 44 He E EThe tf y ee f , k EHEEL k ZE . 7 I Y I a- - F s 2- Tn 32€ a ok a KkkEE 8 top ↳ - L . ¥KEE E FF , 2 I I E " IT 2- it Fife FFS Fp u is z taken THAT Y G y g q . . . 22 e " 22 5 . life II I TM a KEKE if . E 2 *Ep If 9 22 I e - - A 3 a " . = th 2- I H 's 22 u 5 'so U is . To h = s KERA FE 2 z EEE's c E ZE k Ia Etfd " I e- A 3 F 's a IE Bae EM c I 3 . u F- A " , 2 * in e ' Eai 'm 't → I c = 22 3 a THE 's T2 " o 42 a no - I " Fi ' a 5 . EREH 3 I FER To 2¥ By a " To 3 ,
  • 12. Conditional Probability • Conditional probability can be extracted from joint probability • Extract appropriate slice and normalize 12Computer vision: models, learning and inference. ©2011 Simon J.D. Prince g EST THE Fi ' it E EH Y E - - T e Be t a = k Fi ' H . you . y * a 2€ a g a EA a 5¥ ↳ ¥ Eaglets 3¥ ! f a - - ft eh 's In:&, ' Ian . hEs u EAin . C I a BIKE HE et 4¥. 8 to 3 2 I iz it ? ¥ f- sa k EE EE E Etty 4h c E 's FE EH n ME I F The Za Azul , 2 , EE EE TE h¥ a FER A 6 " I k A 3 F 7 iz I ER he t 3 La FE to " In 3
  • 13. Conditional Probability • More usually written in compact form • Can be re-arranged to give 13Computer vision: models, learning and inference. ©2011 Simon J.D. Prince €. :*"¥⇒÷÷:* . ¥**±⇒=÷¥÷÷÷ -- - EffectED of M¥715.5
  • 14. Conditional Probability • This idea can be extended to more than two variables 14Computer vision: models, learning and inference. ©2011 Simon J.D. Prince - Z a I I 55 Fp - YEAHHTT 5 R F- FA I 8 Fp - - - K n y a Z I Ff htt ht IT 5 RE EH E 5 Ep
  • 15. Bayes’ Rule From before: Combining : Re- arranging: 15Computer vision: models, learning and inference. ©2011 Simon J.D. Prince Eff4 Ft I B Fp a " An - a 32 . no a a . . * . . g a - 3 . A ' h K ' a Be EBE THE¥ EEE If it K2 " ¥44 ft H 2 E L 2 . EH4 tf it 2 E A E . t fi ' a 5 Eg § a Fet 3 .
  • 16. Bayes’ Rule Terminology Posterior – what we know about y after seeing x Prior – what we know about y before seeing x Likelihood – propensity for observing a certain value of x given a certain value of y Evidence –a constant to ensure that the left hand side is a valid distribution 16Computer vision: models, learning and inference. ©2011 Simon J.D. Prince fi Fk ( ' ¥HffEEeEz¥) * ' HER ' kit " k¥-7424 . . z¥¥, § THE 'a5kE2E9ka¥H #Tt ( ¥ ¥, ↳q¥ it ← 5Th ) -iFex¥¥iETT{} = ¥14184 -344784C ¥1467 BEGET IS # HIER 3-kkn.tk#k2HBeFtK-3kcTiGczOk . (Ef 4564k¥ ) 737×4 KEEN 3913449 Kritz By 2- I 3 .
  • 17. Independence • If two variables x and y are independent then variable x tells us nothing about variable y (and vice-versa) 17Computer vision: models, learning and inference. ©2011 Simon J.D. Prince HEE ← ya " x a EEE ¥4 - a ¥4 94dg z ELK a . IT a 4¥ IKE FEE 34 EINE , a e f it f)eh I 2 " In 3 U ' ' so FEE Ff c " . Y $ " Y , a z E 't ) :*. :*'s. ¥: " " ⇒ y it iceI'M ' Fatih Et ¥ EH - . .
  • 18. Independence • If two variables x and y are independent then variable x tells us nothing about variable y (and vice-versa) 18Computer vision: models, learning and inference. ©2011 Simon J.D. Prince ¥4993971 a FBA ' E E FAL ' ' .
  • 19. Independence • When variables are independent, the joint factorizes into a product of the marginals: 19Computer vision: models, learning and inference. ©2011 Simon J.D. Prince - Ah I a z I or L in Ffa FR e I ¥ EI en D - s . K Fi ' I a ERK EE - a Ft v . HE . 2 ARE a GEEK n A ② ¥ To Ep is q th z " k EEE 'T a ftp.t ' Eat 3 .
  • 20. Expectation Expectation tell us the expected or average value of some function f [x] taking into account the distribution of x Definition: 20Computer vision: models, learning and inference. ©2011 Simon J.D. Prince Eta 4¥ HE a a Tropez It B FT E % C 2 . FIFE K f EX ] a K IF A 7 A . I 2 u it THE ET I th 2 f TE E fi k 3 . um K K a ' 4h 2 C 3 . d to " Totalk Faklike n HIPFa x g ETE If ri EI H It IT c K f ex , 2 ' ItE. & a E ER 2 . a * KLEENE a Eka Es a AFF to
  • 21. Expectation Expectation tell us the expected or average value of some function f [x] taking into account the distribution of x Definition in two dimensions: 21Computer vision: models, learning and inference. ©2011 Simon J.D. Prince 2 s KK a -438 Fr . x e f n THE¥ Eth EE I ' Fs H ht i J c Te f Lx . g ] E = EE EEN, . E Fil . = a TH it K E I E FLEE ftp. ~ 7 LE Y V
  • 22. Expectation: Common Cases 22Computer vision: models, learning and inference. ©2011 Simon J.D. Prince AME 's FIG EEE . y at 'E9 E - tst KEG Yaba " FFF # Yakka £ch¥fhk3 . an FIFE 3k E - fit BEAK EEFE FIFE IEIFT.tn#aEEa2ct22iz . k£4123 ¥B¥A
  • 23. Expectation: Rules Rule 1: Expected value of a constant is the constant 23Computer vision: models, learning and inference. ©2011 Simon J.D. Prince Reiko Kk a Hai EE the es k Za E a .
  • 24. Expectation: Rules Rule 2: Expected value of constant times function is constant times expected value of function 24Computer vision: models, learning and inference. ©2011 Simon J.D. Prince k f = = a k x k . 2 . ItEe - naw IFF Sos II EI K FEE 47 E ' ' a - 's . FEEL k He E C 2 E IF o E " K S 7 t E I 2 .
  • 25. Expectation: Rules Rule 3: Expectation of sum of functions is sum of expectation of functions 25Computer vision: models, learning and inference. ©2011 Simon J.D. Prince As f- He FEND a FREE H FEE ft E - a - s .
  • 26. Expectation: Rules Rule 4: Expectation of product of functions in variables x and y is product of expectations of functions if x and y are independent 26Computer vision: models, learning and inference. ©2011 Simon J.D. Prince He 8 a " Heh EHF Box Es a 4 = a fly a Bfa 43 .
  • 27. Conclusions 27Computer vision: models, learning and inference. ©2011 Simon J.D. Prince • Rules of probability are compact and simple • Concepts of marginalization, joint and conditional probability, Bayes rule and expectation underpin all of the models in this book • One remaining concept – conditional expectation – discussed later ¥2 If RFI H a U L , D ' ' I 93 a fit IT 3 I 2 , - Eff4 tf E FEE 4¥ The et KK 2 . 43 .