fn
expit
→Tensorexpit(x: Tensor)Logistic sigmoid (expit) function .
Convenience alias for lucid.sigmoid. Maps the real line
onto the open interval and is the inverse of
lucid.logit.
Parameters
xTensorInput tensor; any floating-point dtype.
Returns
Tensor element-wise, same shape
and dtype as x.
Notes
Definition:
Symmetry: . Derivative: . Frequently used as the probabilistic-output activation of binary classifiers.
Examples
>>> import lucid
>>> from lucid.special import expit
>>> expit(lucid.tensor([-2.0, 0.0, 2.0]))
Tensor([0.1192, 0.5000, 0.8808])