Tensor.TryBroadcastTo 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
TryBroadcastTo<T>(TensorSpan<T>, TensorSpan<T>) |
将数据从 |
TryBroadcastTo<T>(ReadOnlyTensorSpan<T>, TensorSpan<T>) |
将数据从 |
TryBroadcastTo<T>(Tensor<T>, TensorSpan<T>) |
将数据从 |
TryBroadcastTo<T>(TensorSpan<T>, TensorSpan<T>)
- Source:
- TensorExtensions.cs
将数据从 tensor
广播到与 destination
兼容的最小可广播形状,并将其存储在 destination
如果形状不兼容,则返回 false。
public:
generic <typename T>
[System::Runtime::CompilerServices::Extension]
static bool TryBroadcastTo(System::Numerics::Tensors::TensorSpan<T> % tensor, System::Numerics::Tensors::TensorSpan<T> % destination);
public static bool TryBroadcastTo<T> (this in System.Numerics.Tensors.TensorSpan<T> tensor, in System.Numerics.Tensors.TensorSpan<T> destination);
static member TryBroadcastTo : TensorSpan * TensorSpan -> bool
<Extension()>
Public Function TryBroadcastTo(Of T) (ByRef tensor As TensorSpan(Of T), ByRef destination As TensorSpan(Of T)) As Boolean
类型参数
- T
参数
- tensor
- TensorSpan<T>
输入 TensorSpan<T>。
- destination
- TensorSpan<T>
目标 TensorSpan<T>。
返回
如果形状不兼容,则 false
否则 true
。
适用于
TryBroadcastTo<T>(ReadOnlyTensorSpan<T>, TensorSpan<T>)
- Source:
- TensorExtensions.cs
将数据从 tensor
广播到与 destination
兼容的最小可广播形状,并将其存储在 destination
如果形状不兼容,则返回 false。
public:
generic <typename T>
[System::Runtime::CompilerServices::Extension]
static bool TryBroadcastTo(System::Numerics::Tensors::ReadOnlyTensorSpan<T> % tensor, System::Numerics::Tensors::TensorSpan<T> % destination);
public static bool TryBroadcastTo<T> (this in System.Numerics.Tensors.ReadOnlyTensorSpan<T> tensor, in System.Numerics.Tensors.TensorSpan<T> destination);
static member TryBroadcastTo : ReadOnlyTensorSpan * TensorSpan -> bool
<Extension()>
Public Function TryBroadcastTo(Of T) (ByRef tensor As ReadOnlyTensorSpan(Of T), ByRef destination As TensorSpan(Of T)) As Boolean
类型参数
- T
参数
- tensor
- ReadOnlyTensorSpan<T>
- destination
- TensorSpan<T>
目标 TensorSpan<T>。
返回
如果形状不兼容,则 false
否则 true
。
适用于
TryBroadcastTo<T>(Tensor<T>, TensorSpan<T>)
- Source:
- TensorExtensions.cs
将数据从 tensor
广播到与 destination
兼容的最小可广播形状,并将其存储在 destination
如果形状不兼容,则返回 false。
public:
generic <typename T>
[System::Runtime::CompilerServices::Extension]
static bool TryBroadcastTo(System::Numerics::Tensors::Tensor<T> ^ tensor, System::Numerics::Tensors::TensorSpan<T> % destination);
public static bool TryBroadcastTo<T> (this System.Numerics.Tensors.Tensor<T> tensor, in System.Numerics.Tensors.TensorSpan<T> destination);
static member TryBroadcastTo : System.Numerics.Tensors.Tensor<'T> * TensorSpan -> bool
<Extension()>
Public Function TryBroadcastTo(Of T) (tensor As Tensor(Of T), ByRef destination As TensorSpan(Of T)) As Boolean
类型参数
- T
参数
- destination
- TensorSpan<T>
目标 TensorSpan<T>。
返回
如果形状不兼容,则 false
否则 true
。