torch.nn.functional.relu6

torch.nn.functional.relu6(input, inplace=False) → Tensor [source]

Applies the element-wise function ReLU6(x)=min(max(0,x),6)\text{ReLU6}(x) = \min(\max(0,x), 6).

See ReLU6 for more details.

Return type

Tensor

© 2024, PyTorch Contributors
PyTorch has a BSD-style license, as found in the LICENSE file.
https://pytorch.org/docs/2.1/generated/torch.nn.functional.relu6.html