Tensor<T>.Slice 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
Slice(ReadOnlySpan<NIndex>) |
从给定张量中形成切片 |
Slice(ReadOnlySpan<NRange>) |
从给定张量中形成切片 |
Slice(ReadOnlySpan<IntPtr>) |
从给定张量中形成切片 |
Slice(ReadOnlySpan<NIndex>)
- Source:
- Tensor.cs
从给定张量中形成切片
public:
virtual System::Numerics::Tensors::Tensor<T> ^ Slice(ReadOnlySpan<System::Buffers::NIndex> startIndex);
public System.Numerics.Tensors.Tensor<T> Slice (scoped ReadOnlySpan<System.Buffers.NIndex> startIndex);
abstract member Slice : ReadOnlySpan<System.Buffers.NIndex> -> System.Numerics.Tensors.Tensor<'T>
override this.Slice : ReadOnlySpan<System.Buffers.NIndex> -> System.Numerics.Tensors.Tensor<'T>
Public Function Slice (startIndex As ReadOnlySpan(Of NIndex)) As Tensor(Of T)
参数
- startIndex
- ReadOnlySpan<NIndex>
切片的起始索引
返回
Tensor<T> 作为提供的范围的副本。
实现
适用于
Slice(ReadOnlySpan<NRange>)
- Source:
- Tensor.cs
从给定张量中形成切片
public:
virtual System::Numerics::Tensors::Tensor<T> ^ Slice(ReadOnlySpan<System::Buffers::NRange> start);
public System.Numerics.Tensors.Tensor<T> Slice (scoped ReadOnlySpan<System.Buffers.NRange> start);
abstract member Slice : ReadOnlySpan<System.Buffers.NRange> -> System.Numerics.Tensors.Tensor<'T>
override this.Slice : ReadOnlySpan<System.Buffers.NRange> -> System.Numerics.Tensors.Tensor<'T>
Public Function Slice (start As ReadOnlySpan(Of NRange)) As Tensor(Of T)
参数
- start
- ReadOnlySpan<NRange>
切片的范围
返回
Tensor<T> 作为提供的范围的副本。
实现
适用于
Slice(ReadOnlySpan<IntPtr>)
- Source:
- Tensor.cs
从给定张量中形成切片
public:
virtual System::Numerics::Tensors::Tensor<T> ^ Slice(ReadOnlySpan<IntPtr> start);
public System.Numerics.Tensors.Tensor<T> Slice (scoped ReadOnlySpan<IntPtr> start);
abstract member Slice : ReadOnlySpan<nativeint> -> System.Numerics.Tensors.Tensor<'T>
override this.Slice : ReadOnlySpan<nativeint> -> System.Numerics.Tensors.Tensor<'T>
Public Function Slice (start As ReadOnlySpan(Of IntPtr)) As Tensor(Of T)
参数
- start
-
ReadOnlySpan<nativeint>
切片的起始索引
返回
Tensor<T> 作为提供的范围的副本。