mindspore.ops.digamma
- mindspore.ops.digamma(input)[source]
Computes the grad of the lgamma function on input.
\[P(input) = grad(\ln \Gamma(input))\]Warning
This is an experimental API that is subject to change or deletion.
- Parameters
input (Tensor) – The input tensor. With type of float16 or float32 or float64.
- Returns
Tensor, has the same dtype as input.
- Raises
- Supported Platforms:
GPU
CPU
Examples
>>> x = Tensor(np.array([1.5, 0.5, 9]).astype(np.float16)) >>> output = ops.digamma(x) >>> print(output) [ 0.0365 -1.964 2.14 ]