There was an error while loading. Please reload this page.
Exchanges two axes of m in place and returns m. Like pymath.transpose, but does not allocate a new tensor.
m
pymath.transpose
This function is located in the pymath module.
pymath
m = pymath.transpose_inplace(m [, axis1 [, axis2]])
Because the swap is performed inside m, the two exchanged axes must have the same size.
axis1
integer
1
0
axis2
2
axis1 == axis2
nil
0.0
local M = {{1, 2}, {3, 4}} pymath.transpose_inplace(M) -- M == {{1, 3}, {2, 4}}
Minimum PYTHA Version: V27
pymath, pymath.transpose