Skip to content

RNN classifier built with Keras to classify MNIST dataset

License

Notifications You must be signed in to change notification settings

ar-ms/lstm-mnist

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

lstm-mnist

Image classification using a RNN classifier(LSTM) with Keras.

Requirements

  • python3
  • tensorflow (>=1.4)
  • keras (>=2.1.1)
  • numpy

Train and evaluate

The classifier is trained on 55k samples and tested on 10k samples (The default split).

The ANN is made of one LSTM layer with 128 hidden units and one dense output layer of 10 units with softmax activation. The rmsprop optimizer is used with categorial_crossentropy as loss function.

Launch lstm_classifier.py to train and evaluate the classifier, you can dump a trained classifier and load it later.

python lstm_classifier.py

Ressources