Menu

1 / 4

How does a computer know this is a 3?

DEV Community: machinelearning·Syed Abdul Hanan·18 days ago
#5ZXWENCu
Reading 0:00
15s threshold

A neural network, explained with one handwritten digit and a few simple numbers.

You look at a scribbled 3 and know it in a fraction of a second. A computer has no eyes and no idea what a "3" is. It only has numbers. So how does it get from a grid of pixels to the right answer?

The answer is a neural network. Its core idea is simpler than it sounds, and you can follow it with nothing more than multiplication and addition.

To a computer, an image is just numbers

A small grayscale image of a digit is a grid of 28 by 28 pixels. That's 784 pixels, and each one is stored as a number: 0 for white, 1 for full ink, and values in between for the gray edges of the stroke.

So the computer never sees a "3". It sees a list of 784 numbers.

The digit becomes a 28 × 28 grid. Zoom in and every pixel is a number between 0 (white) and 1 (ink).

One neuron: multiply, add, and add a bias

The basic unit of a neural network is the neuron.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.