沿第一個維度隨機打亂張量。
用法
tf.raw_ops.RandomShuffle(
value, seed=0, seed2=0, name=None
)
參數
-
value
一個Tensor
。要洗牌的張量。 -
seed
可選的int
。默認為0
。如果seed
或seed2
設置為非零,則隨機數生成器由給定種子播種。否則,它由隨機種子播種。 -
seed2
可選的int
。默認為0
。避免種子碰撞的第二個種子。 -
name
操作的名稱(可選)。
返回
-
一個
Tensor
。具有與value
相同的類型。
張量沿維度 0 打亂,使得每個 value[j]
映射到一個且隻有一個 output[i]
。例如,一個 3x2 張量可能出現的映射是:
[[1, 2], [[5, 6],
[3, 4], ==> [1, 2],
[5, 6]] [3, 4]]
相關用法
- Python tf.raw_ops.Range用法及代碼示例
- Python tf.raw_ops.Rank用法及代碼示例
- Python tf.raw_ops.RaggedGather用法及代碼示例
- Python tf.raw_ops.RaggedCross用法及代碼示例
- Python tf.raw_ops.RaggedRange用法及代碼示例
- Python tf.raw_ops.ResourceScatterNdSub用法及代碼示例
- Python tf.raw_ops.ReadVariableXlaSplitND用法及代碼示例
- Python tf.raw_ops.ResourceScatterMul用法及代碼示例
- Python tf.raw_ops.ReduceJoin用法及代碼示例
- Python tf.raw_ops.RGBToHSV用法及代碼示例
- Python tf.raw_ops.ResourceScatterAdd用法及代碼示例
- Python tf.raw_ops.ResourceScatterMax用法及代碼示例
- Python tf.raw_ops.ResourceScatterMin用法及代碼示例
- Python tf.raw_ops.Real用法及代碼示例
- Python tf.raw_ops.Rint用法及代碼示例
- Python tf.raw_ops.Relu用法及代碼示例
- Python tf.raw_ops.ReverseV2用法及代碼示例
- Python tf.raw_ops.ResourceGather用法及代碼示例
- Python tf.raw_ops.Reverse用法及代碼示例
- Python tf.raw_ops.Reshape用法及代碼示例
注:本文由純淨天空篩選整理自tensorflow.org大神的英文原創作品 tf.raw_ops.RandomShuffle。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。