

Import the fashion_mnist datasetLet’s import the dataset and prepare it for training, validation and test.

To learn more about Colab, read the official blog post or read my blog post on Colab here.ĭataThere are ten categories to classify in the fashion_mnist dataset: Choose this option if you just want to quickly open the notebook and follow along with this tutorial. You can open the notebook with zero setup by directly opening my Jupyter Notebook on Github with Colab which runs on Google’s VM in the Cloud. Run this notebook in ColabAll the code below is in a Jupyter Notebook on my GitHub. If you are a beginner to deep learning, I encourage you to compare and contrast my tutorial with this much older MNSIT tutorial, using the original low-level TensorFlow APIs, to see how much easier things have become. I will try to go over some of the deep learning terminologies. Using tf.keras enables you to take advantage of functionality like eager execution and tf.data - should you like to down the road. You can write all your usual great Keras programs as you normally would using this tf.keras, with the main change being just the imports. It’s built right into to TensorFlow - in addition to being an independent open source project. Keras is popular and well-regarded high-level deep learning API. It’s great for writing “hello world” tutorials for deep learning. It shares the same image size (28x28) and structure of training (60,000) and testing (10,000) splits. In just a few lines of code, you can define and train a model that is able to classify the images with over 90% accuracy, even without much optimization.įashion-MNIST can be used as drop-in replacement for the original MNIST dataset (10 categories of handwritten digits). This is a tutorial of how to classify the Fashion-MNIST dataset with tf.keras, using a Convolutional Neural Network (CNN) architecture.
