Tensor Class
Contains static methods that operate on tensors.
Definition
Namespace: Numerics.NET.Tensors
Assembly: Numerics.NET.Tensors (in Numerics.NET.Tensors.dll) Version: 9.0.5
C#
Assembly: Numerics.NET.Tensors (in Numerics.NET.Tensors.dll) Version: 9.0.5
public static class Tensor
- Inheritance
- Object → Tensor
Methods
Abs<T> | Computes the absolute value of the elements of a tensor. |
Absolute | Computes the element with the largest absolute value of a tensor. |
Absolute | Computes the element with the largest absolute value of a tensor. |
Absolute | Computes the index of the elements of a tensor with the largest absolute value along the specified axis. |
Absolute | Computes the index of the element with the largest absolute value of a tensor. |
Absolute | Computes the element with the smallest absolute value of a tensor. |
Absolute | Computes the element with the smallest absolute value of a tensor. |
Absolute | Computes the index of the elements of a tensor with the smallest absolute value along the specified axis. |
Absolute | Computes the index of the element with the smallest absolute value of a tensor. |
Acos<T> | Computes the inverse cosine of the elements of a tensor. |
Acosh<T> | Computes the inverse hyperbolic cosine of the elements of a tensor. |
Add<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Adds a tensor and a scalar. |
Add<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Adds two tensors. |
Add<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Adds a scalar and a tensor. |
Add | Multiplies two tensors elementwise and multiplies the result by a third. |
All( | Returns whether all elements of a boolean tensor are true. |
All( | Computes whether all elements of a boolean tensor along the specified axis are true. |
And<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise and of a tensor and a scalar. |
And<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise and of two tensors. |
And<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise and of a scalar and a tensor. |
Any( | Returns whether any elements of a boolean tensor are true. |
Any( | Computes whether any elements of a boolean tensor along the specified axis are true. |
Asin<T> | Computes the inverse sine of the elements of a tensor. |
Asinh<T> | Computes the inverse hyperbolic sine of the elements of a tensor. |
Atan<T> | Computes the inverse tangent of the elements of a tensor. |
Atan2<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the inverse tangent of the elements of a tensor and a scalar.. |
Atan2<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the inverse tangent of the elements of two tensors. |
Atan2<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the inverse tangent of a scalar and the elements of a tensor.. |
Atanh<T> | Computes the inverse hyperbolic tangent of the elements of a tensor. |
AtLeast1D<T>(Tensor<T>) | Returns an equivalent tensor that has at least one dimension. |
AtLeast1D<T>(Tensor<T>[]) | Returns an array of equivalent tensors that have at least one dimension. |
AtLeast2D<T>(Tensor<T>) | Returns an equivalent tensor that has at least two dimensions. |
AtLeast2D<T>(Tensor<T>[]) | Returns an array of equivalent tensors that have at least two dimensions. |
AtLeast3D<T>(Tensor<T>) | Gets an equivalent tensor that has at least three dimensions. |
AtLeast3D<T>(Tensor<T>[]) | Returns an array of equivalent tensors that have at least three dimensions. |
Cbrt<T> | Computes the cube root of the elements of a tensor. |
Ceiling<T> | Computes the smallest integer that is not greater than the elements of a tensor. |
Clamp<T> | Computes the values of a tensor clamped by the corresponding values of two other tensors. |
Concatenate<T> | Concatenates a sequence of tensors along the specified axis. |
Correlation<T>(Tensor<T>, Tensor<T>, Tensor<Boolean>, Boolean) | Computes the correlation of the corresponding elements of two tensors. |
Correlation<T>(Tensor<T>, Tensor<T>, Axes, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the correlation of the corresponding elements of two tensors. |
Cos<T> | Computes the cosine of the elements of a tensor. |
Cosh<T> | Computes the hyperbolic cosine of the elements of a tensor. |
Cosine | Computes the cosine similarity of the corresponding elements of two tensors. |
Cosine | Computes the cosine similarity of the corresponding elements of two tensors. |
Covariance<T>(Tensor<T>, Tensor<T>, Tensor<Boolean>, Boolean) | Computes the covariance of the corresponding elements of two tensors. |
Covariance<T>(Tensor<T>, Tensor<T>, Axes, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the covariance of the corresponding elements of two tensors. |
Create<T>(Int32[]) | Constructs a new 3D tensor with the specified dimensions. |
Create<T>(TensorShape, TensorElementOrder) | Constructs a new tensor with the specified shape. |
Create | Constructs a 1-dimensional tensor from a 1-dimensional array. |
Create | Constructs a 4-dimensional tensor from a 4-dimensional array. |
Create | Constructs a 3-dimensional tensor from a 3-dimensional array. |
Create | Constructs a 2-dimensional tensor from a 2-dimensional array. |
Create | Constructs a 1-dimensional tensor from a 1-dimensional array. |
Create | Constructs a 4-dimensional tensor from a 4-dimensional array using the array's memory to store the tensor elements. |
Create | Constructs a 3-dimensional tensor from a 3-dimensional array using the array's memory to store the tensor elements. |
Create | Constructs a 2-dimensional tensor from a 2-dimensional array using the array's memory to store the tensor elements. |
Create | Constructs a new dense tensor of the specifed dimensions, wrapping existing backing memory for the contents. |
Create | Constructs a new dense tensor of the specifed dimensions, wrapping existing backing memory for the contents. |
Create | Creates a new 1-dimensional tensor and initializes the elements using the specified function. |
Create | Creates a new 1-dimensional tensor and initializes the elements using the specified function."/> |
Create | Creates a new 2-dimensional tensor and initializes the elements using the specified function. |
Create | Creates a new 3-dimensional tensor and initializes the elements using the specified function. |
Create | Creates a new 4-dimensional tensor and initializes the elements using the specified function. |
Create | Constructs a 2-dimensional tensor from a 2-dimensional array. |
Create | Constructs a new dense tensor of the specifed dimensions, wrapping existing backing memory for the contents. |
Create | Constructs a new dense tensor of the specifed dimensions, wrapping existing backing memory for the contents. |
Create | Constructs a 1-dimensional tensor from a span. |
Create | Constructs a new tensor with elements from the specified range. |
Create | Constructs a new tensor with elements from the specified range. |
Create | Constructs a new tensor with elements from the specified range. |
Create | Constructs a new tensor with uniform random numbers between 0 and 1. |
Create | Constructs a new tensor with uniform random numbers between 0 and 1. |
Create | Constructs a new tensor with normal random numbers with zero mean and unit standard deviation. |
Create | Constructs a new tensor with normal random numbers with zero mean and unit standard deviation. |
Create | Constructs a new tensor with elements from 0 up to the specified value. |
Create | Constructs a new 1D tensor with elements from the specified range.. |
Create | Constructs a new tensor with elements from the specified range.. |
Create | Constructs a new tensor with elements from the specified range. |
Create | Constructs a 0-dimensional tensor that represents a scalar value. |
Cumulative | Computes the cumulative product of the elements of a tensor. |
Cumulative | Computes the cumulative sum of the elements of a tensor. |
Divide<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Divides a tensor by a scalar. |
Divide<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Divides one tensor by another. |
Divide<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Divides a scalar by a tensor. |
Dot | Computes the dot product of the corresponding elements of two tensors. |
Dot | Computes the dot product of the corresponding elements of two tensors. |
Equal | Compares a tensor and a scalar for equality.. |
Equal | Compares two tensors elementwise for equality. |
Equal | Compares a scalar and a tensor for equality.. |
Euclidean | Computes the Euclidean distance of the corresponding elements of two tensors. |
Euclidean | Computes the Euclidean distance of the corresponding elements of two tensors. |
Exp<T> | Computes the exponential function of the elements of a tensor. |
Exp10<T> | Computes the exponential function (base 10) of the elements of a tensor. |
Exp2<T> | Computes the exponential function (base 2) of the elements of a tensor. |
Exp | Computes the exponential function of the elements of a tensor. |
Find | Gets the linearized indexes where the specified boolean tensor is true. |
Floor<T> | Computes the largest integer that is not less than the elements of a tensor. |
Greater | Returns whether the elements of a tensor are greater than a scalar.. |
Greater | Returns whether the elements of one tensor are greater than the corresponding elements of another tensor.. |
Greater | Returns whether a scalar are greater than the elements of a tensor.. |
Greater | Returns whether the elements of a tensor are greater than or equal to a scalar.. |
Greater | Returns whether the elements of one tensor are less than or equal to the corresponding elements of another tensor.. |
Greater | Returns whether a scalar are greater than or equal to the elements of a tensor.. |
Hypot<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the square root of the sum of the squares of the elements of a tensor and a scalar.. |
Hypot<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the square root of the sum of the squares of the elements of two tensors. |
Hypot<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the square root of the sum of the squares of a scalar and the elements of a tensor.. |
Identity<T>(Int32, Int32, TensorElementOrder) | Returns a 2D tensor that is 1 on the specified diagonal and zero everywhere else. |
Identity<T>(Int32, Int32, Int32, TensorElementOrder) | Returns a 2D tensor that is 1 on the specified diagonal and zero everywhere else. |
If<T> | Selects the elements of one of two tensors based on a condition. |
Imaginary | Returns a tensor with the imaginary part of the elements of a tensor of complex numbers. |
IsNull | Gets whether the specified boolean tensor is null or a scalar tensor with value true. |
Left | Shifts the elements of a tensor to the left. |
Left | Shifts the elements of a tensor to the left.. |
Left | Shifts a scalar to the left.. |
Less | Returns whether the elements of a tensor are less than a scalar.. |
Less | Returns whether the elements of one tensor are less than the corresponding elements of another tensor.. |
Less | Returns whether a scalar are less than the elements of a tensor.. |
Less | Returns whether the elements of a tensor are less than or equal to a scalar.. |
Less | Returns whether the elements of one tensor are less than or equal to the corresponding elements of another tensor.. |
Less | Returns whether a scalar are less than or equal to the elements of a tensor.. |
Log<T>(Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the logarithm of the elements of a tensor. |
Log<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the logarithm of the elements of a tensor to base a scalar.. |
Log<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the logarithm of the elements of a tensor in the base specified by another tensor. |
Log<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the logarithm of a scalar to base the elements of a tensor.. |
Log10<T> | Computes the base 10 logarithm of the elements of a tensor. |
Log1p<T> | Computes the logarithm of the elements of a tensor. |
Log2<T> | Computes the base 2 logarithm of the elements of a tensor. |
Map<T, TResult>(Func<T, TResult>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Applies a function to the corresponding elements of two tensors and returns the result in a third tensor. |
Map<T, U, TResult>(Func<T, U, TResult>, Tensor<T>, Tensor<U>, Tensor<Boolean>, TensorElementOrder) | Applies a function to the corresponding elements of two tensors and returns the result in a third tensor. |
Map | Applies a function to the elements of a tensor. |
Map | Applies a function to the corresponding elements of two tensors. |
Map | Applies a function to the corresponding elements of three tensors. |
Matrix | Performs matrix multiplication over the last two dimensions of a pair of tensors. |
Max<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the maximum of the elements of a tensor and a scalar.. |
Max<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the largest of corresponding elements of two tensors. |
Max<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the maximum of a scalar and the elements of a tensor.. |
Max<T>(Tensor<T>, Index, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the maxima of the elements of a tensor along the specified axis. |
Max | Computes the index of the largest elements of a tensor along the specified axis. |
Max | Computes the index of the largest element of a tensor. |
Max | Computes the maximum of the elements of a tensor and a scalar.. |
Max | Computes the largest of corresponding elements of two tensors without propagating NaN's (where applicable). |
Max | Computes the maximum of a scalar and the elements of a tensor.. |
Max | Computes the largest element of a tensor. |
Max | Computes the largest element of a tensor. |
Mean<T>(Tensor<T>, Tensor<Boolean>, Boolean) | Computes the mean of the elements of a tensor. |
Mean<T>(Tensor<T>, Axes, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the mean of the elements of a tensor. |
Median<T>(Tensor<T>, Tensor<Boolean>, Boolean) | Computes the mean of the elements of a tensor. |
Median<T>(Tensor<T>, Axes, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the mean of the elements of a tensor. |
Min<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the minimum of the elements of a tensor and a scalar.. |
Min<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the smallest of corresponding elements of two tensors. |
Min<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the minimum of a scalar and the elements of a tensor.. |
Min<T>(Tensor<T>, Index, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the minima of the elements of a tensor along the specified axis. |
Min | Computes the index of the smallest elements of a tensor along the specified axis. |
Min | Computes the index of the smallest element of a tensor. |
Min | Computes the minimum of the elements of a tensor and a scalar.. |
Min | Computes the smallest of corresponding elements of two tensors without propagating NaN's (where applicable). |
Min | Computes the minimum of a scalar and the elements of a tensor.. |
Min | Computes the smallest element of a tensor. |
Min | Computes the smallest element of a tensor. |
Modulus<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the remainder after dividing a tensor by a scalar. |
Modulus<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Returns the remainder after dividing one tensor by another. |
Modulus<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the remainder after dividing a scalar by a tensor. |
Multiply<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Multiplies a tensor and a scalar. |
Multiply<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Multiplies two tensors. |
Multiply<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Multiplies a scalar and a tensor. |
Multiply | Adds two tensors and multiplies the result elementwise by a third. |
Negate<T> | Negates a tensor. |
Norm<T>(Tensor<T>, Tensor<Boolean>, Boolean) | Computes the two-norm of the elements of a tensor. |
Norm<T>(Tensor<T>, Axes, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the two-norm of the elements of a tensor. |
Not<T> | Computes the bitwise complement of a tensor. |
Not | Compares a tensor and a scalar for inequality.. |
Not | Compares two tensors elementwise for inequality. |
Not | Compares a scalar and a tensor for inequality.. |
One | Computes the sum of the absolute values of the elements of a tensor. |
One | Computes the sum of the absolute values of the elements of a tensor. |
Or<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise or of a tensor and a scalar. |
Or<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise or of two tensors. |
Or<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise or of a scalar and a tensor. |
Percentile<T>(Tensor<T>, Double, QuantileType, Tensor<Boolean>, Boolean) | Computes the quantile of the elements of a tensor. |
Percentile<T>(Tensor<T>, Double, Axes, QuantileType, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the percentiles of the elements of a tensor along the specified axis. |
Percentiles<T> | Computes the percentiles of the elements of a tensor along the specified axis. |
Pow<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Raises the elements of a tensor to a power. |
Pow<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Raises the elements of a tensor to a power. |
Pow<T>(Tensor<T>, Tensor<Int32>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Raises the elements of a tensor to an integer power. |
Pow<T>(Tensor<T>, Int32, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Raises the elements of a tensor to an integer power. |
Pow<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Raises a scalar to a power. |
Pow<T>(T, Tensor<Int32>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Raises a scalar to an integer power. |
Product<T>(Tensor<T>, Tensor<Boolean>, Boolean) | Computes the product of the elements of a tensor. |
Product<T>(Tensor<T>, Axes, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the product of the elements of a tensor. |
Quantile<T>(Tensor<T>, Double, QuantileType, Tensor<Boolean>, Boolean) | Computes the quantile of the elements of a tensor. |
Quantile<T>(Tensor<T>, Double, Axes, QuantileType, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the quantiles of the elements of a tensor along the specified axis. |
Quantiles<T> | Computes the quantiles of the elements of a tensor along the specified axis. |
Real | Returns a tensor with the real part of the elements of a tensor of complex numbers. |
Reciprocal<T> | Computes the reciprocal of the elements of a tensor. |
Remove | Removes all singleton dimensions from a tensor. |
Right | Shifts the elements of a tensor to the right. |
Right | Shifts the elements of a tensor to the right.. |
Right | Shifts a scalar to the right.. |
Root | Computes the n-th root of the elements of a tensor. |
Root | Computes the n-th root of a the elements of a tensor. |
Root | Computes the n-th root of a a scalar. |
Round<T>(Tensor<T>, Tensor<Int32>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Rounds the elements of a tensor to the specified number of digits. |
Round<T>(Tensor<T>, Int32, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Rounds the elements of a tensor to the specified number of digits.. |
Round<T>(T, Tensor<Int32>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Rounds a scalar to the specified number of digits.. |
Sin<T> | Computes the sine of the elements of a tensor. |
Sinh<T> | Computes the hyperbolic sine of the elements of a tensor. |
Soft | Applies the SoftMax function along the specified axis of a tensor. |
Sort<T>(Tensor<T>, IComparer<T>, Index, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Sorts the elements of a tensor. |
Sort<T>(Tensor<T>, Index, Tensor<T>, Tensor<Boolean>, Boolean, TensorElementOrder) | Sorts the elements of a tensor. |
Sqrt<T> | Computes the square root of the elements of a tensor. |
Stack<T> | Concatenates a sequence of tensors into a tensor of a higher dimension. |
Stack | Stacks 1D tensors as columns in a 2D array. |
Stack | Stacks tensors in the third (depth) dimension. |
Stack | Stacks tensors horizontally (by column). |
Stack | Stacks tensors horizontally (by column). |
Stack | Stacks 1D tensors by row. |
Stack | Stacks tensors vertically (by row). |
Stack | Stacks tensors vertically (by row). |
Standard | Computes the standard deviation of the elements of a tensor. |
Standard | Computes the standard deviation of the elements of a tensor. |
Subtract<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Subtracts a scalar from a scalar. |
Subtract<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Subtracts one tensor from another. |
Subtract<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Subtracts a tensor from a tensor. |
Sum<T>(Tensor<T>, Tensor<Boolean>, Boolean) | Computes the sum of the elements of a tensor. |
Sum<T>(Tensor<T>, Axes, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the sum of the elements of a tensor. |
Swap<T> | Swaps the elements of two tensors. |
Tan<T> | Computes the tangent of the elements of a tensor. |
Tanh<T> | Computes the hyperbolic tangent of the elements of a tensor. |
Truncate<T> | Truncates the elements of a tensor to the nearest integer. |
Variance<T>(Tensor<T>, Tensor<Boolean>, Boolean) | Computes the variance of the elements of a tensor. |
Variance<T>(Tensor<T>, Axes, Tensor<T>, Boolean, Tensor<Boolean>, Boolean, TensorElementOrder) | Computes the variance of the elements of a tensor. |
Xor<T>(Tensor<T>, T, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise xor of a tensor and a scalar. |
Xor<T>(Tensor<T>, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise xor of two tensors. |
Xor<T>(T, Tensor<T>, Tensor<T>, Tensor<Boolean>, TensorElementOrder) | Computes the bitwise xor of a scalar and a tensor. |
Fields
False | Gets a boolean scalar tensor with the value false. |
True | Gets a boolean scalar tensor with the value true. |