chainerx.moveaxis

chainerx.moveaxis(a, source, destination)

Move axes of an array to new positions.

Other axes remain in their original order.

Parameters
  • a (ndarray) – Input Array.

  • source (int or tuple of ints) – Original positions of the axes to move.

  • unique. (the original axes. These must also be) –

  • destintation (int or tuple of ints) – Destination positions for each of

  • unique.

Returns

Array with moved axes. This array is a view of the input array.

Return type

ndarray

Note

  • During backpropagation, this function propagates the gradients of the output arrays to the input array a.

See also

numpy.moveaxis()