Level 0: Foundation
★☆☆☆☆ Introductory⏱ 5 minGeneral audience. No mathematics required.A soft floor instead of a wall
ELU behaves like ReLU for positive inputs, but instead of cutting negative inputs to zero, it curves smoothly down to a floor at −α. Negative outputs mean the average activation can sit near zero, and the gradient is never exactly zero, so units cannot die. SELU scales ELU with two carefully chosen constants so that signals keep a mean of 0 and a variance of 1 as they pass through many layers.
Normalisation layers add compute and behave differently in training and inference, which complicates deployment on embedded hardware and with small batches. SELU promised deep fully connected networks without them, attractive for tabular sensor data and small on-board models. Knowing exactly when that promise holds avoids silent failures.
- 1. ELU for very negative inputs approaches…
- 2. SELU aims to keep activations at…
- 3. Can an ELU unit die like a ReLU unit?
Level 1: Beginner
★★☆☆☆ Basic⏱ 20 minSecondary-school mathematics: arithmetic and elementary algebra.Definitions by hand
- ELU (Clevert, Unterthiner and Hochreiter, 2016): f(z) = z for z > 0, α(eᶻ − 1) for z ≤ 0, usually with α = 1. ELU(−1) = e⁻¹ − 1 ≈ −0.632, ELU(2) = 2.
- Gradient: 1 for z > 0, αeᶻ for z ≤ 0, which equals f(z) + α, so the backward pass can reuse the forward output. At z = −1 with α = 2: 2e⁻¹ ≈ 0.736.
- Smoothness: with α = 1 the derivative is continuous at 0 (both sides equal 1).
- SELU (Klambauer et al., 2017): f(z) = λ·ELU(z; α) with λ ≈ 1.0507 and α ≈ 1.6733. Its floor is −λα ≈ −1.758.
- ELU on standard normal input: mean ≈ 0.161, second moment ≈ 0.645. The mean is closer to zero than ReLU’s 0.399, but not zero.
- Initialisation: SELU needs LeCun-normal weights, w ~ N(0, 1/fan-in).
- 1. ELU(−1) with α = 1 is about…
- 2. For z ≤ 0, ELU′(z) equals…
- 3. SELU's weights should be initialised with variance…
Level 2: Intermediate
★★★☆☆ Intermediate⏱ 25 minUndergraduate students and practising engineers.Where the constants come from
Exercise 1. SELU must map z ~ N(0, 1) to an output with mean 0 and second moment 1.
- The mean condition depends only on α, since λ scales the mean but cannot make it zero. Bisection on E[ELU(z; α)] = 0 gives α ≈ 1.6733.
- λ then scales the second moment to 1: λ = 1/√E[ELU(z; α)²] ≈ 1.0507.
- Checking by quadrature, SELU on N(0, 1) gives mean below 10⁻⁶ and second moment 1.000000.
Why a fixed point is not enough. Klambauer et al. went further. They showed that the map from one layer’s (mean, variance) to the next is a contraction near (0, 1) when the weights have mean 0 and variance 1/fan-in. Moments that start nearby are therefore pulled toward (0, 1) layer by layer. Large variances are pulled down because the negative side saturates. Small variances are pushed up because the positive slope λ > 1.
Alpha dropout. Ordinary dropout sets activations to 0, which changes SELU’s mean and variance. Alpha dropout sets dropped units to the saturation value −λα, then applies an affine map a·x + b that restores mean 0 and variance 1.
nn.SELU(); nn.AlphaDropout(p=0.05)
nn.init.kaiming_normal_(w, nonlinearity='linear') # LeCun normal: std = 1/sqrt(fan_in)- 1. Which constant alone fixes SELU's zero mean?
- 2. Alpha dropout replaces dropped units with…
- 3. Large input variances are reduced by SELU because…
Level 3: Advanced
★★★★☆ Advanced⏱ 25 minGraduate level, with full derivations and proofs.Theory
Self-normalisation theorem (Klambauer et al., 2017, informal). Consider SELU layers with weights of mean 0 and variance 1/fan-in, and inputs whose mean and variance lie in a domain around (0, 1). Then the moment map g: (μ, ν) ↦ (μ̃, ν̃) has a stable, attracting fixed point at (0, 1). They also proved upper and lower bounds on the variance for inputs outside that domain, so gradients cannot vanish or explode.
Assumptions to watch.
- Weight statistics. The theorem assumes weight mean 0 and variance exactly 1/fan-in. Training changes the weights, and exercise 2 shows a 10% scale error already shifts the fixed point noticeably.
- Independence. Pre-activations are treated as approximately Gaussian sums of independent terms. Convolutions, residual connections and attention break this, which is why SELU mostly appears in plain fully connected networks.
- Dropout. Standard dropout breaks the moments; alpha dropout is needed.
ELU’s benefits.
- Negative outputs push mean activations toward zero, reducing the bias shift that slows learning (Clevert et al. related this to natural gradient).
- It is smooth for α = 1.
- It does not die.
The costs are an exponential per negative input, and saturation for very negative inputs.
Results.
- Clevert et al. (2016) reported faster training and better CIFAR-100 accuracy than ReLU variants.
- Klambauer et al. (2017) reported SELU networks outperforming other fully connected networks across 121 UCI tasks, and training plain networks up to 32 layers deep.
- 1. SELU's self-normalisation mainly applies to…
- 2. The moment map near (0, 1) is…
- 3. ELU's negative outputs help by…
Level 4: Expert
★★★★★ Expert⏱ 25 minResearchers: original papers and open problems.How robust is self-normalisation?
History.
- D.-A. Clevert, T. Unterthiner and S. Hochreiter (2016) introduced ELU.
- G. Klambauer, T. Unterthiner, A. Mayr and S. Hochreiter (2017) introduced SELU and alpha dropout, with a 90-page computer-assisted proof of the self-normalisation theorem.
Exercise 2. Inputs with mean 1 and standard deviation 2 (badly scaled) pass through 64 random plain layers of width 128. The weights use the activation’s recommended scale (LeCun for SELU, ELU and tanh; He for ReLU) times 0.9, 1.0 or 1.1. Then plain networks of depth 32 (width 32, no normalisation) are trained on spirals for 300 steps.
| activation | weight scale | (mean, variance) at layer 8 | at layer 32 | at layer 64 |
|---|---|---|---|---|
| SELU | 0.9 | (−0.08, 0.65) | (−0.06, 0.48) | (−0.07, 0.43) |
| SELU | 1.0 | (−0.02, 1.25) | (0.02, 1.03) | (−0.02, 0.99) |
| SELU | 1.1 | (0.12, 2.32) | (0.18, 1.96) | (0.12, 1.86) |
| ELU | 1.0 | (0.03, 0.18) | (0.00, 0.0074) | (0.00, 0.0012) |
| tanh | 1.0 | (−0.01, 0.072) | (0.00, 0.019) | (0.00, 0.0065) |
| ReLU (He) | 0.9 | (0.62, 0.89) | (0.04, 0.0028) | (0.00, 4.6e-6) |
| ReLU (He) | 1.0 | (1.45, 4.78) | (1.14, 2.36) | (1.03, 3.32) |
| ReLU (He) | 1.1 | (3.1, 22) | (24, 1050) | (459, 6.6e5) |
Training accuracy at depth 32 (three seeds): SELU 0.920, 1.000, 0.997; ELU 0.887, 0.998, 1.000; ReLU 0.865, 0.680, 0.437.
- SELU self-normalised as promised. The input variance of 4 became 3.5 after one layer and 1.03 by layer 32. No other activation did this. ELU and tanh shrank the variance toward 0, and He-initialised ReLU kept the input’s bad scale without correcting it.
- The fixed point depends on the weight scale. With weights 10% too small or too large, SELU settled at variance 0.43 or 1.86 rather than 1. That is still a stable, bounded value, unlike ReLU, whose variance vanished or exploded geometrically (factor 0.9² or 1.1² per layer).
- In training, SELU and ELU tied, and both clearly beat ReLU at depth 32 without normalisation. Here, SELU’s forward normalisation did not translate into an advantage over ELU, even though ELU’s forward variance collapsed at initialisation.
ELU and SELU in AI, robotics and aerospace
- Tabular and sensor data: SELU MLPs are a strong baseline for fixed-length feature vectors such as engine health monitoring and telemetry, without normalisation layers.
- Small-batch and on-board training: batch normalisation is unreliable with tiny batches. Self-normalising networks avoid it.
- Physics-informed networks and implicit models: smooth activations such as ELU give continuous derivatives, needed when derivatives of the network enter the loss.
References
- D.-A. Clevert, T. Unterthiner, S. Hochreiter (2016). “Fast and accurate deep network learning by exponential linear units (ELUs).” Proc. ICLR.
- G. Klambauer, T. Unterthiner, A. Mayr, S. Hochreiter (2017). “Self-normalizing neural networks.” Advances in NeurIPS 30.