Speeding up Logistic Regression with PCA (MNIST Data)