Machine learning assignment using MNIST handwritten digit recognition