From 8ee837255ee0cb8a35cec19a64d0833b174f9b63 Mon Sep 17 00:00:00 2001 From: typhoonzero Date: Mon, 23 Apr 2018 11:25:59 +0800 Subject: [PATCH] fix send op handle local scope --- paddle/fluid/framework/details/send_op_handle.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/paddle/fluid/framework/details/send_op_handle.cc b/paddle/fluid/framework/details/send_op_handle.cc index 549b9d9abbe..84e1f28b61c 100644 --- a/paddle/fluid/framework/details/send_op_handle.cc +++ b/paddle/fluid/framework/details/send_op_handle.cc @@ -34,7 +34,9 @@ void SendOpHandle::RunImpl() { } in->generated_op_->Wait(dev_ctxes_[p]); } - this->RunAndRecordEvent([&] { op_->Run(*local_scope_, place_); }); + auto &tmp_scope = local_scope_->FindVar(kLocalExecScopeName)->Get(); + // auto &lod_tensor = tmp_scope->FindVar(var_name)->Get(); + this->RunAndRecordEvent([&] { op_->Run(*tmp_scope, place_); }); } std::string SendOpHandle::Name() const { return "send"; } -- GitLab