Home
last modified time | relevance | path

Searched refs:server_def (Results 1 – 25 of 48) sorted by relevance

12

/external/tensorflow/tensorflow/core/distributed_runtime/
Dsession_mgr_test.cc58 [](const ServerDef& server_def, WorkerCacheInterface** worker_cache) { in __anond6a406250102() argument
66 ServerDef server_def; in TEST_F() local
67 server_def.set_job_name("worker"); in TEST_F()
68 server_def.set_task_index(3); in TEST_F()
71 TF_EXPECT_OK(mgr_.CreateSession(session_handle, server_def, true)); in TEST_F()
80 ServerDef server_def; in TEST_F() local
81 server_def.set_job_name("worker"); in TEST_F()
82 server_def.set_task_index(3); in TEST_F()
83 auto job = server_def.mutable_cluster()->add_job(); in TEST_F()
94 TF_EXPECT_OK(mgr_.CreateSession(session_handle, server_def, in TEST_F()
[all …]
Dserver_lib_test.cc25 bool AcceptsOptions(const ServerDef& server_def) override { in AcceptsOptions() argument
26 return server_def.protocol() == "test_protocol"; in AcceptsOptions()
29 Status NewServer(const ServerDef& server_def, const Options& options, in NewServer() argument
37 ServerDef server_def; in TEST() local
38 server_def.set_protocol("test_protocol"); in TEST()
40 TF_EXPECT_OK(NewServer(server_def, &server)); in TEST()
44 ServerDef server_def; in TEST() local
45 server_def.set_protocol("fake_protocol"); in TEST()
47 Status s = NewServer(server_def, &server); in TEST()
Dserver_lib.cc49 Status ServerFactory::GetFactory(const ServerDef& server_def, in GetFactory() argument
53 if (server_factory.second->AcceptsOptions(server_def)) { in GetFactory()
66 server_def.DebugString(), "\nThe available server factories are: [ ", in GetFactory()
72 Status NewServer(const ServerDef& server_def, in NewServer() argument
75 TF_RETURN_IF_ERROR(ServerFactory::GetFactory(server_def, &factory)); in NewServer()
76 return factory->NewServer(server_def, ServerFactory::Options(), out_server); in NewServer()
81 Status NewServerWithOptions(const ServerDef& server_def, in NewServerWithOptions() argument
85 TF_RETURN_IF_ERROR(ServerFactory::GetFactory(server_def, &factory)); in NewServerWithOptions()
86 return factory->NewServer(server_def, options, out_server); in NewServerWithOptions()
Dmaster_env.h48 WorkerCacheFactoryOptions(const ServerDef& server_def) { in WorkerCacheFactoryOptions()
49 if (server_def.has_cluster() && !server_def.job_name().empty()) { in WorkerCacheFactoryOptions()
50 cluster_def = &server_def.cluster(); in WorkerCacheFactoryOptions()
51 job_name = &server_def.job_name(); in WorkerCacheFactoryOptions()
52 task_index = server_def.task_index(); in WorkerCacheFactoryOptions()
53 protocol = &server_def.protocol(); in WorkerCacheFactoryOptions()
Dsession_mgr.cc49 string SessionMgr::WorkerNameFromServerDef(const ServerDef& server_def) { in WorkerNameFromServerDef() argument
50 return strings::StrCat("/job:", server_def.job_name(), in WorkerNameFromServerDef()
51 "/replica:0/task:", server_def.task_index()); in WorkerNameFromServerDef()
55 const ServerDef& server_def, in CreateSession() argument
57 return CreateSession(session, server_def, {}, isolate_session_state); in CreateSession()
61 const string& session, const ServerDef& server_def, in CreateSession() argument
65 return CreateSession(session, server_def, cluster_device_attributes, in CreateSession()
71 const string& session, const ServerDef& server_def, in CreateSession() argument
107 if (server_def.cluster().job().empty()) { in CreateSession()
111 TF_RETURN_IF_ERROR(worker_cache_factory_(server_def, &worker_cache)); in CreateSession()
[all …]
Dserver_lib.h75 virtual Status NewServer(const ServerDef& server_def, const Options& options,
80 virtual bool AcceptsOptions(const ServerDef& server_def) = 0;
93 static Status GetFactory(const ServerDef& server_def,
99 Status NewServer(const ServerDef& server_def,
101 Status NewServerWithOptions(const ServerDef& server_def,
Dsession_mgr.h50 Status CreateSession(const string& session, const ServerDef& server_def,
53 const string& session, const ServerDef& server_def,
65 const string& session, const ServerDef& server_def,
73 Status UpdateSession(const string& session, const ServerDef& server_def,
85 static string WorkerNameFromServerDef(const ServerDef& server_def);
/external/tensorflow/tensorflow/c/eager/parallel_device/
Dparallel_device_remote_test.cc29 tensorflow::ServerDef server_def; in GetServerDef() local
30 server_def.set_protocol("grpc"); in GetServerDef()
31 server_def.set_job_name(job_name); in GetServerDef()
32 server_def.set_task_index(0); in GetServerDef()
33 tensorflow::ClusterDef* cluster_def = server_def.mutable_cluster(); in GetServerDef()
41 return server_def; in GetServerDef()
54 tensorflow::ServerDef server_def = GetServerDef("worker", 3); in TEST() local
57 std::string serialized = server_def.SerializeAsString(); in TEST()
59 server_def.set_task_index(1); in TEST()
62 server_def, tensorflow::Env::Default(), &worker_server1) in TEST()
[all …]
/external/tensorflow/tensorflow/c/eager/
Dc_api_cluster_test.cc33 void ReplaceTaskInServerDef(tensorflow::ServerDef* server_def, int task_index) { in ReplaceTaskInServerDef() argument
34 tensorflow::JobDef* job_def = server_def->mutable_cluster()->mutable_job(0); in ReplaceTaskInServerDef()
108 tensorflow::ServerDef server_def = GetServerDef(2); in TestRemoteExecuteChangeServerDef() local
111 string serialized = server_def.SerializeAsString(); in TestRemoteExecuteChangeServerDef()
113 server_def.set_task_index(1); in TestRemoteExecuteChangeServerDef()
117 server_def, tensorflow::Env::Default(), &worker_server) in TestRemoteExecuteChangeServerDef()
202 tensorflow::ServerDef server_def = GetServerDef(2); in TestRemoteExecuteUpdateServerDef() local
204 string serialized = server_def.SerializeAsString(); in TestRemoteExecuteUpdateServerDef()
206 server_def.set_task_index(1); in TestRemoteExecuteUpdateServerDef()
209 server_def, tensorflow::Env::Default(), &worker_server) in TestRemoteExecuteUpdateServerDef()
[all …]
Dc_api_distributed_test.cc125 tensorflow::ServerDef server_def = GetServerDef(3); in TestFunctionWithPackedInput() local
128 string serialized = server_def.SerializeAsString(); in TestFunctionWithPackedInput()
130 server_def.set_task_index(1); in TestFunctionWithPackedInput()
133 server_def, tensorflow::Env::Default(), &worker_server1) in TestFunctionWithPackedInput()
137 server_def.set_task_index(2); in TestFunctionWithPackedInput()
140 server_def, tensorflow::Env::Default(), &worker_server2) in TestFunctionWithPackedInput()
349 tensorflow::ServerDef server_def = GetServerDef(3); in TEST() local
351 string serialized = server_def.SerializeAsString(); in TEST()
353 server_def.set_task_index(1); in TEST()
356 server_def, tensorflow::Env::Default(), &worker_server1) in TEST()
[all …]
Dc_api_remote_test_util.cc74 tensorflow::ServerDef server_def = GetServerDef(3); in TestRemoteExecuteSilentCopies() local
77 string serialized = server_def.SerializeAsString(); in TestRemoteExecuteSilentCopies()
79 server_def.set_task_index(1); in TestRemoteExecuteSilentCopies()
82 server_def, tensorflow::Env::Default(), &worker_server1) in TestRemoteExecuteSilentCopies()
86 server_def.set_task_index(2); in TestRemoteExecuteSilentCopies()
89 server_def, tensorflow::Env::Default(), &worker_server2) in TestRemoteExecuteSilentCopies()
Dc_api_remote_test.cc41 tensorflow::ServerDef server_def = GetServerDef(2); in TestRemoteExecute() local
44 string serialized = server_def.SerializeAsString(); in TestRemoteExecute()
46 server_def.set_task_index(1); in TestRemoteExecute()
50 server_def, tensorflow::Env::Default(), &worker_server) in TestRemoteExecute()
Dimmediate_execution_distributed_manager.h35 virtual Status SetOrUpdateServerDef(const ServerDef& server_def,
43 virtual Status EnableCollectiveOps(const ServerDef& server_def) = 0;
/external/tensorflow/tensorflow/core/distributed_runtime/rpc/
Dgrpc_server_lib.cc94 GrpcServer::GrpcServer(const ServerDef& server_def, Env* env) in GrpcServer() argument
95 : env_(env), state_(NEW), server_def_(server_def) {} in GrpcServer()
129 Status GrpcServer::GetHostAndPort(const ServerDef& server_def, in GetHostAndPort() argument
133 for (const auto& job : server_def.cluster().job()) { in GetHostAndPort()
134 if (job.name() == server_def.job_name()) { in GetHostAndPort()
135 auto iter = job.tasks().find(server_def.task_index()); in GetHostAndPort()
137 return errors::Internal("Task ", server_def.task_index(), in GetHostAndPort()
139 server_def.job_name(), "\""); in GetHostAndPort()
142 if (server_def.port() != 0) { in GetHostAndPort()
143 *port = server_def.port(); in GetHostAndPort()
[all …]
Dgrpc_server_lib.h77 GrpcServer(const ServerDef& server_def, Env* env);
78 GrpcServer(const ServerDef& server_def, DeviceMgr* local_device_mgr,
85 static Status Create(const ServerDef& server_def, Env* env,
87 static Status Create(const ServerDef& server_def, Env* env,
90 static Status Create(const ServerDef& server_def, Env* env,
112 Status UpdateServerDef(const ServerDef& server_def);
115 virtual Status GetHostAndPort(const ServerDef& server_def, string* host_name,
121 const ServerDef& server_def) const;
142 const ServerDef& server_def() const { return server_def_; } in server_def() function
Dgrpc_tensorflow_server.cc115 tensorflow::ServerDef server_def; in main() local
117 task_index, &server_def); in main()
124 TF_QCHECK_OK(tensorflow::NewServer(server_def, &server)); in main()
/external/tensorflow/tensorflow/core/common_runtime/eager/
Dcontext_distributed_manager.cc54 const tensorflow::ServerDef& server_def) { in AreLocalDevicesCompatible() argument
55 if (server_def.job_name() != context->HostCPU()->parsed_name().job) { in AreLocalDevicesCompatible()
58 return server_def.default_session_config().SerializeAsString() == in AreLocalDevicesCompatible()
177 tensorflow::uint64 context_view_id, const tensorflow::ServerDef& server_def, in GetReplacedFromExistingWorkers() argument
218 int keep_alive_secs, const tensorflow::ServerDef& server_def, in CreateRemoteContexts() argument
251 *request.mutable_server_def() = server_def; in CreateRemoteContexts()
255 server_def.default_session_config()); in CreateRemoteContexts()
297 tensorflow::uint64 context_view_id, const tensorflow::ServerDef& server_def, in UpdateRemoteContexts() argument
368 *request.mutable_server_def() = server_def; in UpdateRemoteContexts()
372 server_def.default_session_config()); in UpdateRemoteContexts()
[all …]
Dcontext_distributed_manager.h35 Status SetOrUpdateServerDef(const ServerDef& server_def, bool reset_context,
38 Status EnableCollectiveOps(const ServerDef& server_def) override;
/external/tensorflow/tensorflow/python/eager/
Dremote_cluster_test.py57 server_def = tensorflow_server_pb2.ServerDef(
63 return server_def
134 server_def=get_server_def(
153 context.update_server_def(server_def=self.server_def_s1_s2_s3)
179 context.update_server_def(server_def=self.server_def_s1)
199 context.update_server_def(server_def=self.server_def_s1_s3)
217 context.update_server_def(server_def=self.server_def_s1_s2_s3)
242 context.update_server_def(server_def=self.server_def_s1)
270 context.update_server_def(server_def=self.server_def_s1_s2_s3)
275 context.update_server_def(server_def=self.server_def_s1_s2)
[all …]
Dremote_execution_test.py57 server_def = tensorflow_server_pb2.ServerDef(
63 return server_def
80 server_def=get_server_def(
181 server_def=get_server_def(
196 server_def=get_server_def(
Dremote.py172 server_def = ServerDef(
181 context.set_server_def(server_def)
183 context.update_server_def(server_def)
/external/tensorflow/tensorflow/python/training/
Dserver_lib.py57 server_def = tensorflow_server_pb2.ServerDef()
59 server_def.MergeFrom(server_or_cluster_def)
61 server_def.job_name = job_name
63 server_def.task_index = task_index
65 server_def.protocol = protocol
67 server_def.default_session_config.MergeFrom(config)
88 server_def = tensorflow_server_pb2.ServerDef(
94 server_def.default_session_config.MergeFrom(config)
95 return server_def
192 def server_def(self): member in Server
Dserver_lib_test.py189 self.assertEqual(0.1, server.server_def.default_session_config.gpu_options.
197 server_def = tensorflow_server_pb2.ServerDef(
202 server = server_lib.Server(server_def, config=config, start=False)
203 self.assertEqual(0.1, server.server_def.default_session_config.gpu_options.
399 server_def = tensorflow_server_pb2.ServerDef(
407 """, server_def)
417 server_def = tensorflow_server_pb2.ServerDef(
426 """, server_def)
437 server_def = tensorflow_server_pb2.ServerDef(
449 """, server_def)
[all …]
/external/tensorflow/tensorflow/python/debug/lib/
Dgrpc_tensorflow_server.py93 server_def = tensorflow_server_pb2.ServerDef(protocol="grpc")
96 parse_cluster_spec(FLAGS.cluster_spec, server_def.cluster, FLAGS.verbose)
101 server_def.job_name = FLAGS.job_name
106 server_def.task_index = FLAGS.task_id
112 server = server_lib.Server(server_def, config=config)
/external/tensorflow/tensorflow/java/src/main/native/
Dserver_jni.cc38 JNIEnv* env, jclass clazz, jbyteArray server_def) { in Java_org_tensorflow_Server_allocate() argument
41 jbyte* server_def_ptr = env->GetByteArrayElements(server_def, nullptr); in Java_org_tensorflow_Server_allocate()
44 server_def_ptr, static_cast<size_t>(env->GetArrayLength(server_def)), in Java_org_tensorflow_Server_allocate()
47 env->ReleaseByteArrayElements(server_def, server_def_ptr, JNI_ABORT); in Java_org_tensorflow_Server_allocate()

12