# tf.math.sigmoid

<br />

|---|---|
| [![](https://www.tensorflow.org/images/tf_logo_32px.png) TensorFlow 1 version](https://www.tensorflow.org/versions/r1.15/api_docs/python/tf/math/sigmoid) | [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/tensorflow/blob/v2.0.0/tensorflow/python/ops/math_ops.py#L3112-L3132) |

Computes sigmoid of `x` element-wise.

#### View aliases


**Main aliases**

[`tf.nn.sigmoid`](https://www.tensorflow.org/api_docs/python/tf/math/sigmoid), [`tf.sigmoid`](https://www.tensorflow.org/api_docs/python/tf/math/sigmoid)
**Compat aliases for migration**

See
[Migration guide](https://www.tensorflow.org/guide/migrate) for
more details.

[`tf.compat.v1.math.sigmoid`](https://www.tensorflow.org/api_docs/python/tf/math/sigmoid), [`tf.compat.v1.nn.sigmoid`](https://www.tensorflow.org/api_docs/python/tf/math/sigmoid), [`tf.compat.v1.sigmoid`](https://www.tensorflow.org/api_docs/python/tf/math/sigmoid)

<br />

    tf.math.sigmoid(
        x, name=None
    )

Specifically, `y = 1 / (1 + exp(-x))`.

<br />

<br />

<br />

| ## Args ||
|---|---|
| `x` | A Tensor with type `float16`, `float32`, `float64`, `complex64`, or `complex128`. |
| `name` | A name for the operation (optional). |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| A Tensor with the same type as `x`. ||

<br />

#### Scipy Compatibility

Equivalent to scipy.special.expit