This is an automated email from the ASF dual-hosted git repository.
haibin pushed a commit to branch doc-patch
in repository https://gitbox.apache.org/repos/asf/incubator-mxnet.git
The following commit(s) were added to refs/heads/doc-patch by this push:
new a811563 Update indexing_op.cc
a811563 is described below
commit a8115630e79120e1fb83b9bb9e5e3c3ff4e05c72
Author: Haibin Lin <[email protected]>
AuthorDate: Mon Aug 12 16:38:49 2019 -0700
Update indexing_op.cc
---
src/operator/tensor/indexing_op.cc | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/operator/tensor/indexing_op.cc
b/src/operator/tensor/indexing_op.cc
index ad4e54d..8a5030e 100644
--- a/src/operator/tensor/indexing_op.cc
+++ b/src/operator/tensor/indexing_op.cc
@@ -481,8 +481,9 @@ All the input values should be integers in the range [0,
input_dim).
If the input_dim is ip0 and output_dim is op0, then shape of the embedding
weight matrix must be
(ip0, op0).
-By default, if any index mentioned is too large, it is replaced by the index
that addresses
-the last vector in an embedding matrix.
+When "sparse_grad" is False, if any index mentioned is too large, it is
replaced by the index that
+addresses the last vector in an embedding matrix.
+When "sparse_grad" is True, an error will be raised if invalid indices are
found.
Examples::