L11 TopicModels 2
L11 TopicModels 2
Topic Models
Yangqiu Song
2 Topic Models
2 Topic Models
P(x) = P ∗ (x)/Z
Example
Example
R
X P ∗ (x(r ) )
Φ̂ = φ(x(r ) )
r =1
ZR
2 Topic Models
2 Topic Models
2 Topic Models
P ∗ (x 0 )Q(x (t) |x 0 )
a=
P ∗ (x (t) )Q(x 0 |x (t) )
as required
Metropolis method actually samples from the required distribution
P(x)
Yangqiu Song (HKUST) COMP5222/MATH5471 October 25, 2019 31 / 37
Sampling Effects
1
21 x ∈ {0, 1, . . . , 20}
P(x) =
0 otherwise
x0 = x ± 1
1
0 2
Q(x |x) =
0 otherwise
2 Topic Models