# tf.raw_ops.RandomShuffle

<br />

Randomly shuffles a tensor along its first dimension.

#### View aliases


**Compat aliases for migration**

See
[Migration guide](https://www.tensorflow.org/guide/migrate) for
more details.

[`tf.compat.v1.raw_ops.RandomShuffle`](https://www.tensorflow.org/api_docs/python/tf/raw_ops/RandomShuffle)

<br />

    tf.raw_ops.RandomShuffle(
        value, seed=0, seed2=0, name=None
    )

The tensor is shuffled along dimension 0, such that each `value[j]` is mapped
to one and only one `output[i]`. For example, a mapping that might occur for a
3x2 tensor is:

    [[1, 2],       [[5, 6],
     [3, 4],  ==>   [1, 2],
     [5, 6]]        [3, 4]]

<br />

<br />

<br />

| ## Args ||
|---|---|
| `value` | A `Tensor`. The tensor to be shuffled. |
| `seed` | An optional `int`. Defaults to `0`. If either `seed` or `seed2` are set to be non-zero, the random number generator is seeded by the given seed. Otherwise, it is seeded by a random seed. |
| `seed2` | An optional `int`. Defaults to `0`. A second seed to avoid seed collision. |
| `name` | A name for the operation (optional). |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| A `Tensor`. Has the same type as `value`. ||

<br />