A perceptron is one artificial neuron: it weighs its inputs, adds them up, and decides whether to fire. Wire thousands together and you get a neural network — but the whole thing is built from this single repeated unit.
Where you meet it
- Every layer of a neural net — each node is one of these neurons.
- Linear classifiers: spam vs. not-spam, a simple yes/no decision from a few features.
- Deep learning frameworks — a
Dense/Linearlayer is just many neurons side by side.
What it does
It turns several input numbers into one output number. Each input gets a weight saying how much it matters; the neuron sums the weighted inputs, shifts the total by a bias, and passes the result through an activation function that decides how strongly it fires.
One neuron is just a single straight line — it can't even do XOR. The magic isn't the neuron, it's stacking nonlinear ones.
How it works
The whole neuron is two steps. First the weighted sum, then the activation:
z = w₁x₁ + w₂x₂ + … + wₙxₙ + b
y = f(z)
- Weighted sum (Σ wᵢxᵢ) — each weight says how important that input is; its sign says whether the input pushes the decision up or down.
- Bias (b) — a movable threshold. It shifts the whole sum so the neuron fires sooner or later, independent of the inputs.
- Activation (f) — squashes
zinto the output: a step function gives a hard 0/1; sigmoid, tanh and ReLU give smooth, trainable signals.
Geometrically, one neuron draws a single straight decision boundary through the input space: everything on one side fires, everything on the other stays quiet. The weights set the line's tilt, the bias sets its position.
Watch out
- One perceptron can't solve XOR. XOR isn't linearly separable — no single straight line splits it. The fix is layers: stack neurons and the network can bend boundaries into any shape.
- No nonlinear activation = no depth. Stack purely linear neurons and the whole stack collapses back into one linear function. The nonlinearity is what makes deep networks more powerful than a single neuron.
- Don't drop the bias. Without
bthe decision boundary is forced through the origin, which throws away half the lines it could draw. - Weights are learned, not set by hand. Training nudges every weight and bias to shrink the error — the values are the result, not the input.
Go deeper
Ein Perzeptron ist ein künstliches Neuron: Es gewichtet seine Eingaben, summiert sie und entscheidet, ob es feuert. Verdrahtest du Tausende davon, entsteht ein neuronales Netz — aber das Ganze besteht aus dieser einen, wiederholten Einheit.
Wo es vorkommt
- Jede Schicht eines neuronalen Netzes — jeder Knoten ist genau so ein Neuron.
- Lineare Klassifikatoren: Spam oder nicht, eine simple Ja/Nein-Entscheidung aus ein paar Merkmalen.
- Deep-Learning-Frameworks — eine
Dense- /Linear-Schicht ist nur viele Neuronen nebeneinander.
Was es tut
Es macht aus mehreren Eingabezahlen eine Ausgabezahl. Jede Eingabe bekommt ein Gewicht, das sagt, wie wichtig sie ist; das Neuron summiert die gewichteten Eingaben, verschiebt die Summe um einen Bias und schickt das Ergebnis durch eine Aktivierungsfunktion, die bestimmt, wie stark es feuert.
Ein Neuron ist nur eine einzige Gerade — XOR schafft es nicht mal. Die Magie ist nicht das Neuron, sondern das Stapeln nichtlinearer.
Wie es funktioniert
Das ganze Neuron sind zwei Schritte. Zuerst die gewichtete Summe, dann die Aktivierung:
z = w₁x₁ + w₂x₂ + … + wₙxₙ + b
y = f(z)
- Gewichtete Summe (Σ wᵢxᵢ) — jedes Gewicht sagt, wie wichtig diese Eingabe ist; sein Vorzeichen, ob die Eingabe die Entscheidung hebt oder senkt.
- Bias (b) — eine verschiebbare Schwelle. Er rückt die ganze Summe, sodass das Neuron früher oder später feuert, unabhängig von den Eingaben.
- Aktivierung (f) — drückt
zin die Ausgabe: eine Stufenfunktion liefert hart 0/1; sigmoid, tanh und ReLU liefern weiche, trainierbare Signale.
Geometrisch zieht ein Neuron eine einzige gerade Entscheidungsgrenze durch den Eingaberaum: alles auf der einen Seite feuert, alles auf der anderen bleibt still. Die Gewichte bestimmen die Neigung der Linie, der Bias ihre Position.
Worauf achten
- Ein Perzeptron kann XOR nicht lösen. XOR ist nicht linear trennbar — keine einzige Gerade teilt es. Die Lösung sind Schichten: Stapelt man Neuronen, kann das Netz Grenzen in jede Form biegen.
- Keine nichtlineare Aktivierung = keine Tiefe. Stapelt man rein lineare Neuronen, fällt der ganze Stapel wieder zu einer linearen Funktion zusammen. Erst die Nichtlinearität macht tiefe Netze mächtiger als ein einzelnes Neuron.
- Den Bias nicht vergessen. Ohne
bwird die Entscheidungsgrenze durch den Ursprung gezwungen — das verschenkt die Hälfte der möglichen Linien. - Gewichte werden gelernt, nicht von Hand gesetzt. Das Training schubst jedes Gewicht und jeden Bias, um den Fehler zu verkleinern — die Werte sind das Ergebnis, nicht die Eingabe.