A tutorial for MNIST handwritten digit classification using sklearn, PyTorch and Keras.
numpy_matplotlib_sklearn.ipynb
: for numpy, matplotlib and sklearn.pytorch.ipynb
: for pytorch.keras.ipynb
: for keras.- Reference solution: (not published yet)
Code tested on following environments, other version should also work:
- linux system (ubuntu 16.04)
- python 3.6.3
- numpy 1.13.3
- matplotlib 2.1.0
- sklearn 0.19.1
- pytorch 0.4.1
- keras 2.1.2
numpy_matplotlib_sklearn.ipynb
: for numpy, matplotlib and sklearn. [done]pytorch.ipynb
: for pytorch. [done]keras.ipynb
: for keras. [done]
Q1:
Training accuracy: 97.55%
Testing accuracy: 87.90%
Q2:
Training accuracy: 82.03%
Testing accuracy: 79.90%
Q3:
Training accuracy: 97.85%
Testing accuracy: 83.60%
Q4:
Training accuracy: 97.90%
Testing accuracy: 83.70%
Q5:
training accuracy: 0.998046875
testing accuracy: 0.9893830128205128
Q6:
Training accuracy: 1.00%
Testing accuracy: 0.99%