Optimizing Sorting with Machine Learning Algorithms