From 1bc093a70a6478df33dc6b5b0fa7e8e5158d860d Mon Sep 17 00:00:00 2001 From: seiriosPlus Date: Thu, 27 Aug 2020 20:36:20 +0800 Subject: [PATCH] add nn.Embedding --- python/paddle/nn/functional/input.py | 1 + 1 file changed, 1 insertion(+) diff --git a/python/paddle/nn/functional/input.py b/python/paddle/nn/functional/input.py index 055b2341a4ee6..832a2fdf950a3 100644 --- a/python/paddle/nn/functional/input.py +++ b/python/paddle/nn/functional/input.py @@ -177,6 +177,7 @@ def embedding(x, weight, padding_idx=None, sparse=False, name=None): initializer=fluid.initializer.NumpyArrayInitializer(weight_data), trainable=True) emb = paddle.nn.functional.embedding(x=data, weight=weight, sparse=True, name="sparse_embedding") + """ if in_dygraph_mode(): return core.ops.lookup_table_v2(