Browse Source

Upgrade module

- Change build paths
- Migate to new proto generator
Alexey Edelev 3 years ago
parent
commit
7591e67bc7
4 changed files with 273 additions and 95 deletions
  1. 246 62
      cluster/cluster.pb.go
  2. 2 6
      go.mod
  3. 22 22
      go.sum
  4. 3 5
      updateproto.sh

+ 246 - 62
cluster/cluster.pb.go

@@ -24,7 +24,7 @@ var _ = math.Inf
 // proto package needs to be updated.
 const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
 
-type Unit struct {
+type UnitInfo struct {
 	Url                  string   `protobuf:"bytes,1,opt,name=url,proto3" json:"url,omitempty"`
 	AvailableThreads     int32    `protobuf:"zigzag32,2,opt,name=availableThreads,proto3" json:"availableThreads,omitempty"`
 	XXX_NoUnkeyedLiteral struct{} `json:"-"`
@@ -32,104 +32,216 @@ type Unit struct {
 	XXX_sizecache        int32    `json:"-"`
 }
 
-func (m *Unit) Reset()         { *m = Unit{} }
-func (m *Unit) String() string { return proto.CompactTextString(m) }
-func (*Unit) ProtoMessage()    {}
-func (*Unit) Descriptor() ([]byte, []int) {
+func (m *UnitInfo) Reset()         { *m = UnitInfo{} }
+func (m *UnitInfo) String() string { return proto.CompactTextString(m) }
+func (*UnitInfo) ProtoMessage()    {}
+func (*UnitInfo) Descriptor() ([]byte, []int) {
 	return fileDescriptor_3cfb3b8ec240c376, []int{0}
 }
 
-func (m *Unit) XXX_Unmarshal(b []byte) error {
-	return xxx_messageInfo_Unit.Unmarshal(m, b)
+func (m *UnitInfo) XXX_Unmarshal(b []byte) error {
+	return xxx_messageInfo_UnitInfo.Unmarshal(m, b)
 }
-func (m *Unit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
-	return xxx_messageInfo_Unit.Marshal(b, m, deterministic)
+func (m *UnitInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+	return xxx_messageInfo_UnitInfo.Marshal(b, m, deterministic)
 }
-func (m *Unit) XXX_Merge(src proto.Message) {
-	xxx_messageInfo_Unit.Merge(m, src)
+func (m *UnitInfo) XXX_Merge(src proto.Message) {
+	xxx_messageInfo_UnitInfo.Merge(m, src)
 }
-func (m *Unit) XXX_Size() int {
-	return xxx_messageInfo_Unit.Size(m)
+func (m *UnitInfo) XXX_Size() int {
+	return xxx_messageInfo_UnitInfo.Size(m)
 }
-func (m *Unit) XXX_DiscardUnknown() {
-	xxx_messageInfo_Unit.DiscardUnknown(m)
+func (m *UnitInfo) XXX_DiscardUnknown() {
+	xxx_messageInfo_UnitInfo.DiscardUnknown(m)
 }
 
-var xxx_messageInfo_Unit proto.InternalMessageInfo
+var xxx_messageInfo_UnitInfo proto.InternalMessageInfo
 
-func (m *Unit) GetUrl() string {
+func (m *UnitInfo) GetUrl() string {
 	if m != nil {
 		return m.Url
 	}
 	return ""
 }
 
-func (m *Unit) GetAvailableThreads() int32 {
+func (m *UnitInfo) GetAvailableThreads() int32 {
 	if m != nil {
 		return m.AvailableThreads
 	}
 	return 0
 }
 
-type Units struct {
-	List                 []*Unit  `protobuf:"bytes,1,rep,name=list,proto3" json:"list,omitempty"`
+type UnitInfos struct {
+	List                 []*UnitInfo `protobuf:"bytes,1,rep,name=list,proto3" json:"list,omitempty"`
+	XXX_NoUnkeyedLiteral struct{}    `json:"-"`
+	XXX_unrecognized     []byte      `json:"-"`
+	XXX_sizecache        int32       `json:"-"`
+}
+
+func (m *UnitInfos) Reset()         { *m = UnitInfos{} }
+func (m *UnitInfos) String() string { return proto.CompactTextString(m) }
+func (*UnitInfos) ProtoMessage()    {}
+func (*UnitInfos) Descriptor() ([]byte, []int) {
+	return fileDescriptor_3cfb3b8ec240c376, []int{1}
+}
+
+func (m *UnitInfos) XXX_Unmarshal(b []byte) error {
+	return xxx_messageInfo_UnitInfos.Unmarshal(m, b)
+}
+func (m *UnitInfos) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+	return xxx_messageInfo_UnitInfos.Marshal(b, m, deterministic)
+}
+func (m *UnitInfos) XXX_Merge(src proto.Message) {
+	xxx_messageInfo_UnitInfos.Merge(m, src)
+}
+func (m *UnitInfos) XXX_Size() int {
+	return xxx_messageInfo_UnitInfos.Size(m)
+}
+func (m *UnitInfos) XXX_DiscardUnknown() {
+	xxx_messageInfo_UnitInfos.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_UnitInfos proto.InternalMessageInfo
+
+func (m *UnitInfos) GetList() []*UnitInfo {
+	if m != nil {
+		return m.List
+	}
+	return nil
+}
+
+type Matrix struct {
+	Matrix               []byte   `protobuf:"bytes,1,opt,name=matrix,proto3" json:"matrix,omitempty"`
 	XXX_NoUnkeyedLiteral struct{} `json:"-"`
 	XXX_unrecognized     []byte   `json:"-"`
 	XXX_sizecache        int32    `json:"-"`
 }
 
-func (m *Units) Reset()         { *m = Units{} }
-func (m *Units) String() string { return proto.CompactTextString(m) }
-func (*Units) ProtoMessage()    {}
-func (*Units) Descriptor() ([]byte, []int) {
-	return fileDescriptor_3cfb3b8ec240c376, []int{1}
+func (m *Matrix) Reset()         { *m = Matrix{} }
+func (m *Matrix) String() string { return proto.CompactTextString(m) }
+func (*Matrix) ProtoMessage()    {}
+func (*Matrix) Descriptor() ([]byte, []int) {
+	return fileDescriptor_3cfb3b8ec240c376, []int{2}
 }
 
-func (m *Units) XXX_Unmarshal(b []byte) error {
-	return xxx_messageInfo_Units.Unmarshal(m, b)
+func (m *Matrix) XXX_Unmarshal(b []byte) error {
+	return xxx_messageInfo_Matrix.Unmarshal(m, b)
 }
-func (m *Units) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
-	return xxx_messageInfo_Units.Marshal(b, m, deterministic)
+func (m *Matrix) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+	return xxx_messageInfo_Matrix.Marshal(b, m, deterministic)
 }
-func (m *Units) XXX_Merge(src proto.Message) {
-	xxx_messageInfo_Units.Merge(m, src)
+func (m *Matrix) XXX_Merge(src proto.Message) {
+	xxx_messageInfo_Matrix.Merge(m, src)
 }
-func (m *Units) XXX_Size() int {
-	return xxx_messageInfo_Units.Size(m)
+func (m *Matrix) XXX_Size() int {
+	return xxx_messageInfo_Matrix.Size(m)
 }
-func (m *Units) XXX_DiscardUnknown() {
-	xxx_messageInfo_Units.DiscardUnknown(m)
+func (m *Matrix) XXX_DiscardUnknown() {
+	xxx_messageInfo_Matrix.DiscardUnknown(m)
 }
 
-var xxx_messageInfo_Units proto.InternalMessageInfo
+var xxx_messageInfo_Matrix proto.InternalMessageInfo
 
-func (m *Units) GetList() []*Unit {
+func (m *Matrix) GetMatrix() []byte {
 	if m != nil {
-		return m.List
+		return m.Matrix
+	}
+	return nil
+}
+
+type DataSet struct {
+	Biases               []*Matrix `protobuf:"bytes,1,rep,name=biases,proto3" json:"biases,omitempty"`
+	Weights              []*Matrix `protobuf:"bytes,2,rep,name=weights,proto3" json:"weights,omitempty"`
+	Data                 []*Matrix `protobuf:"bytes,3,rep,name=data,proto3" json:"data,omitempty"`
+	Result               []*Matrix `protobuf:"bytes,4,rep,name=result,proto3" json:"result,omitempty"`
+	XXX_NoUnkeyedLiteral struct{}  `json:"-"`
+	XXX_unrecognized     []byte    `json:"-"`
+	XXX_sizecache        int32     `json:"-"`
+}
+
+func (m *DataSet) Reset()         { *m = DataSet{} }
+func (m *DataSet) String() string { return proto.CompactTextString(m) }
+func (*DataSet) ProtoMessage()    {}
+func (*DataSet) Descriptor() ([]byte, []int) {
+	return fileDescriptor_3cfb3b8ec240c376, []int{3}
+}
+
+func (m *DataSet) XXX_Unmarshal(b []byte) error {
+	return xxx_messageInfo_DataSet.Unmarshal(m, b)
+}
+func (m *DataSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+	return xxx_messageInfo_DataSet.Marshal(b, m, deterministic)
+}
+func (m *DataSet) XXX_Merge(src proto.Message) {
+	xxx_messageInfo_DataSet.Merge(m, src)
+}
+func (m *DataSet) XXX_Size() int {
+	return xxx_messageInfo_DataSet.Size(m)
+}
+func (m *DataSet) XXX_DiscardUnknown() {
+	xxx_messageInfo_DataSet.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_DataSet proto.InternalMessageInfo
+
+func (m *DataSet) GetBiases() []*Matrix {
+	if m != nil {
+		return m.Biases
+	}
+	return nil
+}
+
+func (m *DataSet) GetWeights() []*Matrix {
+	if m != nil {
+		return m.Weights
+	}
+	return nil
+}
+
+func (m *DataSet) GetData() []*Matrix {
+	if m != nil {
+		return m.Data
+	}
+	return nil
+}
+
+func (m *DataSet) GetResult() []*Matrix {
+	if m != nil {
+		return m.Result
 	}
 	return nil
 }
 
 func init() {
-	proto.RegisterType((*Unit)(nil), "cluster.Unit")
-	proto.RegisterType((*Units)(nil), "cluster.Units")
+	proto.RegisterType((*UnitInfo)(nil), "cluster.UnitInfo")
+	proto.RegisterType((*UnitInfos)(nil), "cluster.UnitInfos")
+	proto.RegisterType((*Matrix)(nil), "cluster.Matrix")
+	proto.RegisterType((*DataSet)(nil), "cluster.DataSet")
 }
 
 func init() { proto.RegisterFile("cluster.proto", fileDescriptor_3cfb3b8ec240c376) }
 
 var fileDescriptor_3cfb3b8ec240c376 = []byte{
-	// 173 bytes of a gzipped FileDescriptorProto
-	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x4d, 0xce, 0x29, 0x2d,
-	0x2e, 0x49, 0x2d, 0xd2, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x87, 0x72, 0x95, 0x5c, 0xb8,
-	0x58, 0x42, 0xf3, 0x32, 0x4b, 0x84, 0x04, 0xb8, 0x98, 0x4b, 0x8b, 0x72, 0x24, 0x18, 0x15, 0x18,
-	0x35, 0x38, 0x83, 0x40, 0x4c, 0x21, 0x2d, 0x2e, 0x81, 0xc4, 0xb2, 0xc4, 0xcc, 0x9c, 0xc4, 0xa4,
-	0x9c, 0xd4, 0x90, 0x8c, 0xa2, 0xd4, 0xc4, 0x94, 0x62, 0x09, 0x26, 0x05, 0x46, 0x0d, 0xc1, 0x20,
-	0x0c, 0x71, 0x25, 0x2d, 0x2e, 0x56, 0x90, 0x29, 0xc5, 0x42, 0x8a, 0x5c, 0x2c, 0x39, 0x99, 0xc5,
-	0x25, 0x12, 0x8c, 0x0a, 0xcc, 0x1a, 0xdc, 0x46, 0xbc, 0x7a, 0x30, 0x5b, 0x41, 0xb2, 0x41, 0x60,
-	0x29, 0x23, 0x57, 0x2e, 0x11, 0xbf, 0xd4, 0xd2, 0xa2, 0xc4, 0x1c, 0xbf, 0xd4, 0x92, 0xf2, 0xfc,
-	0xa2, 0x6c, 0x67, 0x88, 0x12, 0x21, 0x5d, 0x2e, 0x8e, 0xa0, 0xd4, 0xf4, 0x4c, 0x30, 0x1b, 0x55,
-	0xa3, 0x14, 0x1f, 0x0a, 0xb7, 0x58, 0x89, 0xc1, 0x80, 0x31, 0x89, 0x0d, 0xec, 0x11, 0x63, 0x40,
-	0x00, 0x00, 0x00, 0xff, 0xff, 0x5f, 0x84, 0xe4, 0x41, 0xd9, 0x00, 0x00, 0x00,
+	// 290 bytes of a gzipped FileDescriptorProto
+	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0xb1, 0x4e, 0xc3, 0x30,
+	0x10, 0x86, 0x6b, 0x52, 0x25, 0xed, 0x01, 0x22, 0xb1, 0x10, 0x8a, 0x3a, 0x45, 0x46, 0x88, 0xd0,
+	0xa1, 0x42, 0x81, 0x9d, 0x01, 0x06, 0x90, 0xa0, 0x83, 0x81, 0x07, 0x70, 0xa8, 0x69, 0x2d, 0x4c,
+	0x82, 0xec, 0x0b, 0xe5, 0x9d, 0x78, 0x49, 0x14, 0x27, 0xa9, 0x04, 0x29, 0xdb, 0xdd, 0x7d, 0xbf,
+	0xff, 0xff, 0x74, 0x86, 0xfd, 0x17, 0x5d, 0x59, 0x94, 0x66, 0xf6, 0x61, 0x4a, 0x2c, 0x69, 0xd0,
+	0xb6, 0xec, 0x16, 0x46, 0xcf, 0x85, 0xc2, 0xbb, 0xe2, 0xb5, 0xa4, 0x21, 0x78, 0x95, 0xd1, 0x31,
+	0x49, 0x48, 0x3a, 0xe6, 0x75, 0x49, 0xa7, 0x10, 0x8a, 0x4f, 0xa1, 0xb4, 0xc8, 0xb5, 0x7c, 0x5a,
+	0x19, 0x29, 0x16, 0x36, 0xde, 0x49, 0x48, 0x1a, 0xf1, 0xde, 0x9c, 0x65, 0x30, 0xee, 0x9c, 0x2c,
+	0x3d, 0x81, 0xa1, 0x56, 0x16, 0x63, 0x92, 0x78, 0xe9, 0x6e, 0x16, 0xcd, 0xba, 0xf4, 0x4e, 0xc1,
+	0x1d, 0x66, 0x09, 0xf8, 0x0f, 0x02, 0x8d, 0xfa, 0xa2, 0x47, 0xe0, 0xbf, 0xbb, 0xca, 0xc5, 0xef,
+	0xf1, 0xb6, 0x63, 0xdf, 0x04, 0x82, 0x1b, 0x81, 0xe2, 0x51, 0x22, 0x3d, 0x05, 0x3f, 0x57, 0xc2,
+	0x4a, 0xdb, 0xda, 0x1e, 0x6c, 0x6c, 0x1b, 0x13, 0xde, 0x62, 0x7a, 0x06, 0xc1, 0x5a, 0xaa, 0xe5,
+	0x0a, 0xeb, 0x6d, 0xb7, 0x2a, 0x3b, 0x4e, 0x8f, 0x61, 0xb8, 0x10, 0x28, 0x62, 0x6f, 0xbb, 0xce,
+	0xc1, 0x3a, 0xd8, 0x48, 0x5b, 0x69, 0x8c, 0x87, 0xff, 0x04, 0x37, 0x38, 0xbb, 0x87, 0xc3, 0xb9,
+	0xac, 0x8c, 0xd0, 0x73, 0x89, 0xeb, 0xd2, 0xbc, 0x5d, 0x37, 0x32, 0x7a, 0x09, 0x23, 0x2e, 0x97,
+	0xca, 0xd5, 0xfd, 0x63, 0x4c, 0xfa, 0x23, 0x36, 0x38, 0x27, 0xd9, 0x15, 0x44, 0xbf, 0xdc, 0x6a,
+	0x48, 0xa7, 0xe0, 0xf1, 0xaa, 0xa0, 0xe1, 0xe6, 0x49, 0x7b, 0x9d, 0xc9, 0xdf, 0xa5, 0xd8, 0x20,
+	0xf7, 0xdd, 0x67, 0x5f, 0xfc, 0x04, 0x00, 0x00, 0xff, 0xff, 0xa9, 0xdf, 0x40, 0x3f, 0xfd, 0x01,
+	0x00, 0x00,
 }
 
 // Reference imports to suppress errors if they are not otherwise used.
@@ -144,7 +256,7 @@ const _ = grpc.SupportPackageIsVersion6
 //
 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
 type NeuralNetworkClusterClient interface {
-	Register(ctx context.Context, in *Unit, opts ...grpc.CallOption) (NeuralNetworkCluster_RegisterClient, error)
+	Register(ctx context.Context, in *UnitInfo, opts ...grpc.CallOption) (NeuralNetworkCluster_RegisterClient, error)
 }
 
 type neuralNetworkClusterClient struct {
@@ -155,7 +267,7 @@ func NewNeuralNetworkClusterClient(cc grpc.ClientConnInterface) NeuralNetworkClu
 	return &neuralNetworkClusterClient{cc}
 }
 
-func (c *neuralNetworkClusterClient) Register(ctx context.Context, in *Unit, opts ...grpc.CallOption) (NeuralNetworkCluster_RegisterClient, error) {
+func (c *neuralNetworkClusterClient) Register(ctx context.Context, in *UnitInfo, opts ...grpc.CallOption) (NeuralNetworkCluster_RegisterClient, error) {
 	stream, err := c.cc.NewStream(ctx, &_NeuralNetworkCluster_serviceDesc.Streams[0], "/cluster.NeuralNetworkCluster/Register", opts...)
 	if err != nil {
 		return nil, err
@@ -171,7 +283,7 @@ func (c *neuralNetworkClusterClient) Register(ctx context.Context, in *Unit, opt
 }
 
 type NeuralNetworkCluster_RegisterClient interface {
-	Recv() (*Units, error)
+	Recv() (*UnitInfo, error)
 	grpc.ClientStream
 }
 
@@ -179,8 +291,8 @@ type neuralNetworkClusterRegisterClient struct {
 	grpc.ClientStream
 }
 
-func (x *neuralNetworkClusterRegisterClient) Recv() (*Units, error) {
-	m := new(Units)
+func (x *neuralNetworkClusterRegisterClient) Recv() (*UnitInfo, error) {
+	m := new(UnitInfo)
 	if err := x.ClientStream.RecvMsg(m); err != nil {
 		return nil, err
 	}
@@ -189,14 +301,14 @@ func (x *neuralNetworkClusterRegisterClient) Recv() (*Units, error) {
 
 // NeuralNetworkClusterServer is the server API for NeuralNetworkCluster service.
 type NeuralNetworkClusterServer interface {
-	Register(*Unit, NeuralNetworkCluster_RegisterServer) error
+	Register(*UnitInfo, NeuralNetworkCluster_RegisterServer) error
 }
 
 // UnimplementedNeuralNetworkClusterServer can be embedded to have forward compatible implementations.
 type UnimplementedNeuralNetworkClusterServer struct {
 }
 
-func (*UnimplementedNeuralNetworkClusterServer) Register(req *Unit, srv NeuralNetworkCluster_RegisterServer) error {
+func (*UnimplementedNeuralNetworkClusterServer) Register(req *UnitInfo, srv NeuralNetworkCluster_RegisterServer) error {
 	return status.Errorf(codes.Unimplemented, "method Register not implemented")
 }
 
@@ -205,7 +317,7 @@ func RegisterNeuralNetworkClusterServer(s *grpc.Server, srv NeuralNetworkCluster
 }
 
 func _NeuralNetworkCluster_Register_Handler(srv interface{}, stream grpc.ServerStream) error {
-	m := new(Unit)
+	m := new(UnitInfo)
 	if err := stream.RecvMsg(m); err != nil {
 		return err
 	}
@@ -213,7 +325,7 @@ func _NeuralNetworkCluster_Register_Handler(srv interface{}, stream grpc.ServerS
 }
 
 type NeuralNetworkCluster_RegisterServer interface {
-	Send(*Units) error
+	Send(*UnitInfo) error
 	grpc.ServerStream
 }
 
@@ -221,7 +333,7 @@ type neuralNetworkClusterRegisterServer struct {
 	grpc.ServerStream
 }
 
-func (x *neuralNetworkClusterRegisterServer) Send(m *Units) error {
+func (x *neuralNetworkClusterRegisterServer) Send(m *UnitInfo) error {
 	return x.ServerStream.SendMsg(m)
 }
 
@@ -238,3 +350,75 @@ var _NeuralNetworkCluster_serviceDesc = grpc.ServiceDesc{
 	},
 	Metadata: "cluster.proto",
 }
+
+// NeuralNetworkUnitClient is the client API for NeuralNetworkUnit service.
+//
+// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
+type NeuralNetworkUnitClient interface {
+	Run(ctx context.Context, in *DataSet, opts ...grpc.CallOption) (*Matrix, error)
+}
+
+type neuralNetworkUnitClient struct {
+	cc grpc.ClientConnInterface
+}
+
+func NewNeuralNetworkUnitClient(cc grpc.ClientConnInterface) NeuralNetworkUnitClient {
+	return &neuralNetworkUnitClient{cc}
+}
+
+func (c *neuralNetworkUnitClient) Run(ctx context.Context, in *DataSet, opts ...grpc.CallOption) (*Matrix, error) {
+	out := new(Matrix)
+	err := c.cc.Invoke(ctx, "/cluster.NeuralNetworkUnit/Run", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
+// NeuralNetworkUnitServer is the server API for NeuralNetworkUnit service.
+type NeuralNetworkUnitServer interface {
+	Run(context.Context, *DataSet) (*Matrix, error)
+}
+
+// UnimplementedNeuralNetworkUnitServer can be embedded to have forward compatible implementations.
+type UnimplementedNeuralNetworkUnitServer struct {
+}
+
+func (*UnimplementedNeuralNetworkUnitServer) Run(ctx context.Context, req *DataSet) (*Matrix, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method Run not implemented")
+}
+
+func RegisterNeuralNetworkUnitServer(s *grpc.Server, srv NeuralNetworkUnitServer) {
+	s.RegisterService(&_NeuralNetworkUnit_serviceDesc, srv)
+}
+
+func _NeuralNetworkUnit_Run_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(DataSet)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(NeuralNetworkUnitServer).Run(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/cluster.NeuralNetworkUnit/Run",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(NeuralNetworkUnitServer).Run(ctx, req.(*DataSet))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
+var _NeuralNetworkUnit_serviceDesc = grpc.ServiceDesc{
+	ServiceName: "cluster.NeuralNetworkUnit",
+	HandlerType: (*NeuralNetworkUnitServer)(nil),
+	Methods: []grpc.MethodDesc{
+		{
+			MethodName: "Run",
+			Handler:    _NeuralNetworkUnit_Run_Handler,
+		},
+	},
+	Streams:  []grpc.StreamDesc{},
+	Metadata: "cluster.proto",
+}

+ 2 - 6
go.mod

@@ -1,9 +1,5 @@
 module git.semlanik.org/semlanik/NeuralNetwork
 
-go 1.12
+go 1.14
 
-require (
-	github.com/golang/protobuf v1.3.3
-	gonum.org/v1/gonum v0.6.2
-	google.golang.org/grpc v1.27.1
-)
+require google.golang.org/protobuf v1.25.0 // indirect

+ 22 - 22
go.sum

@@ -1,30 +1,27 @@
 cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
 github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
-github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw=
 github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
 github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
 github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
 github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
-github.com/fogleman/gg v1.2.1-0.20190220221249-0403632d5b90/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k=
-github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k=
-github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58=
 github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
 github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
 github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
 github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
-github.com/golang/protobuf v1.3.4 h1:87PNWwrRvUSnqS4dlcBU/ftvOIBep4sYuBLlh6rX2wk=
-github.com/golang/protobuf v1.3.4/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
-github.com/google/go-cmp v0.2.0 h1:+dTQ8DZQJz0Mb/HjFlkptS1FeQ4cWSnN941F8aEG4SQ=
+github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8=
+github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA=
+github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs=
+github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w=
+github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0=
+github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8=
 github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
-github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes=
+github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
+github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
+github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
+github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
 github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
 golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
-golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
-golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
 golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
-golang.org/x/exp v0.0.0-20190125153040-c74c464bbbf2 h1:y102fOLFqhV41b+4GPiJoa0k/x+pJcEi2/HB1Y5T6fU=
-golang.org/x/exp v0.0.0-20190125153040-c74c464bbbf2/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
-golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs=
 golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
 golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
 golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
@@ -39,24 +36,27 @@ golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJ
 golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
 golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
 golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
-golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
 golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
-golang.org/x/tools v0.0.0-20190206041539-40960b6deb8e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
 golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY=
 golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
 golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
-gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo=
-gonum.org/v1/gonum v0.6.2/go.mod h1:9mxDZsDKxgMAuccQkewq682L+0eCu4dCN2yonUJTCLU=
-gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0 h1:OE9mWmgKkjJyEmDAAtGMPjXu+YNeGvK9VTSHY6+Qihc=
-gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw=
-gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b/go.mod h1:Wt8AAjI+ypCyYX3nZBvf6cAIx93T+c/OS2HFAYskSZc=
+golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
 google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
 google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
 google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
 google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
+google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo=
 google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
 google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
-google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
+google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
+google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
+google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0=
+google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM=
+google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE=
+google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo=
+google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
+google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU=
+google.golang.org/protobuf v1.25.0 h1:Ejskq+SyPohKW+1uil0JJMtmHCgJPJ/qWTxr8qp+R4c=
+google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c=
 honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
 honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
-rsc.io/pdf v0.1.1/go.mod h1:n8OzWcQ6Sp37PL01nO98y4iUCRdTGarVfzxY20ICaU4=

+ 3 - 5
updateproto.sh

@@ -1,10 +1,8 @@
-export GOPATH=$PWD
-export PATH=$PATH:$PWD/bin
-export GOBIN=$PWD/bin
+export GOBIN=$(go env GOPATH)/bin
+export PATH=$PATH:$GOBIN
 export RPC_PATH=$PWD/remotecontrol
 
-go get github.com/golang/protobuf/protoc-gen-go
-go install ./src/github.com/golang/protobuf/protoc-gen-go
+go install google.golang.org/protobuf/compiler/protogen
 
 mkdir -p $RPC_PATH
 rm -f $RPC_PATH/*.pb.go