trainer

package
v2.0.26 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 11, 2023 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_pkg_apis_trainer_v1_trainer_proto protoreflect.FileDescriptor
View Source
var Trainer_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "trainer.v1.Trainer",
	HandlerType: (*TrainerServer)(nil),
	Methods:     []grpc.MethodDesc{},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "Train",
			Handler:       _Trainer_Train_Handler,
			ClientStreams: true,
		},
	},
	Metadata: "pkg/apis/trainer/v1/trainer.proto",
}

Trainer_ServiceDesc is the grpc.ServiceDesc for Trainer service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterTrainerServer

func RegisterTrainerServer(s grpc.ServiceRegistrar, srv TrainerServer)

Types

type TrainGNNRequest

type TrainGNNRequest struct {

	// Dataset of training GNN.
	Dataset []byte `protobuf:"bytes,1,opt,name=dataset,proto3" json:"dataset,omitempty"`
	// contains filtered or unexported fields
}

TrainGNNRequest represents to train GNN model request of TrainRequest.

func (*TrainGNNRequest) Descriptor deprecated

func (*TrainGNNRequest) Descriptor() ([]byte, []int)

Deprecated: Use TrainGNNRequest.ProtoReflect.Descriptor instead.

func (*TrainGNNRequest) GetDataset

func (x *TrainGNNRequest) GetDataset() []byte

func (*TrainGNNRequest) ProtoMessage

func (*TrainGNNRequest) ProtoMessage()

func (*TrainGNNRequest) ProtoReflect

func (x *TrainGNNRequest) ProtoReflect() protoreflect.Message

func (*TrainGNNRequest) Reset

func (x *TrainGNNRequest) Reset()

func (*TrainGNNRequest) String

func (x *TrainGNNRequest) String() string

func (*TrainGNNRequest) Validate

func (m *TrainGNNRequest) Validate() error

Validate checks the field values on TrainGNNRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*TrainGNNRequest) ValidateAll

func (m *TrainGNNRequest) ValidateAll() error

ValidateAll checks the field values on TrainGNNRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in TrainGNNRequestMultiError, or nil if none found.

type TrainGNNRequestMultiError

type TrainGNNRequestMultiError []error

TrainGNNRequestMultiError is an error wrapping multiple validation errors returned by TrainGNNRequest.ValidateAll() if the designated constraints aren't met.

func (TrainGNNRequestMultiError) AllErrors

func (m TrainGNNRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (TrainGNNRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type TrainGNNRequestValidationError

type TrainGNNRequestValidationError struct {
	// contains filtered or unexported fields
}

TrainGNNRequestValidationError is the validation error returned by TrainGNNRequest.Validate if the designated constraints aren't met.

func (TrainGNNRequestValidationError) Cause

Cause function returns cause value.

func (TrainGNNRequestValidationError) Error

Error satisfies the builtin error interface

func (TrainGNNRequestValidationError) ErrorName

func (e TrainGNNRequestValidationError) ErrorName() string

ErrorName returns error name.

func (TrainGNNRequestValidationError) Field

Field function returns field value.

func (TrainGNNRequestValidationError) Key

Key function returns key value.

func (TrainGNNRequestValidationError) Reason

Reason function returns reason value.

type TrainMLPRequest

type TrainMLPRequest struct {

	// Dataset of training MLP.
	Dataset []byte `protobuf:"bytes,1,opt,name=dataset,proto3" json:"dataset,omitempty"`
	// contains filtered or unexported fields
}

TrainMLPRequest represents to train MLP model request of TrainRequest.

func (*TrainMLPRequest) Descriptor deprecated

func (*TrainMLPRequest) Descriptor() ([]byte, []int)

Deprecated: Use TrainMLPRequest.ProtoReflect.Descriptor instead.

func (*TrainMLPRequest) GetDataset

func (x *TrainMLPRequest) GetDataset() []byte

func (*TrainMLPRequest) ProtoMessage

func (*TrainMLPRequest) ProtoMessage()

func (*TrainMLPRequest) ProtoReflect

func (x *TrainMLPRequest) ProtoReflect() protoreflect.Message

func (*TrainMLPRequest) Reset

func (x *TrainMLPRequest) Reset()

func (*TrainMLPRequest) String

func (x *TrainMLPRequest) String() string

func (*TrainMLPRequest) Validate

func (m *TrainMLPRequest) Validate() error

Validate checks the field values on TrainMLPRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*TrainMLPRequest) ValidateAll

func (m *TrainMLPRequest) ValidateAll() error

ValidateAll checks the field values on TrainMLPRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in TrainMLPRequestMultiError, or nil if none found.

type TrainMLPRequestMultiError

type TrainMLPRequestMultiError []error

TrainMLPRequestMultiError is an error wrapping multiple validation errors returned by TrainMLPRequest.ValidateAll() if the designated constraints aren't met.

func (TrainMLPRequestMultiError) AllErrors

func (m TrainMLPRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (TrainMLPRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type TrainMLPRequestValidationError

type TrainMLPRequestValidationError struct {
	// contains filtered or unexported fields
}

TrainMLPRequestValidationError is the validation error returned by TrainMLPRequest.Validate if the designated constraints aren't met.

func (TrainMLPRequestValidationError) Cause

Cause function returns cause value.

func (TrainMLPRequestValidationError) Error

Error satisfies the builtin error interface

func (TrainMLPRequestValidationError) ErrorName

func (e TrainMLPRequestValidationError) ErrorName() string

ErrorName returns error name.

func (TrainMLPRequestValidationError) Field

Field function returns field value.

func (TrainMLPRequestValidationError) Key

Key function returns key value.

func (TrainMLPRequestValidationError) Reason

Reason function returns reason value.

type TrainRequest

type TrainRequest struct {

	// Scheduler hostname.
	Hostname string `protobuf:"bytes,1,opt,name=hostname,proto3" json:"hostname,omitempty"`
	// Scheduler ip.
	Ip string `protobuf:"bytes,2,opt,name=ip,proto3" json:"ip,omitempty"`
	// Types that are assignable to Request:
	//
	//	*TrainRequest_TrainGnnRequest
	//	*TrainRequest_TrainMlpRequest
	Request isTrainRequest_Request `protobuf_oneof:"request"`
	// contains filtered or unexported fields
}

TrainRequest represents request of Train.

func (*TrainRequest) Descriptor deprecated

func (*TrainRequest) Descriptor() ([]byte, []int)

Deprecated: Use TrainRequest.ProtoReflect.Descriptor instead.

func (*TrainRequest) GetHostname

func (x *TrainRequest) GetHostname() string

func (*TrainRequest) GetIp

func (x *TrainRequest) GetIp() string

func (*TrainRequest) GetRequest

func (m *TrainRequest) GetRequest() isTrainRequest_Request

func (*TrainRequest) GetTrainGnnRequest

func (x *TrainRequest) GetTrainGnnRequest() *TrainGNNRequest

func (*TrainRequest) GetTrainMlpRequest

func (x *TrainRequest) GetTrainMlpRequest() *TrainMLPRequest

func (*TrainRequest) ProtoMessage

func (*TrainRequest) ProtoMessage()

func (*TrainRequest) ProtoReflect

func (x *TrainRequest) ProtoReflect() protoreflect.Message

func (*TrainRequest) Reset

func (x *TrainRequest) Reset()

func (*TrainRequest) String

func (x *TrainRequest) String() string

func (*TrainRequest) Validate

func (m *TrainRequest) Validate() error

Validate checks the field values on TrainRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*TrainRequest) ValidateAll

func (m *TrainRequest) ValidateAll() error

ValidateAll checks the field values on TrainRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in TrainRequestMultiError, or nil if none found.

type TrainRequestMultiError

type TrainRequestMultiError []error

TrainRequestMultiError is an error wrapping multiple validation errors returned by TrainRequest.ValidateAll() if the designated constraints aren't met.

func (TrainRequestMultiError) AllErrors

func (m TrainRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (TrainRequestMultiError) Error

func (m TrainRequestMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type TrainRequestValidationError

type TrainRequestValidationError struct {
	// contains filtered or unexported fields
}

TrainRequestValidationError is the validation error returned by TrainRequest.Validate if the designated constraints aren't met.

func (TrainRequestValidationError) Cause

Cause function returns cause value.

func (TrainRequestValidationError) Error

Error satisfies the builtin error interface

func (TrainRequestValidationError) ErrorName

func (e TrainRequestValidationError) ErrorName() string

ErrorName returns error name.

func (TrainRequestValidationError) Field

Field function returns field value.

func (TrainRequestValidationError) Key

Key function returns key value.

func (TrainRequestValidationError) Reason

Reason function returns reason value.

type TrainRequest_TrainGnnRequest

type TrainRequest_TrainGnnRequest struct {
	TrainGnnRequest *TrainGNNRequest `protobuf:"bytes,3,opt,name=train_gnn_request,json=trainGnnRequest,proto3,oneof"`
}

type TrainRequest_TrainMlpRequest

type TrainRequest_TrainMlpRequest struct {
	TrainMlpRequest *TrainMLPRequest `protobuf:"bytes,4,opt,name=train_mlp_request,json=trainMlpRequest,proto3,oneof"`
}

type TrainerClient

type TrainerClient interface {
	// Train trains models of scheduler using dataset.
	Train(ctx context.Context, opts ...grpc.CallOption) (Trainer_TrainClient, error)
}

TrainerClient is the client API for Trainer service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewTrainerClient

func NewTrainerClient(cc grpc.ClientConnInterface) TrainerClient

type TrainerServer

type TrainerServer interface {
	// Train trains models of scheduler using dataset.
	Train(Trainer_TrainServer) error
}

TrainerServer is the server API for Trainer service. All implementations should embed UnimplementedTrainerServer for forward compatibility

type Trainer_TrainClient

type Trainer_TrainClient interface {
	Send(*TrainRequest) error
	CloseAndRecv() (*emptypb.Empty, error)
	grpc.ClientStream
}

type Trainer_TrainServer

type Trainer_TrainServer interface {
	SendAndClose(*emptypb.Empty) error
	Recv() (*TrainRequest, error)
	grpc.ServerStream
}

type UnimplementedTrainerServer

type UnimplementedTrainerServer struct {
}

UnimplementedTrainerServer should be embedded to have forward compatible implementations.

func (UnimplementedTrainerServer) Train

type UnsafeTrainerServer

type UnsafeTrainerServer interface {
	// contains filtered or unexported methods
}

UnsafeTrainerServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TrainerServer will result in compilation errors.

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL