Tensor.CreateUninitialized Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
CreateUninitialized<T>(ReadOnlySpan<IntPtr>, ReadOnlySpan<IntPtr>, Boolean) |
Creates a Tensor<T> and does not initialize it. If |
CreateUninitialized<T>(ReadOnlySpan<IntPtr>, Boolean) |
Creates a Tensor<T> and does not initialize it. If |
CreateUninitialized<T>(ReadOnlySpan<IntPtr>, ReadOnlySpan<IntPtr>, Boolean)
- Source:
- Tensor.Factory.cs
- Source:
- Tensor.Factory.cs
Creates a Tensor<T> and does not initialize it. If pinned
is true, the memory will be pinned.
public static System.Numerics.Tensors.Tensor<T> CreateUninitialized<T> (scoped ReadOnlySpan<IntPtr> lengths, scoped ReadOnlySpan<IntPtr> strides, bool pinned = false);
static member CreateUninitialized : ReadOnlySpan<nativeint> * ReadOnlySpan<nativeint> * bool -> System.Numerics.Tensors.Tensor<'T>
Public Function CreateUninitialized(Of T) (lengths As ReadOnlySpan(Of IntPtr), strides As ReadOnlySpan(Of IntPtr), Optional pinned As Boolean = false) As Tensor(Of T)
Type Parameters
- T
Parameters
- lengths
-
ReadOnlySpan<nativeint>
A ReadOnlySpan<T> indicating the lengths of each dimension.
- strides
-
ReadOnlySpan<nativeint>
A ReadOnlySpan<T> indicating the strides of each dimension.
Returns
Applies to
CreateUninitialized<T>(ReadOnlySpan<IntPtr>, Boolean)
- Source:
- Tensor.Factory.cs
- Source:
- Tensor.Factory.cs
Creates a Tensor<T> and does not initialize it. If pinned
is true, the memory will be pinned.
public static System.Numerics.Tensors.Tensor<T> CreateUninitialized<T> (scoped ReadOnlySpan<IntPtr> lengths, bool pinned = false);
static member CreateUninitialized : ReadOnlySpan<nativeint> * bool -> System.Numerics.Tensors.Tensor<'T>
Public Function CreateUninitialized(Of T) (lengths As ReadOnlySpan(Of IntPtr), Optional pinned As Boolean = false) As Tensor(Of T)
Type Parameters
- T
Parameters
- lengths
-
ReadOnlySpan<nativeint>
A ReadOnlySpan<T> indicating the lengths of each dimension.