From 5c36eb8b6962446e95840f775f87308d0df32ff6 Mon Sep 17 00:00:00 2001 From: Qiao Longfei Date: Wed, 6 Feb 2019 20:36:31 +0800 Subject: [PATCH] fix build --- paddle/fluid/operators/distributed/parameter_send.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/paddle/fluid/operators/distributed/parameter_send.cc b/paddle/fluid/operators/distributed/parameter_send.cc index 47ca42c7905..fd97926623d 100644 --- a/paddle/fluid/operators/distributed/parameter_send.cc +++ b/paddle/fluid/operators/distributed/parameter_send.cc @@ -75,8 +75,8 @@ void ParameterSend::operator()(const std::string &var_name, // create output var in local scope size_t row_offset = 0; for (auto i = 0; i < out_num; ++i) { - auto *out = - local_scope->Var(send_varnames[i])->GetMutable(); + framework::Tensor *out = local_scope->Var(send_varnames[i]) + ->GetMutable(); *out = send_tensor.Slice(row_offset, row_offset + outs_dims[i][0]); row_offset += outs_dims[i][0]; } @@ -161,7 +161,8 @@ void ParameterSend::operator()(const std::string &var_name, } } - if (sync) { + // note!! only support sync send now + if (true || sync) { for (size_t i = 0; i < rets.size(); i++) { PADDLE_ENFORCE(rets[i]->Wait(), "internal error in RPCClient"); } -- GitLab