diff options
Diffstat (limited to 'tensorflow/python/ops/embedding_ops.py')
-rw-r--r-- | tensorflow/python/ops/embedding_ops.py | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/tensorflow/python/ops/embedding_ops.py b/tensorflow/python/ops/embedding_ops.py index f891b94e2e..aae65b194b 100644 --- a/tensorflow/python/ops/embedding_ops.py +++ b/tensorflow/python/ops/embedding_ops.py @@ -63,10 +63,11 @@ def embedding_lookup(params, ids, partition_strategy="mod", name=None, tensor. The returned tensor has shape `shape(ids) + shape(params)[1:]`. Args: - params: A list of tensors with the same type and which can be concatenated - along dimension 0. Alternatively, a `PartitionedVariable`, created by - partitioning along dimension 0. Each element must be appropriately sized - for the given `partition_strategy`. + params: A single tensor representing the complete embedding tensor, + or a list of P tensors all of same shape except for the first dimension, + representing sharded embedding tensors. Alternatively, a + `PartitionedVariable`, created by partitioning along dimension 0. Each + element must be appropriately sized for the given `partition_strategy`. ids: A `Tensor` with type `int32` or `int64` containing the ids to be looked up in `params`. partition_strategy: A string specifying the partitioning strategy, relevant @@ -217,7 +218,8 @@ def embedding_lookup_sparse(params, sp_ids, sp_weights, params: A single tensor representing the complete embedding tensor, or a list of P tensors all of same shape except for the first dimension, representing sharded embedding tensors. Alternatively, a - `PartitionedVariable`, created by partitioning along dimension 0. + `PartitionedVariable`, created by partitioning along dimension 0. Each + element must be appropriately sized for the given `partition_strategy`. sp_ids: N x M SparseTensor of int64 ids (typically from FeatureValueToId), where N is typically batch size and M is arbitrary. sp_weights: either a SparseTensor of float / double weights, or None to |