1
$\begingroup$

When using the EM algorithm in Gaussian Mixture Models (GMM), in the E-step, we take each x set in the training dataset to calculate and update the "weight" and parameters of each Gaussian distribution of the clusters (M-step). I have read that we do this until it converges. I am a little confused here. Does that mean it loops through the whole training dataset X every time in "one step" of the EM algorithm? Or is "one step" corresponding to calculating ONE particular x set in the whole dataset and using it to update the parameters and weights of each distribution?

To make the question more clear, does each "step" in the EM algorithm in GMMs involve the whole training dataset X or does each step mean one particular x set in the training set, and we loop over the dataset one at a time to improve one at a time?

Any help will be appreciated! Thanks.

$\endgroup$
1
$\begingroup$

At the beginning of the algorithm, you are taking an initial guess for the relevant parameters. Then in each iteration, in the E-step you are computing the responsibilities for all the given datapoints and in the M-step you are computing the weighted means and variances.

Since you are clustering the datapoints there is not training or test set. You just want to divide your dataset to two (or more) clusters.

| improve this answer | |
$\endgroup$
  • $\begingroup$ I see. Just to make sure, so technically after initializing some parameters, we will go through the whole dataset X in every iteration to update and calculate the responsibilities and parameters. We stop when it converges, meaning it has reached the optimized parameters that describe the dataset. Correct? $\endgroup$ – YCCCCC Sep 17 '19 at 21:56
  • 1
    $\begingroup$ Yes. If you cannot meet the stopping criterion, you may define a maximum number of iterations. $\endgroup$ – Christos Karatsalos Sep 18 '19 at 22:04
  • $\begingroup$ Thanks so much for the help! $\endgroup$ – YCCCCC Sep 20 '19 at 17:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.