                                  MixMin: Finding Data Mixtures via Convex Minimization



performed significantly better, suggesting the proxy models          Acknowledgements

were too noisy to lead to good ensembles. Specifically,

this implies the proxy models were far from Bayes optimal,           Resources used in preparing this research were provided in

as the ensemble would have then also been near Bayes                 part by the Province of Ontario, the Government of Canada

optimal. The fact we were able to improve over the natural           through CIFAR, and companies sponsoring the Vector Insti-

distribution suggests MixMin did not need strong proxy               tute. We acknowledge the support of the Natural Sciences

models for these sources and targets.                                and Engineering Research Council of Canada (NSERC),

                                                                     RGPIN-2021-03445. Anvith Thudi is supported by a Vanier

                                                                     Fellowship from NSERC.

MixMin highlighted data sources with similar endpoint

measure All the target assays tested cytotoxicity, and the           Evianne Rovers acknowledges support given through the

majority of the top 4 data sources MixMin found for each             Matthieu Schapira lab at the University of Toronto who re-

assay also tested cytotoxicity (Table 2 in Appendix B). More         ceives funding from NSERC [Grant RGPIN-2019-04416],

specific protein inhibition assays were also included, poten-        CQDM (Quantum Leap-176), and MITACS accelerate

tially providing insights into the compound’s mechanism of           (IT13051). The Structural Genomics Consortium is a regis-

action. However, an assay with no apparent connection to             tered charity (no: 1097737) that receives funds from Bayer

the target assay was also identified. We hope future work            AG, Boehringer Ingelheim, Bristol Myers Squibb, Genen-

explores the full interpretability of MixMin weights for the         tech, Genome Canada through Ontario Genomics Institute

bioassays we tested on.                                              [OGI-196], EU/EFPIA/OICR/McGill/KTH/Diamond Inno-

                                                                     vative Medicines Initiative 2 Joint Undertaking [EUbOPEN

                                                                     grant 875510], Janssen, Merck KGaA (aka EMD in Canada

7. Conclusion

                                                                     and US), Pfizer, and Takeda.

In this paper we formalized a bi-level data mixing objective

                                                                     We thank Chris Crebolder and the rest of the UofT Computer

for mixing data sources to minimize risk on a downstream

                                                                     Science sysadmin team for their help in making many of the

objective. We showed that in the case of CE or MSE, this

                                                                     experiments in this paper possible. We would also like to

objective reduces to a convex minimization as our model

                                                                     thank Marta Skreta, Leo Cotta, Ayoub El Hanchi, William

classes become larger. We proposed using cheap proxy mod-

                                                                     Held, and many others at the Vector Institute for discussions

els trained on the individual source distributions to optimize

                                                                     contributing to this paper.

the convex objective, leading to a data mixing method we

call MixMin. Our experiments showed MixMin consistently

outperformed previous baselines across language modeling             References

and chemistry tasks, and was robust to using cheap proxy             SlimPajama:        A 627B token cleaned and

models. We hope future work explores explaining when                    deduplicated       version        of      RedPajama.

and why MixMin can use cheap proxy model, or develops                   https://www.cerebras.net/blog/slimpajama-a-627b-

alternative empirical approaches to optimizing the convex               token-cleaned-and-deduplicated-version-of-redpajama,

objective for data mixing with large model classes.                     2023.        URL https://huggingface.co/

                                                                        datasets/cerebras/SlimPajama-627B.

Limitations Our reductions for data mixing were specific

to CE and MSE, and required there be no covariate shift              Achiam, J., Adler, S., Agarwal, S., Ahmad, L., Akkaya, I.,

among the source distribution. While this covers generative            Aleman, F. L., Almeida, D., Altenschmidt, J., Altman, S.,

tasks, we hope future work explores extending these ideas              Anadkat, S., et al. Gpt-4 technical report. arXiv preprint

to other loss functions, and handles covariate shift. For              arXiv:2303.08774, 2023.

example, our framework does not currently allow us to do

                                                                     Albalak, A., Pan, L., Raffel, C., and Wang, W. Y. Efficient

data mixing for image classification, where covariate shift is

                                                                       online data mixing for language model pre-training. In R0-

common among sources. Also, MixMin need not be the best

                                                                       FoMo: Robustness of Few-shot and Zero-shot Learning

way to optimize the convex data mixing objective. Finally,

                                                                       in Large Foundation Models, 2023.

an open problem is pushing the limit of how cheap the proxy

model’s can be without degradation to performance.                   Beaini, D., Huang, S., Cunha, J. A., Li, Z., Moisescu-

                                                                       Pareja, G., Dymov, O., Maddrell-Mander, S., McLean,

Impact Statement                                                       C., Wenkel, F., Müller, L., et al. Towards foundational

                                                                       models for molecular learning on large-scale multi-task

This paper presents work whose goal is to advance the field            datasets. arXiv preprint arXiv:2310.04292, 2023.

of Machine Learning. There are many potential societal

consequences of our work, none which we feel must be                 Ben-David, S., Blitzer, J., Crammer, K., Kulesza, A.,

specifically highlighted here.                                         Pereira, F., and Vaughan, J. W. A theory of learning



                                                                 9

