Tensor<T>.CloneEmpty Method

Definition

Namespace: Numerics.NET.Tensors
Assembly: Numerics.NET.Tensors (in Numerics.NET.Tensors.dll) Version: 9.0.0

Overload List

CloneEmpty(TensorElementOrder) Returns a tensor of the same shape and order of elements as this tensor.
CloneEmpty<U>(TensorElementOrder) Returns a tensor of the same shape and order of elements as this tensor.

CloneEmpty(TensorElementOrder)

Returns a tensor of the same shape and order of elements as this tensor.
C#
public Tensor<T> CloneEmpty(
	TensorElementOrder order = TensorElementOrder.Automatic
)

Parameters

order  TensorElementOrder  (Optional)
Optional. Specifies the element order of the result. By default, elements are stored in the order of the current tensor.

Return Value

Tensor<T>
A tensor of the same shape and order of elements as this tensor.

CloneEmpty<U>(TensorElementOrder)

Returns a tensor of the same shape and order of elements as this tensor.
C#
public abstract Tensor<U> CloneEmpty<U>(
	TensorElementOrder order = TensorElementOrder.Automatic
)

Parameters

order  TensorElementOrder  (Optional)
Optional. Specifies the element order of the result. By default, elements are stored in the order of the current tensor.

Type Parameters

U
The type of the elements of the new tensor.

Return Value

Tensor<U>
A tensor with elements of type U of the same shape and order of elements as this tensor.

See Also