Versioned name: Swish-4

Category: Activation

Short description: Swish takes one input tensor and produces output tensor where the Swish function is applied to the tensor elementwise.

Detailed description: For each element from the input tensor calculates corresponding element in the output tensor with the following formula:

\[ Swish(x) = x / (1.0 + e^{-(beta * x)}) \]

The Swish operation is introduced in the article.



  • 1: Multidimensional input tensor of type T. Required.
  • 2: Scalar with non-negative value of type T. Multiplication parameter beta for the sigmoid. If the input is not connected then the default value 1.0 is used. Optional


  • 1: The resulting tensor of the same shape and type as input tensor.


  • T: arbitrary supported floating point type.


<layer ... type="Swish">
<port id="0">
<port id="1"/>
<port id="1">