latest (dev)
Copy
Latest development documentation · Updated 2026-10-15
tensorplay.functional.angle
- tensorplay.functional.angle(input: Tensor, *, out: Tensor | None) Tensor[source]
Computes the element-wise angle (in radians) of the given
inputtensor.- Parameters:
input (Tensor) – the input tensor.
- Keyword Arguments:
out (Tensor, optional) –
the output tensor.
zero for non-negative real numbers, and propagates NaNs. Previously the function would return zero for all real numbers and not propagate floating-point NaNs.
Example:
>>> tensorplay.angle(tensorplay.tensor([-1 + 1j, -2 + 2j, 3 - 3j]))*180/3.14159 tensor([ 135., 135, -45])
Help improve this page
Found an error, an unclear step, or a missing example?
Was this page helpful?

