Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def __init__(self, channel):
self.UnaryUnary = UnaryUnaryMethod(
channel,
'/ping.PingService/UnaryUnary',
None,
None,
)
client_master_pb2.HeartBeatReq,
client_master_pb2.HeartBeatResp,
)
self.Clock = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.AngelCleintMaster/Clock',
client_master_pb2.ClockReq,
client_master_pb2.ClockResp,
)
self.GetClockMap = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.AngelCleintMaster/GetClockMap',
client_master_pb2.GetClockMapReq,
client_master_pb2.GetClockMapResp,
)
self.GetGlobalBatchSize = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.AngelCleintMaster/GetGlobalBatchSize',
common_pb2.VoidReq,
client_master_pb2.GetGlobalBatchResp,
)
self.CompleteTask = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.AngelCleintMaster/CompleteTask',
common_pb2.CompleteTaskReq,
common_pb2.VoidResp,
)
client_worker_pb2.TensorLike,
common_pb2.VoidResp,
)
self.Load = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.ClientWorker/Load',
client_worker_pb2.LoadTensorLike,
common_pb2.VoidResp,
)
self.Save = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.ClientWorker/Save',
client_worker_pb2.SaveTensorLike,
common_pb2.VoidResp,
)
self.Pull = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.ClientWorker/Pull',
client_worker_pb2.PullRequest,
client_worker_pb2.PullResponse,
)
self.Push = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.ClientWorker/Push',
client_worker_pb2.PushRequest,
common_pb2.VoidResp,
)
self.Release = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.ClientWorker/Release',
client_worker_pb2.TensorLike,
common_pb2.VoidResp,
client_worker_pb2.TensorLike,
common_pb2.VoidResp,
)
self.Update = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.ClientWorker/Update',
client_worker_pb2.TensorLike,
common_pb2.VoidResp,
)
self.Sync = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.ClientWorker/Sync',
client_worker_pb2.SyncRequest,
common_pb2.VoidResp,
)
self.CompleteTask = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.ClientWorker/CompleteTask',
common_pb2.CompleteTaskReq,
common_pb2.VoidResp,
)
def __init__(self, channel: grpclib.client.Channel) -> None:
self.RegisterWorker = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.AngelCleintMaster/RegisterWorker',
client_master_pb2.RegisterWorkerReq,
client_master_pb2.RegisterWorkerResp,
)
self.RegisterTask = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.AngelCleintMaster/RegisterTask',
client_master_pb2.RegisterTaskReq,
client_master_pb2.RegisterTaskResp,
)
self.SetAngelLocation = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.AngelCleintMaster/SetAngelLocation',
client_master_pb2.SetAngelLocationReq,
common_pb2.VoidResp,
)
self.GetAngelLocation = grpclib.client.UnaryUnaryMethod(
channel,
'/ClientMaster.AngelCleintMaster/GetAngelLocation',
common_pb2.VoidReq,
client_master_pb2.GetAngelLocationResp,
def __init__(self, channel: grpclib.client.Channel) -> None:
self.SayHello = grpclib.client.UnaryUnaryMethod(
channel,
'/helloworld.Greeter/SayHello',
helloworld.helloworld_pb2.HelloRequest,
helloworld.helloworld_pb2.HelloReply,
)
def __init__(self, channel: grpclib.client.Channel) -> None:
self.UnaryUnaryGreeting = grpclib.client.UnaryUnaryMethod(
channel,
'/helloworld.Greeter/UnaryUnaryGreeting',
streaming.helloworld_pb2.HelloRequest,
streaming.helloworld_pb2.HelloReply,
)
self.UnaryStreamGreeting = grpclib.client.UnaryStreamMethod(
channel,
'/helloworld.Greeter/UnaryStreamGreeting',
streaming.helloworld_pb2.HelloRequest,
streaming.helloworld_pb2.HelloReply,
)
self.StreamUnaryGreeting = grpclib.client.StreamUnaryMethod(
channel,
'/helloworld.Greeter/StreamUnaryGreeting',
streaming.helloworld_pb2.HelloRequest,
streaming.helloworld_pb2.HelloReply,
def __init__(self, channel: grpclib.client.Channel) -> None:
self.Rollout = grpclib.client.UnaryUnaryMethod(
channel,
'/DotaOptimizer/Rollout',
protos.DotaOptimizer_pb2.RolloutData,
protos.DotaOptimizer_pb2.Empty2,
)
self.GetWeights = grpclib.client.UnaryUnaryMethod(
channel,
'/DotaOptimizer/GetWeights',
protos.DotaOptimizer_pb2.WeightQuery,
protos.DotaOptimizer_pb2.Weights,
)