Art of DS

Appearance

Palette
Theme
Unlock $20 one time
Sign in, or create an account

Sign in to Art of DSCreate your Art of DS account

We email you a link and a six-digit code. Either one signs you in; there is no password.Enter your email. We send a link and a six-digit code to confirm it — no password to remember. The account is free.

  • You come back to this page, right where you were.
  • Already have an account? The same email simply signs you in.

By continuing you accept the Terms and the Privacy policy.

Your account

Free accountLifetime access

Which activation, and where?

Five activations side by side, the pairs people confuse, and one deep network trained with each, where one learns nothing and one loses a fifth of its units.

prints on 2 A4 pagesfrom 6 pages and 1 cataloguefree to read · PDF with a free accountUpdated 24 Oct 2026

Download PDF

The PDF and the Print button ask you to sign in; a free account is enough. Reading and Test yourself are open to everyone.

Side by side

The first columns are the Activation functions catalogue’s; the rest come from each page.

Say what each one answers, what it cannot see and when to reach for it, then reveal its row.

Activation Output range Peak gradient Saturates? Reach for it when Trap
Step {0, 1} 0 (undefined at 0) Everywhere explaining the perceptron; never in a network trained by gradient It only converges if the data is linearly separable.
Sigmoid (0, 1) 0.25 Both tails a single yes-or-no output needs a probability Do not stack sigmoids deep.
Tanh (−1, 1) 1 Both tails a recurrent cell needs a bounded, zero-centred state It still saturates.
ReLU [0, ∞) 1 Negative side only hidden layers, by default Dying ReLU.
Leaky ReLU (−∞, ∞) 1 No dead units have been counted, not suspected Diagnose before switching.

A formula is printed only when it is shorter than the words; the others are said in words, and each page has its formula.

Easy to confuse

The “what is the difference between…” questions, in two lines each.

  • Sigmoid vs Tanh

    Tanh is sigmoid rescaled to (−1, 1), zero-centred with four times the peak gradient; both saturate in the tails.

    Tanh inside a network, if a bounded activation is wanted at all; sigmoid at a binary output.

  • ReLU vs Leaky ReLU

    Leaky ReLU keeps a small slope below zero, so no unit stops receiving gradient; ReLU's exact zeros make it sparse.

    ReLU by default; leaky ReLU once dead units are measured.

  • Sigmoid vs Softmax

    Sigmoid gives each output its own probability; softmax makes the outputs one distribution that sums to 1.

    Softmax when exactly one class is true; a sigmoid per label when several can be.

  • Saturated unit vs Dead unit

    A saturated sigmoid passes back a gradient that is tiny but never zero; a dead ReLU unit passes back none, for every input.

    Saturation comes with depth and is fixed by the activation; dead units often come from too large a learning rate.

One real run

The same ten-layer network trained on two circles with each activation, and once with none.

Activation Gradient kept Dead Test acc.
none 0.79 0.00 0.46
step 0 0.12 0.48
sigmoid 1.6e-6 0.00 0.50
tanh 0.64 0.00 0.99
relu 0.87 0.20 0.99
leaky-relu 0.87 0.00 0.99

“Without a non-linearity, ten layers are one straight line.”

“Sigmoid's gradient does not survive the depth.”

“A fifth of ReLU's units die; leaky ReLU loses none.”

The run and these lines are the worked example on ReLU, as it printed: 10 hidden layers of 32 units, two circles, mean of 5 seeds

Which one?

  1. Where does it sit?

    • A hidden layer ReLU
    • A recurrent cell Tanh
  2. What does the output answer?

  3. Are many units dead?

Each answer is from its page’s “Why & when”.

All 23 traps on these pages

Each is the opening line of a pitfall; its page says why.

Perceptron

  • Scale your features.
  • It only converges if the data is linearly separable.
  • The output is not a confidence.

Sigmoid

  • Use a numerically stable implementation.
  • Outputs are not zero-centred.
  • Do not stack sigmoids deep.
  • Sigmoid output is not calibrated by default.

Tanh

  • It still saturates.
  • Zero-centred inputs matter too.
  • The derivative has a cheap closed form.
  • Being better than sigmoid is a low bar.

ReLU

  • Dying ReLU.
  • Unbounded output.
  • Not zero-centred.
  • Watch your learning rate.

Leaky ReLU

  • a is a hyperparameter you probably will not tune.
  • It gives up sparsity.
  • It is not reliably better.
  • Diagnose before switching.

Softmax

  • Taking the log of the output.
  • Reading confidence off it.
  • Applying it twice.
  • Using it for multi-label problems.

Have a promo code?

A code that takes 100% off unlocks everything at once. A smaller one takes its share off the price in the payment window: enter the same code there.

Write to support

A question, a problem with access, a refund? Write to us and we answer by email.

What is it about?

Your address is used only to answer you.

Message sent

Thank you. We will reply to the address you gave, by email.

Or write to us directly

support@artofds.com

Message sent Thank you. We will reply to the address you gave, by email.

Check the email address: we need it to reply.

That is our own address. Enter yours, so the reply reaches you.

This address cannot receive email. Check it for a typo.

Write a little more: at least 10 characters.

Too many messages in a short time. Try again in a few minutes.

The message could not be sent. Please write to us directly: support@artofds.com