client

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Jul 19, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PredictionRequest

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

SDK is an instance of the Agones SDK

func NewPrediction

func NewPrediction() *PredictionRequest

func (*PredictionRequest) Explain

func (req *PredictionRequest) Explain() *PredictionRequest

func (*PredictionRequest) GetModel

func (r *PredictionRequest) GetModel(predictorName string, name string, host string, port int, ctx context.Context) (*api.GetModelResponse, error)

func (*PredictionRequest) GetPredictor

func (req *PredictionRequest) GetPredictor(host string, port int) (*api.GetPredictorResponse, error)

func (*PredictionRequest) SendInsecure

func (req *PredictionRequest) SendInsecure(host string, port int) (*PredictionResult, error)

send the request to the predictor

func (*PredictionRequest) Validate

func (req *PredictionRequest) Validate() *PredictionRequest

func (*PredictionRequest) WithCsv

func (req *PredictionRequest) WithCsv(payload string) *PredictionRequest

func (*PredictionRequest) WithJson

func (req *PredictionRequest) WithJson(payload string) *PredictionRequest

func (*PredictionRequest) WithLabeled

func (req *PredictionRequest) WithLabeled() *PredictionRequest

func (*PredictionRequest) WithMetrics

func (req *PredictionRequest) WithMetrics(metrics []string) *PredictionRequest

type PredictionResult

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

func (*PredictionResult) AsJson

func (res *PredictionResult) AsJson() (string, error)

return raw json

func (*PredictionResult) TestResults

func (res *PredictionResult) TestResults() (map[string]float32, error)

TestResults answers the result of executing the test

type PredictionResultLineItem

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

type PredictorClient

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

SDK is an instance of the Agones SDK

func NewPredictorClient

func NewPredictorClient(host string, port int32) (*PredictorClient, error)

func (*PredictorClient) Alive

func (r *PredictorClient) Alive() (bool, error)

func (*PredictorClient) ModelReady

func (r *PredictorClient) ModelReady(name string, version string) (bool, error)

func (*PredictorClient) Ready

func (r *PredictorClient) Ready() (bool, error)

func (*PredictorClient) Shutdown added in v0.4.647

func (r *PredictorClient) Shutdown() error

Jump to

Keyboard shortcuts

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