Tensor.CreateFromMatrix<T> Method

Constructs a 2-dimensional tensor from a 2-dimensional array.

Definition

Namespace: Numerics.NET.Tensors
Assembly: Numerics.NET.Tensors (in Numerics.NET.Tensors.dll) Version: 9.0.3
C#
public static Tensor<T> CreateFromMatrix<T>(
	Matrix<T> matrix
)

Parameters

matrix  Matrix<T>
An array containing the elements of the new tensor.

Type Parameters

T
The type of the elements of the tensor.

Return Value

Tensor<T>
A 2-dimensional tensor of the same shape and with the same elements as matrix.

See Also