On this page
torch.sinh
torch.sinh(input, *, out=None) → Tensor
-
Returns a new tensor with the hyperbolic sine of the elements of
input
.- Parameters
-
input (Tensor) – the input tensor.
- Keyword Arguments
-
out (Tensor, optional) – the output tensor.
Example:
>>> a = torch.randn(4) >>> a tensor([ 0.5380, -0.8632, -0.1265, 0.9399]) >>> torch.sinh(a) tensor([ 0.5644, -0.9744, -0.1268, 1.0845])
Note
When
input
is on the CPU, the implementation of torch.sinh may use the Sleef library, which rounds very large results to infinity or negative infinity. See here for details.
© 2024, PyTorch Contributors
PyTorch has a BSD-style license, as found in the LICENSE file.
https://pytorch.org/docs/2.1/generated/torch.sinh.html