TensorFlow.js: Digit Recognizer with Layers

Train a model to recognize handwritten digits from the MNIST database using the tf.layers api.


This examples lets you train a handwritten digit recognizer using either a Convolutional Neural Network (also known as a ConvNet or CNN) or a Fully Connected Neural Network (also known as a DenseNet).

The MNIST dataset is used as training data.

Training Parameters

Training Progress

Inference Examples