tf.nn.leaky_relu
Stay organized with collections
Save and categorize content based on your preferences.
Compute the Leaky ReLU activation function.
tf.nn.leaky_relu(
features, alpha=0.2, name=None
)
Used in the notebooks
Source: Rectifier Nonlinearities Improve Neural Network Acoustic Models.
AL Maas, AY Hannun, AY Ng - Proc. ICML, 2013.
Args |
features
|
A Tensor representing preactivation values. Must be one of
the following types: float16 , float32 , float64 , int32 , int64 .
|
alpha
|
Slope of the activation function at x < 0.
|
name
|
A name for the operation (optional).
|
Returns |
The activation value.
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates. Some content is licensed under the numpy license.
Last updated 2024-04-26 UTC.
[null,null,["Last updated 2024-04-26 UTC."],[],[],null,["# tf.nn.leaky_relu\n\n\u003cbr /\u003e\n\n|----------------------------------------------------------------------------------------------------------------------------|\n| [View source on GitHub](https://github.com/tensorflow/tensorflow/blob/v2.16.1/tensorflow/python/ops/nn_ops.py#L3667-L3699) |\n\nCompute the Leaky ReLU activation function. \n\n tf.nn.leaky_relu(\n features, alpha=0.2, name=None\n )\n\n### Used in the notebooks\n\n| Used in the tutorials |\n|-----------------------------------------------------------------------------------------------|\n| - [Scalable model compression](https://www.tensorflow.org/tutorials/optimization/compression) |\n\nSource: [Rectifier Nonlinearities Improve Neural Network Acoustic Models.\nAL Maas, AY Hannun, AY Ng - Proc. ICML, 2013](https://ai.stanford.edu/%7Eamaas/papers/relu_hybrid_icml2013_final.pdf).\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Args ---- ||\n|------------|--------------------------------------------------------------------------------------------------------------------------------------|\n| `features` | A `Tensor` representing preactivation values. Must be one of the following types: `float16`, `float32`, `float64`, `int32`, `int64`. |\n| `alpha` | Slope of the activation function at x \\\u003c 0. |\n| `name` | A name for the operation (optional). |\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Returns ------- ||\n|---|---|\n| The activation value. ||\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| References ---------- ||\n|---|---|\n| Rectifier Nonlinearities Improve Neural Network Acoustic Models: [Maas et al., 2013](http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.693.1422) ([pdf](http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.693.1422&rep=rep1&type=pdf)) ||\n\n\u003cbr /\u003e"]]