Tensor<T>.AsReadOnlyTensorSpan 方法

定义

重载

AsReadOnlyTensorSpan()

将此 Tensor<T> 转换为指向相同后盾内存的 ReadOnlyTensorSpan<T>。/>

AsReadOnlyTensorSpan(ReadOnlySpan<NIndex>)

将此 Tensor<T> 转换为指向基于提供的起始索引的相同后盾内存的 ReadOnlyTensorSpan<T>。/>

AsReadOnlyTensorSpan(ReadOnlySpan<NRange>)

将此 Tensor<T> 转换为一个 ReadOnlyTensorSpan<T>,该 ReadOnlyTensorSpan<T> 基于提供的范围指向相同的支持内存。/>

AsReadOnlyTensorSpan(ReadOnlySpan<IntPtr>)

将此 Tensor<T> 转换为指向基于提供的起始位置的同一支持内存的 ReadOnlyTensorSpan<T>。/>

AsReadOnlyTensorSpan()

Source:
Tensor.cs
Source:
Tensor.cs

将此 Tensor<T> 转换为指向相同后盾内存的 ReadOnlyTensorSpan<T>。/>

public:
 virtual System::Numerics::Tensors::ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan();
public System.Numerics.Tensors.ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan ();
abstract member AsReadOnlyTensorSpan : unit -> System.Numerics.Tensors.ReadOnlyTensorSpan<'T>
override this.AsReadOnlyTensorSpan : unit -> System.Numerics.Tensors.ReadOnlyTensorSpan<'T>
Public Function AsReadOnlyTensorSpan () As ReadOnlyTensorSpan(Of T)

返回

ReadOnlyTensorSpan<T>

实现

适用于

AsReadOnlyTensorSpan(ReadOnlySpan<NIndex>)

Source:
Tensor.cs
Source:
Tensor.cs

将此 Tensor<T> 转换为指向基于提供的起始索引的相同后盾内存的 ReadOnlyTensorSpan<T>。/>

public:
 virtual System::Numerics::Tensors::ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan(ReadOnlySpan<System::Buffers::NIndex> startIndex);
public System.Numerics.Tensors.ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan (scoped ReadOnlySpan<System.Buffers.NIndex> startIndex);
abstract member AsReadOnlyTensorSpan : ReadOnlySpan<System.Buffers.NIndex> -> System.Numerics.Tensors.ReadOnlyTensorSpan<'T>
override this.AsReadOnlyTensorSpan : ReadOnlySpan<System.Buffers.NIndex> -> System.Numerics.Tensors.ReadOnlyTensorSpan<'T>
Public Function AsReadOnlyTensorSpan (startIndex As ReadOnlySpan(Of NIndex)) As ReadOnlyTensorSpan(Of T)

参数

startIndex
ReadOnlySpan<NIndex>

ReadOnlyTensorSpan<T> 中所需的起始索引

返回

实现

适用于

AsReadOnlyTensorSpan(ReadOnlySpan<NRange>)

Source:
Tensor.cs
Source:
Tensor.cs

将此 Tensor<T> 转换为一个 ReadOnlyTensorSpan<T>,该 ReadOnlyTensorSpan<T> 基于提供的范围指向相同的支持内存。/>

public:
 virtual System::Numerics::Tensors::ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan(ReadOnlySpan<System::Buffers::NRange> start);
public System.Numerics.Tensors.ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan (scoped ReadOnlySpan<System.Buffers.NRange> start);
abstract member AsReadOnlyTensorSpan : ReadOnlySpan<System.Buffers.NRange> -> System.Numerics.Tensors.ReadOnlyTensorSpan<'T>
override this.AsReadOnlyTensorSpan : ReadOnlySpan<System.Buffers.NRange> -> System.Numerics.Tensors.ReadOnlyTensorSpan<'T>
Public Function AsReadOnlyTensorSpan (start As ReadOnlySpan(Of NRange)) As ReadOnlyTensorSpan(Of T)

参数

start
ReadOnlySpan<NRange>

ReadOnlyTensorSpan<T> 中所需的范围

返回

实现

适用于

AsReadOnlyTensorSpan(ReadOnlySpan<IntPtr>)

Source:
Tensor.cs
Source:
Tensor.cs

将此 Tensor<T> 转换为指向基于提供的起始位置的同一支持内存的 ReadOnlyTensorSpan<T>。/>

public:
 virtual System::Numerics::Tensors::ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan(ReadOnlySpan<IntPtr> start);
public System.Numerics.Tensors.ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan (scoped ReadOnlySpan<IntPtr> start);
abstract member AsReadOnlyTensorSpan : ReadOnlySpan<nativeint> -> System.Numerics.Tensors.ReadOnlyTensorSpan<'T>
override this.AsReadOnlyTensorSpan : ReadOnlySpan<nativeint> -> System.Numerics.Tensors.ReadOnlyTensorSpan<'T>
Public Function AsReadOnlyTensorSpan (start As ReadOnlySpan(Of IntPtr)) As ReadOnlyTensorSpan(Of T)

参数

start

ReadOnlySpan<IntPtr>

ReadOnlySpan<nativeint>

ReadOnlyTensorSpan<T> 中所需的起始位置

返回

实现

适用于