Skip to main content
Colin Jaffe/2 min read

MNIST Dataset: Variations in Handwritten Digits

ML Best Practices

0/4
Master Machine Learning at Noble Desktop

Noble Desktop's Python Machine Learning Bootcamp covers scikit-learn, Keras, neural networks, and applied ML.

This lesson is a preview from our Data Science & AI Certificate Online (includes software) and Python Certification Online (includes software & exam). Enroll in a course for detailed lessons, live instructor support, and project-based training.

Explore the MNIST dataset to recognize handwritten digits using neural networks. Watch this tutorial to learn the key concepts and techniques.

Let's talk about the data we're working with and the problem we're trying to solve. We're going to be working with the MNIST dataset. That's the Modified National Institute of Standards and Technology Database.

It's a very popular database of handwritten digits, and it's commonly used to train a machine learning model to recognize digits. It's also used for machine learning quite often. Let's take a look at displaying your own image stored on Google Drive. We've done this for you, but it's really not very hard to do—just learn how to display an image using the Image library.

But let's take a look at this image, which we grabbed from Wikipedia, to show you the kind of digits we're going to be working with. So these are the MNIST—this is a sample of the MNIST handwritten digits. And you can see how much variation there is among the zeros, handwritten, among the ones—look at all the crazy different directions they're leaning.

This one is almost 45 degrees. There's quite a bit of variation in how people draw twos—more with loops than I would have thought. These threes—every one of these numbers—make it particularly apparent how many different styles you can have.

So having a system that can learn how to recognize a seven with a little extra line down or a line through it, versus this one with a bold stroke, or another that looks unusual, to a very simple, standard seven like this one. But you know, there aren’t many standard sevens. So having a system that can recognize all of these and identify each one with great accuracy—that's a very tough challenge unless you're using a neural network.

Let's dive into that data even more in the next lesson.