We can't find the internet
Attempting to reconnect
Something went wrong!
Attempting to reconnect
← Activations step 2 of 9
Easy
Primitives
Implement Sigmoid
Implement the sigmoid activation function.
$$\sigma(x) = \frac{1}{1 + e^{-x}}$$
The sigmoid function maps any real number to the range $(0, 1)$.
Input: A tensor x of any shape
Output: A tensor of the same shape with values in $(0, 1)$
Loading visualization…
Nothing accepted yet. When a submission passes, the code that passed shows up
here, one entry per mode.
Stuck?
PyTorch reference solution
Sign in to attempt this problem and reveal the reference solution.