mindspore.nn.SeLU

class mindspore.nn.SeLU[source]

Activation function SeLU (Scaled exponential Linear Unit).

Refer to mindspore.ops.selu() for more details.

Supported Platforms:

Ascend GPU CPU

Examples

>>> input_x = Tensor(np.array([[-1.0, 4.0, -8.0], [2.0, -5.0, 9.0]]), mindspore.float32)
>>> selu = nn.SeLU()
>>> output = selu(input_x)
>>> print(output)
[[-1.1113307 4.202804 -1.7575096]
[ 2.101402 -1.7462534 9.456309 ]]