Solved – Is the EM-algorithm the same thing that variational inference in LDA

I am new in the probabilistic topic modeling, and I need to understand deeply the Latent Dirichlet Allocation (LDA) process.

I understand that what is the inference process in LDA, and there are 2 "types" of inference: probabilistic methods (like the Gibbs sampling) and deterministic ones.

In the deterministic type, some papers talk about Expectation Maximization algorithm and others talk about something called Variational Inference.

So my questions are

  1. Are those terms or concepts same?
  2. How EM algorithm works in LDA?

First, I notice that the answer given by AdamO discusses linear discriminant analysis. Since the question mentions topic modeling, I believe it is about latent Dirichlet allocation instead.

Now to answer the question:

  1. EM and variational inference are not the same. In EM, you maximize the likelihood or posterior wrt. the parameters with the hidden variables marginalized. In VI, the parameters are also regarded as hidden variables, and you want to approximate the posterior of the hidden variables by a variational distribution. You may think of EM as a special case of mean-field VI where the variational distributions are assumed to be point estimations.

  2. To apply EM to LDA: In the E-step, you fix $theta$ (the topic distribution of the document) and $phi$ (the word distribution under a topic) and compute the distribution $q(z)$ of $z$ (the topic assignment of each word). In the M-step, you update $theta$ and $phi$ to optimize the expected log likelihood, where the expectation is taken based on $q(z)$.

Similar Posts:

Rate this post

Leave a Comment