Tensor.PermuteDimensions<T> メソッド

定義

tensor パラメーターに従って、dimensions テンソルの寸法を入れ替えます。 tensorが 1D テンソルの場合、tensorが返されます。 それ以外の場合は、新しいメモリを割り当てることによって、新しい軸の順序を持つ新しい Tensor<T> が作成されます。

public:
generic <typename T>
[System::Runtime::CompilerServices::Extension]
 static System::Numerics::Tensors::Tensor<T> ^ PermuteDimensions(System::Numerics::Tensors::Tensor<T> ^ tensor, ReadOnlySpan<int> dimensions);
public static System.Numerics.Tensors.Tensor<T> PermuteDimensions<T>(this System.Numerics.Tensors.Tensor<T> tensor, ReadOnlySpan<int> dimensions);
static member PermuteDimensions : System.Numerics.Tensors.Tensor<'T> * ReadOnlySpan<int> -> System.Numerics.Tensors.Tensor<'T>
<Extension()>
Public Function PermuteDimensions(Of T) (tensor As Tensor(Of T), dimensions As ReadOnlySpan(Of Integer)) As Tensor(Of T)

型パラメーター

T

パラメーター

tensor
Tensor<T>

入力 Tensor<T>

dimensions
ReadOnlySpan<Int32>

ReadOnlySpan<T> 新しい軸の順序付けを使用します。

返品

適用対象