Universal Functions (ufunc)
DPNP provides universal functions (a.k.a. ufuncs) to support various elementwise operations.
Available ufuncs
Math operations
Add arguments element-wise. |
|
Subtract arguments, element-wise. |
|
Multiply arguments element-wise. |
|
Divide arguments element-wise. |
|
Provide a true division of the inputs, element-wise. |
|
Compute the largest integer smaller or equal to the division of the inputs. |
|
Negative element-wise. |
|
First array elements raised to powers from second array, element-wise. |
|
Return element-wise remainder of division. |
|
Compute element-wise remainder of division. |
|
Calculate the element-wise remainder of division. |
|
Calculate the absolute value element-wise. |
|
Calculate the absolute value element-wise. |
|
Compute the absolute values element-wise. |
|
Returns an element-wise indication of the sign of a number. |
|
Trigonometric exponent, element-wise. |
|
Trigonometric exponent2, element-wise. |
|
Trigonometric logarithm, element-wise. |
|
Trigonometric logarithm, element-wise. |
|
Trigonometric logarithm, element-wise. |
|
Trigonometric exponent minus 1, element-wise. |
|
Trigonometric logarithm, element-wise. |
|
Return the positive square-root of an array, element-wise. |
|
Return the element-wise square of the input. |
|
Return the reciprocal of the argument, element-wise. |
Trigonometric functions
Trigonometric sine, element-wise. |
|
Trigonometric cosine, element-wise. |
|
Compute tangent element-wise. |
|
Inverse sine, element-wise. |
|
Trigonometric inverse cosine, element-wise. |
|
Trigonometric inverse tangent, element-wise. |
|
Element-wise arc tangent of |
|
Given the "legs" of a right triangle, return its hypotenuse. |
|
Trigonometric hyperbolic sine, element-wise. |
|
Trigonometric hyperbolic cosine, element-wise. |
|
Compute hyperbolic tangent element-wise. |
|
Inverse hyperbolic sine, element-wise. |
|
Trigonometric inverse hyperbolic cosine, element-wise. |
|
Trigonometric hyperbolic inverse tangent, element-wise. |
|
Convert angles from degrees to radians. |
|
Convert angles from radians to degrees. |
Bit-twiddling functions
Compute the bit-wise AND of two arrays element-wise. |
|
Compute the bit-wise OR of two arrays element-wise. |
|
Compute the bit-wise XOR of two arrays element-wise. |
|
Compute bit-wise inversion, or bit-wise NOT, element-wise. |
|
Shift the bits of an integer to the left. |
|
Shift the bits of an integer to the right. |
Comparison functions
Return (x1 > x2) element-wise. |
|
Return (x1 >= x2) element-wise. |
|
Return (x1 < x2) element-wise. |
|
Return (x1 <= x2) element-wise. |
|
Return (x1 != x2) element-wise. |
|
Return (x1 == x2) element-wise. |
|
Compute the truth value of x1 AND x2 element-wise. |
|
Compute the truth value of x1 OR x2 element-wise. |
|
Compute the truth value of x1 XOR x2, element-wise. |
|
Compute the truth value of NOT x element-wise. |
|
Element-wise maximum of array elements. |
|
Element-wise minimum of array elements. |
|
Element-wise maximum of array elements. |
|
Element-wise minimum of array elements. |
Floating functions
Test element-wise for finiteness (not infinity or not Not a Number). |
|
Test element-wise for positive or negative infinity. |
|
Test element-wise for NaN and return result as a boolean array. |
|
Change the sign of x1 to that of x2, element-wise. |
|
Return the fractional and integral parts of an array, element-wise. |
|
Calculate the element-wise remainder of division. |
|
Round a number to the nearest integer toward minus infinity. |
|
Compute the ceiling of the input, element-wise. |
|
Compute the truncated value of the input, element-wise. |