# tensorplay.functional.cosh Source: https://www.tensorplay.cn/docs/generated/tensorplay.functional.cosh.html ```python tensorplay.functional.cosh(input, *, out=None) → Tensor ``` Returns a new tensor with the hyperbolic cosine of the elements of input. $$\text{out}_{i} = \cosh(\text{input}_{i})$$ Parameters: input ([Tensor](/docs/generated/tensorplay.Tensor.html#tensorplay.Tensor)) – the input tensor. Keyword Arguments: out ([Tensor](/docs/generated/tensorplay.Tensor.html#tensorplay.Tensor), optional) – the output tensor. Example: ``` >>> a = tensorplay.randn(4) >>> a tensor([ 0.1632, 1.1835, -0.6979, -0.7325]) >>> tensorplay.cosh(a) tensor([ 1.0133, 1.7860, 1.2536, 1.2805]) ``` > **Note** > > When input is on the CPU, the implementation of tensorplay.cosh may use the Sleef library, which rounds very large results to infinity or negative infinity. See here for details.