A Data and Platform-Aware Framework For Large-Scale Machine Learning