From d613b0cfbb06ff9e022fab37382f866976d69218 Mon Sep 17 00:00:00 2001 From: lvliang Date: Thu, 27 Aug 2020 12:59:44 +0800 Subject: [PATCH] fixed-bug-of-embedding-look-up-run-failed-in-pynative --- mindspore/ccsrc/pipeline/pynative/pynative_execute.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mindspore/ccsrc/pipeline/pynative/pynative_execute.cc b/mindspore/ccsrc/pipeline/pynative/pynative_execute.cc index 6407ca986..03399586c 100644 --- a/mindspore/ccsrc/pipeline/pynative/pynative_execute.cc +++ b/mindspore/ccsrc/pipeline/pynative/pynative_execute.cc @@ -522,6 +522,9 @@ void ConstructInputTensor(const OpExecInfoPtr &op_run_info, std::vector *te opt::ConstInputToAttrInfoRegister reg; bool reg_exist = opt::ConstInputToAttrInfoRegistry::Instance().GetRegisterByOpName(op_run_info->op_name, ®); + if (op_run_info->op_name == prim::kPrimEmbeddingLookup->name()) { + reg_exist = false; + } op_prim->BeginRecordAddAttr(); size_t input_num = op_run_info->op_inputs.size(); -- GitLab