Search the guide

Start with a guide

Lesson 1 of 14 · Basics · Python tutorial

What a weight does

Change a weight and see the output change.

Multiply, then add#

A weight controls how much an input contributes to an output. A single neuron multiplies each input by its weight, adds the products, then adds a bias. With one input, the calculation is y = w × x + b.

Run a neuron#

Python · NumPy
Ready to run

Output

Run the code to see its output.

Try this: Change a weight, run again, and predict which output will change before you look.

Runs in your browser. Ctrl/⌘ + Enter runs the code.

The same code, different behavior#

The computation stayed the same. Changing the stored numbers changed the function it computes. A larger network combines many such operations; its weights determine how information moves through them.

Course contents