|
|
|
@ -21,7 +21,7 @@
|
|
|
|
|
#include "paddle/fluid/framework/lod_tensor.h"
|
|
|
|
|
#include "paddle/fluid/framework/scope.h"
|
|
|
|
|
|
|
|
|
|
DECLARE_int32(grpc_deadline);
|
|
|
|
|
DECLARE_int32(rpc_deadline);
|
|
|
|
|
|
|
|
|
|
namespace paddle {
|
|
|
|
|
namespace operators {
|
|
|
|
@ -35,26 +35,26 @@ class RPCClient {
|
|
|
|
|
const platform::DeviceContext& ctx,
|
|
|
|
|
const framework::Scope& scope,
|
|
|
|
|
const std::string& var_name,
|
|
|
|
|
int64_t time_out = FLAGS_grpc_deadline) = 0;
|
|
|
|
|
int64_t time_out = FLAGS_rpc_deadline) = 0;
|
|
|
|
|
|
|
|
|
|
virtual bool AsyncGetVar(const std::string& ep,
|
|
|
|
|
const platform::DeviceContext& ctx,
|
|
|
|
|
const framework::Scope& scope,
|
|
|
|
|
const std::string& var_name,
|
|
|
|
|
int64_t time_out = FLAGS_grpc_deadline) = 0;
|
|
|
|
|
int64_t time_out = FLAGS_rpc_deadline) = 0;
|
|
|
|
|
|
|
|
|
|
virtual bool AsyncPrefetchVar(const std::string& ep,
|
|
|
|
|
const platform::DeviceContext& ctx,
|
|
|
|
|
const framework::Scope& scope,
|
|
|
|
|
const std::string& in_var_name,
|
|
|
|
|
const std::string& out_var_name,
|
|
|
|
|
int64_t time_out = FLAGS_grpc_deadline) = 0;
|
|
|
|
|
int64_t time_out = FLAGS_rpc_deadline) = 0;
|
|
|
|
|
|
|
|
|
|
virtual void AsyncSendBatchBarrier(
|
|
|
|
|
const std::string& ep, int64_t time_out = FLAGS_grpc_deadline) = 0;
|
|
|
|
|
virtual void AsyncSendBatchBarrier(const std::string& ep,
|
|
|
|
|
int64_t time_out = FLAGS_rpc_deadline) = 0;
|
|
|
|
|
|
|
|
|
|
virtual void AsyncSendFetchBarrier(
|
|
|
|
|
const std::string& ep, int64_t time_out = FLAGS_grpc_deadline) = 0;
|
|
|
|
|
virtual void AsyncSendFetchBarrier(const std::string& ep,
|
|
|
|
|
int64_t time_out = FLAGS_rpc_deadline) = 0;
|
|
|
|
|
|
|
|
|
|
// SendComplete tells all the server that current trainer have no more data
|
|
|
|
|
// to train, so that the pserver can reduce it's barrier count, and continue
|
|
|
|
|