SELU is ELU with two very specific numbers bolted on:
with
Task: write selu(values) returning one output per input, each rounded to 4 decimal places.
alpha, then multiply the whole thing by lambda. The scale applies to both branches, positive and negative.alpha and lambda are constants here — the function takes no extra arguments.x = 0 maps to exactly 0.0.Those two ugly constants are not arbitrary: they're solved for, so that activations with mean 0 and variance 1 going into a layer come out with mean 0 and variance 1 again. Stack SELU layers and the signal neither explodes nor fades as it goes deeper — the network is self-normalising, which is where the extra S comes from. Change either constant and that property quietly disappears, which is why you'll always see them written out to full precision.