There was an error while loading. Please reload this page.
Returns a new tensor (rank ≥ 2) with two axes exchanged. With the default axes this is the ordinary matrix transpose.
This function is located in the pymath module. See pymath for the tensor representation.
pymath
result = pymath.transpose(m [, axis1 [, axis2]])
m
axis1
integer
1
0
axis2
2
result
axis1 == axis2
pymath.transpose_inplace
local A = {{1, 2, 3}, {4, 5, 6}} -- 2 x 3 local T = pymath.transpose(A) -- T == {{1, 4}, {2, 5}, {3, 6}} -- 3 x 2
Minimum PYTHA Version: V27
pymath, pymath.transpose_inplace, pymath.dot