Mathematical functions#
Trigonometric functions#
sine of a Generalizes a scalar |
|
cosine of a Generalizes a scalar |
|
tangent of a Generalizes a scalar |
|
arcsine of a Generalizes a scalar |
|
arccosine of a Generalizes a scalar |
|
arctangent of a Generalizes a scalar |
|
arctangent of a / b Generalizes a scalar |
|
convert degree a to radian Generalizes a scalar |
|
convert radian a to degree Generalizes a scalar |
Hyperbolic functions#
hyperbolic sine of a Generalizes a scalar |
|
hyperbolic cosine of a Generalizes a scalar |
|
hyperbolic tangent of a Generalizes a scalar |
|
hyperbolic arc sine of a Generalizes a scalar |
|
hyperbolic arc cosine of a Generalizes a scalar |
|
hyperbolic arc tangent of a Generalizes a scalar |
Rounding#
|
round_mode(a) with mode in [half_away_from_zero, half_to_even]. |
|
cast(round(a,mode),'int64') |
floor of a Generalizes a scalar |
|
ceiling of a Generalizes a scalar |
|
trunc of a Generalizes a scalar |
|
round_half_to_even(a) Generalizes a scalar |
|
round_half_away_from_zero(a) Generalizes a scalar |
Sums, products, differences#
|
Computes the sum along the given axis(es) of a tensor |
|
Return the cumulative sum of the elements along a given |
|
Computes the product along the given axis(es) of a tensor |
|
Return the cumulative product of the elements along a given |
|
Calculate the |
Exponents and logarithms#
e^`a` Generalizes a scalar |
|
e^`a` - 1 Generalizes a scalar |
|
2^`a` Generalizes a scalar |
|
base e logarithm of a Generalizes a scalar |
|
base 2 logarithm of a Generalizes a scalar |
|
base 10 logarithm of a Generalizes a scalar |
|
log(1+a) Generalizes a scalar |
|
|
Logarithm of the sum of exponentiations of the inputs. |
square of a Generalizes a scalar |
|
square root of a Generalizes a scalar |
|
|
Special functions#
complementary error function Generalizes a scalar |
|
scaled complementary error function Generalizes a scalar |
|
inverse complementary error function Generalizes a scalar |
|
inverse error function Generalizes a scalar |
|
owens t function Generalizes a scalar |
|
gamma function Generalizes a scalar |
|
log gamma function Generalizes a scalar |
|
derivative of log gamma function Generalizes a scalar |
|
second derivative of the log gamma function Generalizes a scalar |
|
chi squared survival function Generalizes a scalar |
|
Regularized lower gamma function Generalizes a scalar |
|
Regularized upper gamma function Generalizes a scalar |
|
Upper incomplete gamma function. |
|
Gaussian hypergeometric function. |
|
Derivatives for Gaussian hypergeometric function. |
|
Bessel function of the first kind of order 0. |
|
Bessel function of the first kind of order 1. |
|
Bessel function of the first kind of order v (real). |
|
Modified Bessel function of the first kind of order 0. |
|
Modified Bessel function of the first kind of order 1. |
|
Modified Bessel function of the first kind of order v (real). |
|
Logistic sigmoid function (1 / (1 + exp(-x)), also known as expit or inverse logit Generalizes a scalar |
|
Compute log(1 + exp(x)), also known as softplus or log1pexp Generalizes a scalar |
|
|
|
|
|
|
Return a matrix where each row correspond to the one hot encoding of each element in |
|
Compute the Pochhammer/rising factorial. |
Compute the factorial. |
|
Compute log(1 - exp(x)), also known as log1mexp Generalizes a scalar |
|
Regularized incomplete beta function Generalizes a scalar |
|
|
Compute the log of the sum of exponentials of input elements. |
Generalizes a scalar |
|
Generalizes a scalar |
Arithmetic operations#
elementwise addition Generalizes a scalar |
|
1.0/a Generalizes a scalar |
|
|
|
elementwise modulo Generalizes a scalar |
|
|`a`| Generalizes a scalar |
|
-a Generalizes a scalar |
|
elementwise power Generalizes a scalar |
|
sign of a Generalizes a scalar |
|
elementwise multiplication Generalizes a scalar |
|
elementwise subtraction Generalizes a scalar |
|
elementwise [floor] division (inverse of multiplication) Generalizes a scalar |
|
|
Safely compute |
elementwise [true] division (inverse of multiplication) Generalizes a scalar |
|
|
Element-wise |
>>> a, b = at.itensor3(), at.itensor3() # example inputs
>>> a + 3 # at.add(a, 3) -> itensor3
>>> 3 - a # at.sub(3, a)
>>> a * 3.5 # at.mul(a, 3.5) -> ftensor3 or dtensor3 (depending on casting)
>>> 2.2 / a # at.truediv(2.2, a)
>>> 2.2 // a # at.intdiv(2.2, a)
>>> 2.2**a # at.pow(2.2, a)
>>> b % a # at.mod(b, a)
Extrema#
elemwise maximum. |
|
elemwise minimum. |
|
|
Returns the k-largest elements along an axis. |
|
Returns the indices of k-largest elements along an axis. |
|
Returns the results of both topk() and argtopk() in one Op. |
Complex numbers#
Return polar-coordinate angle of complex-valued tensor |
|
Return real component of complex-valued tensor |
|
Return imaginary component of complex-valued tensor |
|
|
|
Return complex-valued tensor from polar coordinate specification. |
|
Return complex-valued tensor with |
Miscellaneous#
Clip x to be between min and max. |