Method empty
static member empty: ITensorDevice -> int -> Tensor<'T>
Creates a new, empty tensor with the given number of dimensions.
Declaration
static member empty: dev:ITensorDevice -> nDims:int -> Tensor<'T>
Parameters
Type | Name | Description |
---|---|---|
ITensorDevice | dev | The device to create the tensor on. |
int | nDims | The number of dimensions of the new, empty tensor. |
Returns
Type | Description |
---|---|
Tensor<'T> | The new, empty tensor. |
Remarks
The shape of the tensor is [0L; ...; 0L]
. It contains no elements.