<br />

|---|
| [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/tensorflow/blob/v2.21.0/tensorflow/python/ops/math_ops.py#L662-L685) |

Computes elementwise softplus: `softplus(x) = log(exp(x) + 1)`.

#### View aliases


**Main aliases**

[`tf.nn.softplus`](https://www.tensorflow.org/api_docs/python/tf/math/softplus)

<br />

    tf.math.softplus(
        features, name=None
    )

### Used in the notebooks

| Used in the guide | Used in the tutorials |
|---|---|
| - [Introduction to gradients and automatic differentiation](https://www.tensorflow.org/guide/autodiff) | - [TFP Probabilistic Layers: Regression](https://www.tensorflow.org/probability/examples/Probabilistic_Layers_Regression) - [Gaussian Process Latent Variable Models](https://www.tensorflow.org/probability/examples/Gaussian_Process_Latent_Variable_Model) - [Bayesian Modeling with Joint Distribution](https://www.tensorflow.org/probability/examples/Modeling_with_JointDistribution) |

`softplus` is a smooth approximation of `relu`. Like `relu`, `softplus` always
takes on positive values.

![](https://www.tensorflow.org/images/softplus.png)

#### Example:

    import tensorflow as tf
    tf.math.softplus(tf.range(0, 2, dtype=tf.float32)).numpy()
    array([0.6931472, 1.3132616], dtype=float32)

<br />

<br />

<br />

| ## Args ||
|---|---|
| `features` | `Tensor` |
| `name` | Optional: name to associate with this operation. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| `Tensor` ||

<br />