Permute a tensorflow Tensor

Try this:

# 't' is [0, 1, 2, 3, 4]
tf.roll(t, shift=-1, axis=0) ==> [1, 2, 3, 4, 0]

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top