tf.keras.ops.swapaxes

Interchange two axes of a tensor.

Main aliases

tf.keras.ops.numpy.swapaxes

x Input tensor.
axis1 First axis.
axis2 Second axis.

A tensor with the axes swapped.