                              Learning Mixtures of Experts with EM: A Mirror Descent Perspective



in high SNR scenarios. To validate our results further, we

                                                                                 Table 1. Performance for single Logistic Expert

perform a paired t-test (Ross & Willson, 2018). For EM and

Gradient EM compared to GD, we obtain a T-statistic ≥ 22                                          Accuracy       Random Invert

indicating that the difference in final accuracy is statistically             Single Expert        83.2%              No

significant (p-value ∼ 0.000).                                                Single Expert        10.2%             Yes

Validation Experiment on Fashion MNIST. For the small

scale proof of concept experiment on Fashion MNIST (Xiao                        Table 2. Performance for 2-Component MoLogE

et al., 2017), we alter the dataset so as to simulate a mixture

of 2 Logistic Experts. To do so, we perform an inversion                                             Accuracy Cross Entropy

transformation on the images at random with probability 12 .                 EM                       78.5%       0.827

Effectively, the transformation inverts the images from a                    Gradient EM              66.0%        1.29

white article of clothing on a black background to a black                   Gradient Descent         62.4%        1.30

article of clothing on a white background. As shown in Table

1, the single expert on the original Fashion MNIST dataset

reaches an accuracy of 83.2% on the test set. Meanwhile,

the single expert cannot achieve better than an accuracy of

10.2% on the altered dataset. This suggests a 2-component

MoLogE is appropriate for fitting the altered dataset, so long

as the ground truth partitioning is linear in image space.

The 2-component MoLogE to be trained consists of one

Linear gating layer of dimension 2 × 28 × 28, and 2 logistic                           (a)                              (b)

experts of dimension 10 × 28 × 28 each. We randomly

                                                                        Figure 3. Test accuracy and objective function, n1 n   i=1 1yˆi =yi

                                                                                                                            P

initialize each linear layer to be unit norm and execute the

algorithms on the same datasets and with the same initial-              and L(θ t ) in 3a and 3b, respectively, averaged over 25 instances

izations. For Gradient EM, the only additional code needed              for a 2-component MoLogE train on Random Invert FMNIST.

over GD is to define the EM Loss function appropriately,

and then perform a Gradient Step on the Gating parameters               7. Conclusion

and the Expert parameters separately as describe in Algo-

rithm 2. For EM, for each iteration, we perform several                 In this paper, we theoretically addressed the problem of

gradient steps in an inner loop to approximately recover the            Mixtures of Experts (MoE) with the use of the EM algo-

solutions to the sub-problems described in (9). We report               rithm. We first showed that the EM update for MoE could

our findings for the full-batch iteration of the respective             be interpreted as a projected Mirror Descent step on the

algorithms in Table 2 and Figure 3.                                     log-likelihood with a unit step size and a KL divergence

                                                                        regularizer, extending the result of (Kunstner et al., 2021)

In Table 2, we report the respective final test accuracy and

                                                                        beyond complete data distribution belonging to an expo-

cross-entropy loss values after 100 iterations of EM, Gradi-

                                                                        nential family. Building on this, we characterized different

ent EM and GD for fitting a 2-component MoLogE on the

                                                                        convergence rates for EM in this setting under various as-

altered Fashion MNIST dataset, averaged over 25 instances.

                                                                        sumptions about the log-likelihood function and specified

We see that EM boasts a much improved final test accuracy

                                                                        when these assumptions held. Lastly, we empirically ob-

that nearly recovers the single expert accuracy on the origi-

                                                                        served that EM can outperform gradient descent in both

nal unaltered Fashion MNIST dataset of 79.2%. Meanwhile,

                                                                        convergence rate and final performance.

Gradient EM also registers an improvement over GD. In

Figure 3, we report the progress made on the accuracy and

objective function for the test set over the 100 iterations, av-

eraged over 25 instances. As was observed in our synthetic

experiment, EM takes considerably less iterations to fit the

mixture than both Gradient EM and GD, where the former

also takes considerably less time to fit the mixture than GD.

To validate our results further, we perform a paired t-test.

For EM and Gradient EM compared to GD, we obtain a T-

statistic ≥ 17 indicating that the difference in final accuracy

is statistically significant (p-value ∼ 0.000).







                                                                    9

