torch_polygamma function

Polygamma

Polygamma

torch_polygamma(n, input)

Arguments

  • n: (int) the order of the polygamma function
  • input: (Tensor) the input tensor.

Note

This function is not implemented for \eqn{n \geq 2}.

polygamma(n, input, out=NULL) -> Tensor

Computes the nthn^{th} derivative of the digamma function on input. n0n \geq 0 is called the order of the polygamma function.

ψ(n)(x)=d(n)dx(n)ψ(x) \psi^{(n)}(x) = \frac{d^{(n)}}{dx^{(n)}} \psi(x)

Examples

if (torch_is_installed()) { ## Not run: a = torch_tensor(c(1, 0.5)) torch_polygamma(1, a) ## End(Not run) }
  • Maintainer: Daniel Falbel
  • License: MIT + file LICENSE
  • Last published: 2024-05-21