Array Operations¶
Array creation routines¶
Returns an array without initializing the elements. |
|
Returns a new array with same shape and dtype of a given array. |
|
Returns a 2-D array with ones on the diagonals and zeros elsewhere. |
|
Returns a 2-D identity array. |
|
Returns a new array of given shape and dtype, filled with ones. |
|
Returns an array of ones with same shape and dtype as a given array. |
|
Returns a new array of given shape and dtype, filled with zeros. |
|
Returns an array of zeros with same shape and dtype as a given array. |
|
Returns a new array of given shape and dtype, filled with a given value. |
|
Returns a full array with same shape and dtype as a given array. |
|
Creates an array. |
|
Converts an object to an array. |
|
Converts an object to an array. |
|
Returns a C-contiguous array. |
|
Creates a copy of a given array. |
|
Returns a 1-D array interpretation of a buffer. |
|
Constructs an array from data in a text or binary file. |
|
Constructs an array by executing a function over each coordinate. |
|
Constructs a new 1-D array from an iterable object. |
|
Constructs a new 1-D array initialized from text data in a string. |
|
Constructs an array by loading data from a text file. |
|
Returns an array with evenly spaced values within a given interval. |
|
Returns an array with evenly spaced numbers over a specified interval. |
|
Returns a diagonal or a diagonal array. |
|
Creates a diagonal array from the flattened input. |
|
Returns coordinate matrices from coordinate vectors. |
|
Returns a 2-D array with ones at and below the given diagonal and zeros elsewhere. |
|
Lower triangle of an array. |
|
Upper triangle of an array. |
Activation functions¶
The log of the softmax of input array. |
|
Element-wise hyperbolic tangent function. |
|
Rectified Linear Unit function. |
|
Element-wise sigmoid logistic function. |
|
S-LSTM units as an activation function. |
|
TreeLSTM unit as an activation function. |
Array manipulation routines¶
Returns a reshaped array. |
|
Returns a flattened array. |
|
Permutes the dimensions of an array. |
|
Broadcasts an array to a given shape. |
|
Removes size-one axes from the shape of an array. |
|
Converts an object to an array. |
|
Returns a C-contiguous array. |
|
Joins arrays along an axis. |
|
Stacks arrays along a new axis. |
|
Stack arrays in sequence horizontally (column wise). |
|
Stack arrays in sequence vertically (row wise). |
|
Stack arrays in sequence depth wise (along third axis). |
|
View inputs as arrays with at least two dimensions. |
|
View inputs as arrays with at least three dimensions. |
|
Splits an array into multiple sub arrays along a given axis. |
|
Split array into multiple sub-arrays along the 3rd axis (depth). |
|
Splits an array into multiple sub-arrays vertically (row-wise). |
|
Split an array into multiple sub-arrays horizontally (column-wise). |
|
Interchange two axes of an array. |
|
Constructs an array by repeating a given array. |
|
Expand the shape of an array. |
|
Reverse the order of elements in an array along the given axis. |
|
Flip array in the left/right direction. |
|
Flip array in the up/down direction. |
|
Move axes of an array to new positions. |
Evaluation routines¶
Computes multiclass classification accuracy of the minibatch. |
Indexing routines¶
Takes elements from an array along an axis. |
|
Return elements chosen from |
|
Return the indices of the elements that are non-zero. |
Linear algebra¶
Returns a dot product of two arrays. |
|
Computes the Cholesky decomposition of a matrix. |
|
Compute the qr factorization of a matrix. |
|
Singular Value Decomposition. |
|
Compute the eigenvalues and eigenvectors of a real symmetric matrix. |
|
Compute the eigenvalues of a real symmetric matrix. |
|
Solves a linear matrix equation, or system of linear scalar equations. |
|
Computes the inverse of a matrix. |
|
Compute the (Moore-Penrose) pseudo-inverse of a matrix. |
Logic functions¶
Test whether all array elements along a given axis evaluate to True. |
|
Test whether any array element along a given axis evaluate to True. |
|
Test element-wise for positive or negative infinity. |
|
Test element-wise for NaN and return result as a boolean array. |
|
Returns an array of x1 AND x2 element-wise. |
|
Returns an array of x1 OR x2 element-wise. |
|
Returns an array of x1 XOR x2 element-wise. |
|
Returns an array of NOT x element-wise. |
|
Returns an array of (x1 > x2) element-wise. |
|
Returns an array of (x1 >= x2) element-wise. |
|
Returns an array of (x1 < x2) element-wise. |
|
Returns an array of (x1 <= x2) element-wise. |
|
Returns an array of (x1 == x2) element-wise. |
|
Returns an array of (x1 != x2) element-wise. |
Loss functions¶
Element-wise absolute error function. |
|
Element-wise squared error function. |
|
Element-wise Huber loss. |
|
Element-wise KL-divergence of Gaussian variables from the standard one. |
|
Element-wise cross entropy loss for pre-sigmoid activations. |
|
Element-wise cross entropy loss for pre-softmax activations. |
Mathematical functions¶
Numerical negative, element-wise. |
|
Add arguments, element-wise. |
|
Subtract arguments, element-wise. |
|
Multiply arguments, element-wise. |
|
Divide arguments, element-wise. |
|
remainder(x1, x2) Return element-wise remainder of division. |
|
Return element-wise remainder of division. |
|
Sum of array elements over a given axis. |
|
Maximum arguments, element-wise. |
|
Minimum arguments, element-wise. |
|
Numerical exponential, element-wise. |
|
Natural logarithm, element-wise. |
|
Base 10 logarithm, element-wise. |
|
Base 2 logarithm, element-wise. |
|
Natural logarithm of one plus the input, element-wise. |
|
The log of the sum of exponentials of input array. |
|
The log of the softmax of input array. |
|
Non-negative square-root, element-wise |
|
Sine, element-wise |
|
Cosine, element-wise |
|
Tangent, element-wise |
|
Inverse sine, element-wise |
|
Trigonometric inverse cosine, element-wise |
|
Trigonometric inverse tangent, element-wise |
|
Element-wise arc tangent of \(\frac{x_1}{x_2}\) choosing the quadrant correctly. |
|
Hyperbolic Sine, element-wise |
|
Hyperbolic Cosine, element-wise |
|
Element-wise hyperbolic tangent function. |
|
Inverse hyperbolic sine, element-wise |
|
Inverse hypberbolic inverse cosine, element-wise |
|
Returns the element-wise square of the input. |
|
Clips the values of an array to a given interval. |
|
Compute the absolute values element-wise. |
|
Returns an element-wise indication of the sign of a number. |
|
Return the ceiling of the input, element-wise.. |
|
Return the floor of the input, element-wise. |
|
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. |
|
Shift the bits of an integer to the left. |
|
Shift the bits of an integer to the right. |
Random sampling¶
Draws random samples from a normal (Gaussian) distribution. |
|
Draws samples from a uniform distribution. |
Sorting, searching, and counting¶
Returns the indices of the maximum along an axis. |
|
Returns the indices of the minimum along an axis. |
Statistics¶
Returns the maximum of an array or the maximum along an axis. |
|
Compute the arithmetic mean along the specified axis. |
|
Compute the arithmetic var along the specified axis. |
Connection¶
N-dimensional convolution. |
|
N-dimensional transposed convolution. |
|
Linear function, or affine transformation. |
|
Long Short-Term Memory units as an activation function. |
Normalization¶
Batch normalization function. |
|
Batch normalization function with fixed statistics. |
Pooling¶
Spatial max pooling function. |
|
Spatial average pooling function. |
RNN¶
Stacked Uni-directional Long Short-Term Memory function. |
|
Stacked Bi-directional Long Short-Term Memory function. |
|
Stacked Uni-directional Gated Recurrent Unit function. |
|
Stacked Bi-directional Gated Recurrent Unit function. |
|
Stacked Uni-directional RNN function for sequence inputs. |
|
Stacked Bi-directional RNN function for sequence inputs. |