Benchmark by training a logistic regression classifier on the MNIST dataset.