reciprocal

dragon.math.reciprocal(
  inputs,
  **kwargs
)[source]

Compute the reciprocal of input.

\[\text{out} = \frac{1}{\text{input}} \]

Examples:

x = dragon.constant([0., 1., 2.])
print(dragon.math.reciprocal(x))  # [inf, 1., 0.5]
Parameters:
Returns:

dragon.Tensor The output tensor.