Probability and Informa0on 270C Defini0on of Probability - - PowerPoint PPT Presentation
Probability and Informa0on 270C Defini0on of Probability - - PowerPoint PPT Presentation
Probability and Informa0on 270C Defini0on of Probability Experiment : toss a coin twice Sample space : possible outcomes of an experiment S = {HH,
Defini0on ¡of ¡Probability ¡
- Experiment: ¡toss ¡a ¡coin ¡twice ¡
- Sample ¡space: ¡possible ¡outcomes ¡of ¡an ¡experiment ¡
– S ¡= ¡{HH, ¡HT, ¡TH, ¡TT} ¡
- Event: ¡a ¡subset ¡of ¡possible ¡outcomes ¡
– A={HH}, ¡B={HT, ¡TH} ¡
- Probability ¡of ¡an ¡event ¡: ¡an ¡number ¡assigned ¡to ¡an ¡
event ¡Pr(A) ¡
– Axiom ¡1: ¡Pr(A) ¡≥ ¡0 ¡ – Axiom ¡2: ¡Pr(S) ¡= ¡1 ¡ – Axiom ¡3: ¡For ¡every ¡sequence ¡of ¡disjoint ¡events ¡ – Example: ¡Pr(A) ¡= ¡n(A)/N: ¡frequen0st ¡sta0s0cs ¡
Random ¡Variable ¡and ¡Distribu0on ¡
- A ¡random ¡variable ¡X ¡is ¡a ¡numerical ¡outcome ¡of ¡a ¡
random ¡experiment ¡
- The ¡distribu9on ¡of ¡a ¡random ¡variable ¡is ¡the ¡collec0on ¡
- f ¡possible ¡outcomes ¡along ¡with ¡their ¡probabili0es: ¡ ¡
– Discrete ¡case: ¡ – Con0nuous ¡case: ¡ ¡
Random ¡Variable: ¡Example ¡
- Let ¡S ¡be ¡the ¡set ¡of ¡all ¡sequences ¡of ¡three ¡rolls ¡of ¡a ¡
- die. ¡Let ¡X ¡be ¡the ¡sum ¡of ¡the ¡number ¡of ¡dots ¡on ¡the ¡
three ¡rolls. ¡
- What ¡are ¡the ¡possible ¡values ¡for ¡X? ¡
- Pr(X ¡= ¡5) ¡= ¡?, ¡Pr(X ¡= ¡10) ¡= ¡? ¡
Expecta0on ¡
- A ¡random ¡variable ¡X~Pr(X=x). ¡Then, ¡its ¡expecta0on ¡is ¡
¡ ¡ ¡
– In ¡an ¡empirical ¡sample, ¡x1, ¡x2,…, ¡xN, ¡ ¡
- Con0nuous ¡case: ¡
- ¡Expecta0on ¡of ¡sum ¡of ¡random ¡variables ¡
Expecta0on: ¡Example ¡
- Let ¡S ¡be ¡the ¡set ¡of ¡all ¡sequence ¡of ¡three ¡rolls ¡of ¡a ¡die. ¡
Let ¡X ¡be ¡the ¡sum ¡of ¡the ¡number ¡of ¡dots ¡on ¡the ¡three ¡
- rolls. ¡
- What ¡is ¡E(X)? ¡
- Let ¡S ¡be ¡the ¡set ¡of ¡all ¡sequence ¡of ¡three ¡rolls ¡of ¡a ¡die. ¡
Let ¡X ¡be ¡the ¡product ¡of ¡the ¡number ¡of ¡dots ¡on ¡the ¡ three ¡rolls. ¡
- What ¡is ¡E(X)? ¡
Variance ¡
- The ¡variance ¡of ¡a ¡random ¡variable ¡X ¡is ¡the ¡
expecta0on ¡of ¡(X-‑E[x])2 ¡: ¡
Bernoulli ¡Distribu0on ¡
- The ¡outcome ¡of ¡an ¡experiment ¡can ¡either ¡be ¡success ¡
(i.e., ¡1) ¡and ¡failure ¡(i.e., ¡0). ¡
- Pr(X=1) ¡= ¡p, ¡Pr(X=0) ¡= ¡1-‑p, ¡or ¡
- E[X] ¡= ¡p, ¡Var(X) ¡= ¡p(1-‑p) ¡
Binomial ¡Distribu0on ¡
- n ¡draws ¡of ¡a ¡Bernoulli ¡distribu0on ¡
– Xi~Bernoulli(p), ¡X=∑i=1
n ¡Xi, ¡X~Bin(p, ¡n) ¡
- Random ¡variable ¡X ¡stands ¡for ¡the ¡number ¡of ¡0mes ¡
that ¡experiments ¡are ¡successful. ¡
- E[X] ¡= ¡np, ¡Var(X) ¡= ¡np(1-‑p) ¡
Plots ¡of ¡Binomial ¡Distribu0on ¡
Poisson ¡Distribu0on ¡
- Coming ¡from ¡Binomial ¡distribu0on ¡
– Fix ¡the ¡expecta0on ¡λ=np ¡ – Let ¡the ¡number ¡of ¡trials ¡n→∞ ¡ A ¡Binomial ¡distribu0on ¡will ¡become ¡a ¡Poisson ¡distribu0on ¡
- E[X] ¡= ¡λ, ¡Var(X) ¡= ¡λ ¡
Plots ¡of ¡Poisson ¡Distribu0on ¡
Normal ¡(Gaussian) ¡Distribu0on ¡
- X~N(µ,σ) ¡
- E[X]= ¡µ, ¡Var(X)= ¡σ2 ¡
- If ¡X1~N(µ1,σ1) ¡and ¡X2~N(µ2,σ2), ¡X= ¡X1+ ¡X2 ¡? ¡
Joint ¡Probability ¡
- For ¡events ¡A ¡and ¡B, ¡joint ¡probability ¡Pr(AB) ¡
stands ¡for ¡the ¡probability ¡that ¡both ¡events ¡
- happen. ¡
- Example: ¡A={HH}, ¡B={HT, ¡TH}, ¡what ¡is ¡the ¡joint ¡
probability ¡Pr(AB)? ¡
Independence ¡
- Two ¡events ¡A ¡and ¡B ¡are ¡independent ¡in ¡case ¡
¡ ¡ ¡Pr(AB) ¡= ¡Pr(A)Pr(B) ¡
- A ¡set ¡of ¡events ¡{Ai} ¡is ¡independent ¡in ¡case ¡
- If ¡A ¡and ¡B ¡are ¡events ¡with ¡Pr(A) ¡> ¡0, ¡the ¡condi9onal ¡
probability ¡of ¡B ¡given ¡A ¡is ¡
Condi0oning ¡
Condi0onal ¡Independence ¡
- Event ¡A ¡and ¡B ¡are ¡condi9onally ¡independent ¡given ¡C ¡
in ¡case ¡ ¡ ¡ ¡Pr(AB|C)=Pr(A|C)Pr(B|C) ¡
- A ¡set ¡of ¡events ¡{Ai} ¡is ¡condi0onally ¡independent ¡given ¡
C ¡in ¡case ¡ ¡ ¡ ¡
- Given ¡two ¡events ¡A ¡and ¡B ¡and ¡suppose ¡that ¡Pr(A) ¡> ¡0. ¡Then ¡
- Example: ¡
Bayes’ ¡Rule ¡
Pr(W|R) R ¬R W 0.7 0.4 ¬W 0.3 0.6 R: ¡It ¡is ¡a ¡rainy ¡day ¡ W: ¡The ¡grass ¡is ¡wet ¡ Pr(R|W) ¡= ¡? ¡ Pr(R) ¡= ¡0.8 ¡
Bayes’ ¡Rule ¡
R ¬R W 0.7 0.4 ¬W 0.3 0.6
R: ¡It ¡rains ¡ W: ¡The ¡grass ¡is ¡wet ¡
R ¡ W ¡
Informa2on ¡ Pr(W|R) ¡ Inference ¡ Pr(R|W) ¡
Bayes’ ¡Rule ¡
R ¬R W 0.7 0.4 ¬W 0.3 0.6 R: ¡It ¡rains ¡ W: ¡The ¡grass ¡is ¡wet ¡ Hypothesis ¡H ¡ Evidence ¡E ¡
Informa2on: ¡Pr(E|H) ¡ Inference: ¡Pr(H|E) ¡
Prior ¡ Likelihood ¡ Posterior ¡
Measures ¡of ¡Complexity ¡
Entropy ¡and ¡Uncertainty ¡
Coding ¡length: ¡ Data ¡processing ¡inequality: ¡ Rela0ve ¡Entropy: ¡
K(x) is the length of a shortest program to compute x K(x|y) is the length of a shortest program to compute x given y as input K(x,y) is the length of a shortest program to compute the pair (x,y)
Calcula0ng ¡ MK− jpg =1− K NH rgb =1− 0.169 = 0.831
MK
MK− jpg
MK− png =1− 0.305 = 0.695
Example: ¡Mondrian-‑1 ¡
Mutual ¡Informa0on, ¡Joint ¡Entropy ¡& ¡ Condi0onal ¡Entropy ¡
Entropy ¡
- Entropy ¡(self-‑informa0on) ¡
– the ¡amount ¡of ¡informa-on ¡in ¡a ¡random ¡variable ¡ – average ¡uncertainty ¡of ¡a ¡random ¡variable ¡ – the ¡average ¡length ¡of ¡the ¡message ¡needed ¡to ¡transmit ¡an ¡
- utcome ¡of ¡that ¡variable ¡
– the ¡size ¡of ¡the ¡search ¡space ¡consis0ng ¡of ¡the ¡possible ¡ values ¡of ¡a ¡random ¡variable ¡and ¡its ¡associated ¡probabili0es ¡ – Proper0es ¡
- ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡( ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡: ¡providing ¡no ¡new ¡informa0on) ¡
- increases ¡with ¡message ¡length ¡
Entropy ¡ ¡-‑ ¡Example ¡
- Simplified ¡Language ¡
– leler ¡frequencies ¡ – per-‑leler ¡entropy ¡ – coding ¡
p ¡ ¡ ¡t ¡ ¡k ¡ ¡a ¡ ¡i ¡ ¡u ¡ 100 ¡ ¡00 ¡ ¡101 ¡ ¡01 ¡ ¡110 ¡ ¡111 ¡
30 ¡
Joint ¡Entropy ¡& ¡Condi0onal ¡Entropy ¡
- Joint ¡Entropy ¡
– the ¡amount ¡of ¡informa0on ¡needed ¡on ¡average ¡to ¡ specify ¡both ¡their ¡values ¡
- Condi0onal ¡Entropy ¡
how much extra information you still need to supply on average to communicate Y given that the other party knows X
31 ¡
Joint ¡Entropy ¡& ¡Condi0onal ¡Entropy ¡
- Chain ¡Rules ¡for ¡Entropy ¡
32 ¡
Joint ¡Entropy ¡& ¡Condi0onal ¡Entropy ¡
- ‑ ¡Example ¡
- Simplified ¡Language ¡Revisited ¡
– syllable ¡structure ¡
- all ¡words ¡consist ¡of ¡sequences ¡of ¡CV ¡syllables. ¡
- C: ¡consonant, ¡V: ¡vowel ¡
33 ¡
Joint ¡Entropy ¡& ¡Condi0onal ¡Entropy ¡
- Entropy ¡Rate ¡(per-‑word/per-‑leler ¡entropy) ¡
- Entropy ¡of ¡a ¡Block ¡
Mutual ¡Informa0on ¡
- Mutual ¡Informa0on ¡
– the ¡reduc0on ¡in ¡uncertainty ¡of ¡one ¡random ¡variable ¡due ¡to ¡knowing ¡ about ¡another ¡ – the ¡amount ¡of ¡informa0on ¡one ¡random ¡variable ¡contains ¡about ¡ another ¡ – measure ¡of ¡independence ¡
- ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡: ¡two ¡variables ¡are ¡independent ¡
- grows ¡according ¡to ¡... ¡
– the ¡degree ¡of ¡dependence ¡ – the ¡entropy ¡of ¡the ¡variables ¡
35 ¡
Mutual ¡Informa0on ¡
36 ¡
Mutual ¡Informa0on ¡
- Condi0onal ¡Mutual ¡Informa0on ¡
- Chain ¡Rule ¡
- Pointwise ¡Mutual ¡Informa0on ¡
37 ¡
Communica0on ¡Channel ¡
- The ¡Noisy ¡Channel ¡Model ¡
– Assump0on ¡
- the ¡output ¡of ¡the ¡channel ¡depends ¡probabilis0cally ¡on ¡
the ¡input ¡
– Channel ¡capacity ¡
Encoder Channel p(y|x) Decoder
Message from a finite alphabet Input to channel Output from channel Attempt to reconstruct message based
- n output
38 ¡
Decoding ¡
- The ¡Noisy ¡Channel ¡Model ¡
– decode ¡the ¡output ¡to ¡give ¡the ¡most ¡likely ¡input ¡
Noisy Channel Decoder : source model, : channel probability ¡
Informa0on ¡Dynamics ¡
Info-‑Rate ¡Model ¡
Aesthetic perception as a communication process:
Informa0on ¡that ¡influences ¡the ¡“cogni0ve ¡state” ¡of ¡the ¡informa0on ¡receiver
Slow brain appraisal Fast brain processing Self-supervision (emotions, etc.,…) Receiver y ¡
- Channel. ¡
Source x ¡
The information paradox: Discover more by listening more…. (you gain by learning, not get bored!) M ¡= ¡I(x,y)/H(x) ¡
Time ¡channel: ¡An0cipa0on ¡
- Entropy ¡& ¡Informa0on ¡
H(x) ¡ H(y) ¡ H(x,y) ¡ I(x,y) ¡ H(x|y) ¡ H(y|x) ¡ Receiver y ¡
- Channel. ¡
Source x ¡
- Communica0on ¡Channel ¡
y ¡– ¡past ¡experience, ¡what ¡you ¡heard ¡so ¡far ¡ x ¡– ¡new ¡material ¡ H(x) ¡– ¡uncertainty ¡about ¡x ¡ ¡ H(x|y) ¡– ¡uncertainty ¡about ¡x when ¡we ¡know ¡already y ¡ I(x,y) ¡– ¡how ¡much ¡the ¡past ¡tells ¡us ¡about ¡the ¡future ¡
ρ(X[1n]) = I(X1,X2,...Xn) − I(X1,X2,...Xn−1) = H(Xn) −[H(X1,X2,...Xn) − H(X1,X2,...Xn−1)] = H(Xn) − H(Xn | X1,...Xn−1)
Mul0-‑informa0on ¡
I(X1,X2,...Xn) = H(Xi) − H(
i=11 n
∑
X1,X2,...Xn)
Informa0on-‑rate ¡
X1 X2 Xn−1 Xn
… ¡ |-‑-‑-‑-‑-‑-‑-‑-‑-‑-‑-‑-‑-‑I(X[1 n])-‑-‑-‑-‑-‑-‑-‑-‑-‑-‑-‑-‑>| ¡ |-‑-‑-‑-‑-‑-‑-‑-‑I(X[1 n-1])-‑-‑-‑-‑-‑-‑-‑-‑-‑-‑>| ¡ IR ¡
Info-‑Rate ¡ Predic2ve ¡Info-‑Rate ¡
I(X,Z) = H(X) − H(X | Z)
Informa0on ¡in ¡the ¡present ¡observa0on ¡about ¡the ¡en0re ¡future ¡ Informa0on ¡in ¡the ¡en0re ¡past ¡about ¡the ¡present ¡observa0on ¡
Bifurcation points Mutual Information I(x(n+1),x(n)) Produces a chaotic time series
( 1) ( )(1 ( )) x n x n x n α + = −
( 4) α =
45 ¡
Markov ¡Process ¡
- ¡Markov ¡Property: ¡The ¡state ¡of ¡the ¡system ¡at ¡0me ¡t+1 ¡depends ¡only ¡on ¡the ¡state ¡of ¡
the ¡system ¡at ¡0me ¡t X1 X2 X3 X4 X5
Pr Xt +1 = xt +1 | X1Xt = x1xt
[ ] = Pr Xt +1 = xt +1 | Xt = xt [ ]
- ¡Sta0onary ¡Assump0on: ¡Transi0on ¡probabili0es ¡are ¡independent ¡of ¡0me ¡(t) ¡
Bounded ¡memory ¡transi0on ¡model ¡
46 ¡
Weather: ¡
- ¡raining ¡today
¡ ¡ ¡40% ¡rain ¡tomorrow ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡60% ¡no ¡rain ¡tomorrow ¡ ¡ ¡
- ¡not ¡raining ¡today
¡ ¡ ¡20% ¡rain ¡tomorrow ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡80% ¡no ¡rain ¡tomorrow rain no rain
0.6 0.4 0.8 0.2 Stochas0c ¡FSM: ¡
Markov ¡Process ¡
47 ¡
Weather: ¡
- ¡raining ¡today
¡ ¡ ¡40% ¡rain ¡tomorrow ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡60% ¡no ¡rain ¡tomorrow ¡ ¡ ¡
- ¡not ¡raining ¡today
¡ ¡ ¡20% ¡rain ¡tomorrow ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡80% ¡no ¡rain ¡tomorrow
- ¡Stochas0c ¡matrix: ¡
Rows ¡sum ¡up ¡to ¡1 ¡
- ¡Double ¡stochas0c ¡matrix: ¡
Rows ¡and ¡columns ¡sum ¡up ¡to ¡1 ¡ The ¡transi0on ¡matrix: ¡
Markov ¡Process ¡
=0 ¡
Markov ¡process ¡
Because ¡of ¡Markov ¡property ¡all ¡informa0on ¡between ¡ Past ¡and ¡Future ¡condi0onal ¡on ¡the ¡Present ¡= 0 ¡
PI = I(past, future) = I(past, present) = I(X0,X1) = IR
H(St) = H(π a) = π i
a log(π i a) i=1 N
∑
H(St +1 | St) = Hr(a) = − π i
a i=1 N
∑
a ji log(a ji)
j=1 N
∑
IR = H(π a) − Hr(a) PIR = Hr(a2) − Hr(a) Stationary distribution ¡
Example: ¡
Transition matrix a
Discussion: ¡
- ¡Not ¡interes0ng ¡for ¡us ¡
- ¡Uncertainty ¡about ¡the ¡beginning ¡
- ¡Small ¡devia0ons ¡are ¡highly ¡surprising ¡
- ¡This ¡might ¡be ¡the ¡most ¡“interes0ng” ¡sequence ¡for ¡a ¡listener ¡who ¡has ¡a ¡
single ¡state ¡memory ¡ ¡
- ¡Such ¡listener ¡with ¡memory ¡blackout ¡will ¡view ¡the ¡sequence ¡as ¡noise ¡
again ¡
- ¡Fun ¡in ¡slots? ¡
A ¡Markov ¡circle: ¡ 1 ¡2 ¡3 ¡4 ¡0 ¡1 ¡2 ¡3 ¡4 ¡0 ¡1 ¡1 ¡2 ¡3 ¡ 4 ¡ 3 ¡ 2 ¡ 1 ¡ 0 ¡ H=log2(5), ¡Hr(a)~Hr(a2)~0, ¡Max ¡IR, ¡PIR~0 ¡