Jazyk

Tensor.PermuteDimensions<T> Metoda

Definice

Prohodí rozměry tensor tensoru podle parametru dimensions . Pokud tensor je 1D tensor, vrátí tensorse . V opačném případě vytvoří novou Tensor<T> s novým řazením osy přidělením nové paměti.

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)

Parametry typu

T

Parametry

tensor
Tensor<T>

Vstupní Tensor<T>

dimensions
ReadOnlySpan<Int32>

ReadOnlySpan<T> s novým řazením os.

Návraty

Platí pro