Tensor<T> Class
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.
Represents a tensor.
generic <typename T>
public ref class Tensor sealed : System::Collections::Generic::IEnumerable<T>, System::Numerics::Tensors::IReadOnlyTensor<System::Numerics::Tensors::Tensor<T> ^, T>, System::Numerics::Tensors::ITensor<System::Numerics::Tensors::Tensor<T> ^, T>
[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public sealed class Tensor<T> : System.Collections.Generic.IEnumerable<T>, System.Numerics.Tensors.IReadOnlyTensor<System.Numerics.Tensors.Tensor<T>,T>, System.Numerics.Tensors.ITensor<System.Numerics.Tensors.Tensor<T>,T>
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
type Tensor<'T> = class
interface ITensor<Tensor<'T>, 'T>
interface IReadOnlyTensor<Tensor<'T>, 'T>
interface seq<'T>
interface IEnumerable
Public NotInheritable Class Tensor(Of T)
Implements IEnumerable(Of T), IReadOnlyTensor(Of Tensor(Of T), T), ITensor(Of Tensor(Of T), T)
- T
- Inheritance
-
Tensor<T>
- Attributes
- Implements
Empty |
The Empty Tensor. |
Flattened |
The number of items in the Tensor<T>. |
Is |
Gets a value indicating whether this Tensor<T> is empty. |
Is |
Gets a value indicating whether the backing memory of the Tensor<T> is pinned."/> |
Item[Read |
Returns a reference to specified element of the Tensor. |
Item[Read |
Returns a reference to specified element of the Tensor. |
Item[Read |
Returns a slice of the Tensor. |
Item[Tensor<Boolean>] | |
Lengths |
Gets the length of each dimension in this Tensor<T>. |
Rank |
Gets a value indicating the rank, or number of dimensions, of this Tensor<T>. |
Strides |
Gets the strides of each dimension in this Tensor<T>. |
As |
Converts this Tensor<T> to a ReadOnlyTensorSpan<T> pointing to the same backing memory."/> |
As |
Converts this Tensor<T> to a ReadOnlyTensorSpan<T> pointing to the same backing memory based on the provided start locations."/> |
As |
Converts this Tensor<T> to a ReadOnlyTensorSpan<T> pointing to the same backing memory based on the provided start indexes."/> |
As |
Converts this Tensor<T> to a ReadOnlyTensorSpan<T> pointing to the same backing memory based on the provided ranges."/> |
As |
Converts this Tensor<T> to a TensorSpan<T> pointing to the same backing memory."/> |
As |
Converts this Tensor<T> to a TensorSpan<T> pointing to the same backing memory based on the provided start locations."/> |
As |
Converts this Tensor<T> to a TensorSpan<T> pointing to the same backing memory based on the provided start indexes."/> |
As |
Converts this Tensor<T> to a TensorSpan<T> pointing to the same backing memory based on the provided ranges."/> |
Clear() |
Clears the contents of this tensor. |
Copy |
Copies the contents of this tensor into destination span. If the source and destinations overlap, this method behaves as if the original values in a temporary location before the destination is overwritten. |
Equals(Object) |
Determines whether the specified object is equal to the current object. (Inherited from Object) |
Fill(T) |
Fills the contents of this span with the given value. |
Flatten |
Flattens the contents of this Tensor into the provided Span<T>. |
Get |
Gets an IEnumerator<T> for the Tensor<T>. |
Get |
Gets the hash code for the Tensor<T>. |
Get |
Returns a reference to the 0th element of the Tensor. If the Tensor is empty, returns null reference. It can be used for pinning and is required to support the use of Tensor within a fixed statement. |
Get |
Gets the Type of the current instance. (Inherited from Object) |
Memberwise |
Creates a shallow copy of the current Object. (Inherited from Object) |
Slice(Read |
Forms a slice out of the given tensor |
Slice(Read |
Forms a slice out of the given tensor |
Slice(Read |
Forms a slice out of the given tensor |
To |
Returns a string that represents the current object. (Inherited from Object) |
To |
Creates a String representation of the TensorSpan<T>."/> |
Try |
Copies the contents of this tensor into destination span. If the source and destinations overlap, this method behaves as if the original values in a temporary location before the destination is overwritten. |
Try |
Flattens the contents of this Tensor into the provided Span<T>. |
Implicit(T[] to Tensor<T>) | |
Implicit(Tensor<T> to Read |
|
Implicit(Tensor<T> to Tensor |
IEnumerable. |
Gets an IEnumerator for the Tensor<T>."/> |
IEnumerable<T>.Get |
Gets an IEnumerator<T> for the Tensor<T>. |
IRead |
Returns a reference to the 0th element of the ReadOnlyTensor. If the ReadOnlyTensor is empty, returns null reference. It can be used for pinning and is required to support the use of ReadOnlyTensor within a fixed statement. |
IRead |
Returns the specified element of the ReadOnlyTensor. |
IRead |
Returns the specified element of the ReadOnlyTensor. |
IRead |
Returns a slice of the ReadOnlyTensor. |
IRead |
Gets the length of each dimension in this Tensor<T>. |
IRead |
Gets the strides of each dimension in this Tensor<T>. |
ITensor<Tensor<T>,T>.Create(Read |
Creates a Tensor<T> and initializes it with the default value of T. If |
ITensor<Tensor<T>,T>.Create(Read |
Creates a Tensor<T> and initializes it with the default value of T. If |
ITensor<Tensor<T>,T>.Create |
Creates a Tensor<T> and does not initialize it. If |
ITensor<Tensor<T>,T>.Create |
Creates a Tensor<T> and does not initialize it. If |
ITensor<Tensor<T>,T>.Is |
|
ITensor<Tensor<T>,T>.Item[Read |
Returns the specified element of the Tensor. |
ITensor<Tensor<T>,T>.Item[Read |
Returns the specified element of the Tensor. |
To |
Creates a FrozenDictionary<TKey,TValue> from an IEnumerable<T> according to specified key selector function. |
To |
Creates a FrozenDictionary<TKey,TValue> from an IEnumerable<T> according to specified key selector and element selector functions. |
To |
Creates a FrozenSet<T> with the specified values. |
To |
Creates an immutable array from the specified collection. |
To |
Constructs an immutable dictionary based on some transformation of a sequence. |
To |
Constructs an immutable dictionary from an existing collection of elements, applying a transformation function to the source keys. |
To |
Enumerates and transforms a sequence, and produces an immutable dictionary of its contents by using the specified key and value comparers. |
To |
Enumerates and transforms a sequence, and produces an immutable dictionary of its contents by using the specified key comparer. |
To |
Enumerates and transforms a sequence, and produces an immutable dictionary of its contents. |
To |
Enumerates a sequence, produces an immutable hash set of its contents, and uses the specified equality comparer for the set type. |
To |
Enumerates a sequence and produces an immutable hash set of its contents. |
To |
Enumerates a sequence and produces an immutable list of its contents. |
To |
Enumerates and transforms a sequence, and produces an immutable sorted dictionary of its contents by using the specified key and value comparers. |
To |
Enumerates and transforms a sequence, and produces an immutable sorted dictionary of its contents by using the specified key comparer. |
To |
Enumerates and transforms a sequence, and produces an immutable sorted dictionary of its contents. |
To |
Enumerates a sequence, produces an immutable sorted set of its contents, and uses the specified comparer. |
To |
Enumerates a sequence and produces an immutable sorted set of its contents. |
Broadcast |
Broadcast the data from |
Permute |
Swaps the dimensions of the |
Reshape<T>(Tensor<T>, Read |
Reshapes the |
Set |
Sets a slice of the given |
Squeeze<T>(Tensor<T>) |
Removes all dimensions of length one from the |
Squeeze |
Removes axis of length one from the |
To |
|
Try |
Broadcast the data from |
Unsqueeze<T>(Tensor<T>, Int32) |
Insert a new dimension of length 1 that will appear at the dimension position. |
Produkt | Versionen |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
Feedback zu .NET
.NET ist ein Open Source-Projekt. Wählen Sie einen Link aus, um Feedback zu geben: