Motivating Gaussian Example : Dataset Iris Model Grapical bn - - PowerPoint PPT Presentation

motivating
SMART_READER_LITE
LIVE PREVIEW

Motivating Gaussian Example : Dataset Iris Model Grapical bn - - PowerPoint PPT Presentation

Mixture Model Motivating Gaussian Example : Dataset Iris Model Grapical bn O 7- a he Model Generative , In pyu ,E ) Mu - . ,hk ) Discrete ( M 2- un , . , . ynltn-kn.lt/orm4uh,Iu ) Models Motivating Hidden Mahar Example :


slide-1
SLIDE 1 Motivating Example : Gaussian Mixture Model Grapical Model Iris Dataset bn O 7- a he Generative Model Mu , In
  • pyu ,E )
2- un Discrete ( M , , . . . ,hk ) ynltn-kn.lt/orm4uh,Iu)
slide-2
SLIDE 2

Motivating

Example : Hidden Mahar Models

¢€yT

yi Yt & 7 , Za . z , t Goal : Posterior an Parameters £ t pi O ly ) = ply 10 ) p I O ) t q

y

Can do via

BPG

intractable PCYIO ) = Idt pay , 7101 ply ) =/

DO

pcyiolplo )
slide-3
SLIDE 3 Monte Carlo Estimation : Setup Assume : We have some probabilistic graphical model with unnormalized density x :{ 7,03 A y ( x ) = pay , x ) = pcyix ) pcx ) = y C x ) Goal : Calculate expectation w.at . normalized density 17 Cx ) :-. ycx ) / 2- =

=)

2-

/dx

JK ) = = F :
  • Enix
, [ fix ) :
  • _

fdxrilxiflxl

slide-4
SLIDE 4 Monte Carlo Estimators Idea : Replace integrals with sequences
  • f
samples

Es

÷

Ig ??

, fcxs ) X '
  • Mix
) s
  • I
. . . S Properties : Monte Carlo estimators are 1 . Unbiased : El Es ] = F 2 . Consistent : lim EKES
  • Ft
' ] =
  • S
as
slide-5
SLIDE 5 Monte Carlo Estimators Unbiased ness :

Efts

I = Ef 's I f Ks ) ) = = I
slide-6
SLIDE 6 Monte Carlo Estimators Consistency ; Law
  • f
Large Numbers

EECES

  • FI
]= El

& fix

' ))
  • FT I
= # If 's c

is

= YEH It's.EE#Ef I = 's E )

lsima.IT?lEs-F53=hjzsIEIlfCxt-F5I=o

slide-7
SLIDE 7 Importance Sampling Problem : Often it is not possible to directly sample Xr next from the target Solution : Generate samples Xsnqcx ) from a proposal distribution that is similar to Mk ) EIIHX) ) = fdx next fix , MCM gcxi = fdx

"X

iss

X S
  • i
slide-8
SLIDE 8

Self

  • normalized

Importance

Sampling Problem : In
  • rder
to calculate importance weights wcx ) : = Thx ) 19cm we need to evaluate the normalized density 121×1 = text IF , but normally we can 't calculate 2- :-. fdxycxl Solution : Normalize using a Monte Carlo estimate 2- = 7 fax next = = F = ¥ fdxycxifki =
slide-9
SLIDE 9

Self

  • normalized

Importance

Sampling 17kt =p # IZ

Ws

is 8 ( X ' ) Unnennalized Importune Weight paly )
  • Phil
, qcxs ) Es ' &

Wfld

) I s :-. = S Is s= , s WS =

€ Ews

' f Ks I

Ws

:-. S '
  • s
=2W

flx

' ) 5--1
slide-10
SLIDE 10

Self

  • normalized

Importance

Sampling Es ÷

s.es?Ewsfk7wi--rgYyY,Es:-s?ws

Question

: Is Es unbiased ? ( i.e . EEE ' ] ? F ) Elf 's w ' f Ks ) ) = = ?

El ¥1

. E

w1=*w

, = 's Jensen 's inequality Ely . K ) ) > cel EKD ) when y convex
slide-11
SLIDE 11 What Choice
  • f
Proposal is Optimal ? ^ 91×1 a Jk ) fix )

MEhr

Variance
  • f
Estimator Ell 'Y¥ fix )
  • FI)
  • EH

}

, flat )
  • F
'

=/

dxgcxi

"

E=

(lax

mail.nl/IF

'
slide-12
SLIDE 12

Default

choice

for

proposal : Likelihood Weighting Assume Bayes Net : j 1×7 = ply , Xi = pcylxlpcxl 2- = fdxpiy.tl
  • ply )
Set proposal to prior

[

I not a random Variable ) qcx ) = pcxl Importance Weights : Likelihood Is =

& WI

f Ks ) us = = = 5--1 . § .ws's

pandan

ra ,
slide-13
SLIDE 13 Running Example : Gaussian Mixture Model . Grapical Model Iris Dataset Yn O 7- a he Generative Model Mu , fun pyu ,E ) 2- un Discrete ( M , , . . . ,hk ) ynltn-kn.lt/orm4uh,Iu)
slide-14
SLIDE 14

Motivating

Problem : Hidden Markov Models

§→€→

yi Yt & 7 , Ze . z , t Goal : Posterior an Parameters It pc O ly , =

fat

PCO 't ' Y ) a Guess "

futon

prior Will likelihood weighty wash ? " Cheah " using likelihood

I

a On PCO) 2- ~ pet , it 19 ) Ws pcyi.it/7i:t,T )
slide-15
SLIDE 15 Manhov Chain Monte Carlo 5
  • 1
Idea : Use previous sample x to propose the next sample xs Maher Chain : A sequence
  • f
random variables Xl , . . . ,X5 is a ( discrete
  • time
) Markov chain when xs 1×5 " DX ! ... ,×s " 2 Moran property p ( xslx ' is ' ' ) = p ( Xsixs " ) A Mmwov Chain is homogenous When same trans p(Xs=×s 1×5 "=×s . ' ) = p( X '=xslX=xs " ) dtst for each s
slide-16
SLIDE 16 Manha Chain Monte Carlo Convergence : A Manha chain converges to a target density 17 ( x ) when

lying

.

p(Xs=x

) = n(X=× ) 2

*¥*y¥¥±

,

III :

"II÷u

. in which X=x is visited with " frequency " h(X=x ) J
slide-17
SLIDE 17 Markov Chain Monte Carlo Detailed Balance : A homogenous Markov chain satisfies detailed balance when MCX ) pix ' Ix ) = Mix ' ) plxcx 't Implication i pcx ' 1×1 leaves Mix ) invariant 17 C x ) =

/dx

' Mlxspcx ' IX ) . =

fdx

' MCX ' I pcxlx ' I If you start with a sample x ' n next and then sample XIX ' ~ pl XIX ' ) this xn Mex )
slide-18
SLIDE 18 Metropolis
  • Hastings
Idea : Starting from the current sample xs generate a proposal x ' n qcxixs ) and accept xst ' = x ' with probability . 17 ( x ' I 9 ( XIX ' ) a = mm in

( I

,

mix

, qcx ' Ix ) ) with probability C I
  • a
) reject the proposal and retain the previous sample xs "=xs
slide-19
SLIDE 19 Metropolis
  • Hastings
Idea : Starting from the current sample xs generate a proposal × ' ~ qcxixs ) and accept xst '=x ' with probability . M ( X ' ) q( XIX ' ) a =mmin

( l

i n ( × ) qkllx ) ) with probability ( l
  • d
) reject the proposal and retain the previous sample xs "=xs Exercise : Show that the Markov chain x ' . . . xs satisfies detailed balance
slide-20
SLIDE 20 etropolis
  • Hastings
: Detailed Balance Detailed Balance : 17 C X ) p I X ' Ix ) = Mix ' ) plxcx 't Metropolis
  • Hastings
: Define pcxiixl = ( I
  • d)
8×61+09 C x' Ix )
  • =

minfl.MY?,9gfIYY-j)pCx'lxlnCx

) = =
slide-21
SLIDE 21 etropolis
  • Hastings
: Unrormalired Densities Nice property : Can calculate acceptance prob from unhormaliced densities jcx ' ) and ✓ C x ) . 17 ( X ' I 9 ( XIX ' ) a = mm

in

( I

, n , × , qcx ' Ix ) ) . j ( x ' I 9 C XIX ' ) =

main

( I

s ya , qcx ' Ix ) ) ply , X ' 7 gcxlx ' ) y Cx ) = ply , X ) =

rain

( I

, pay ,

xyqcx

' Ix ) )
slide-22
SLIDE 22 Metropolis
  • Hastings
: Choosing proposals Independent
  • Mtt
: Sample proposers from pretor a ( X ' IX ) = pal ) Independent from previous sample ply , x ' ) g ( XIX ' ) a =

rain

( I

i pay , qcx ' Ix ) ) = mm

in

( I

,

)

=

mind

,
  • )
Really simple , but low acceptance prob
slide-23
SLIDE 23 large ft Metropolis
  • Hastings
: Choosing proposals

y

Continuous variables : Gaussian " ÷÷§\× .
  • f
  • off
qcx ' IX ) = Norm ( X ' ; X , 82 ) small
  • r
' Trade
  • ff
fur proposal variance
  • 82
too small ; good acceptance prob A , but high correlation between samples
  • 82
too large : less correlation , but lower acceptance prob A Rule
  • f
thumb , tune
  • f
' to make 9 I 0.234
slide-24
SLIDE 24 Gibbs

Sampling

( Next Lecture ) Idea : Propose 1 variable at a time , holding
  • ther
variables constant y C x ) = ply Ix , ,Xa ) pix . , Xz )
  • x. in
xi
  • Acceptance
Ratio : Car accept with prob I = A = min ( I ,

)

= I
slide-25
SLIDE 25 Gibbs Sampling : Gaussian Mixture

(

Next Lecture ) Grapical Model Gibbs Sampler Steps 2- n ly , µ , E r pcznly.lu , E ) Y " µ , Ely , 't ~ pyu.Ely.tl 2- a Conditional Distributions : 2- n he pctn-hlyn.pe , E ) = plyn.7n-h.ME) Generative Model

pcyn.IQ/uu,Iunpc/u,E

) = p ' Yul 2- n=h , µ , E) pC7n=h ) 2- n
  • Discretely
, . . . .tk )

?

pcynl Zu
  • l, µ
, El pl7n=l ) ynlZn=k~N0rm( Mish ) Exploit and . ind . 2- nItm-dnl9.ME
slide-26
SLIDE 26