triton

package
v0.6.1-alpha Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeserializeBytesTensor

func DeserializeBytesTensor(encodedTensor []byte, capacity int64) []string

func DeserializeFloat32Tensor

func DeserializeFloat32Tensor(encodedTensor []byte) []float32

func ParseModel

func ParseModel(modelMetadata *inferenceserver.ModelMetadataResponse, modelConfig *inferenceserver.ModelConfigResponse) (int64, int64, int64)

func ReadFloat32

func ReadFloat32(fourBytes []byte) float32

func ReadInt32

func ReadInt32(fourBytes []byte) int32

func Reshape1DArrayFloat32To3D

func Reshape1DArrayFloat32To3D(array []float32, shape []int64) ([][][]float32, error)

func Reshape1DArrayStringTo2D

func Reshape1DArrayStringTo2D(array []string, shape []int64) ([][]string, error)

TODO: generalise reshape functions by using interface{} arguments and returned values

func SerializeBytesTensor

func SerializeBytesTensor(tensor [][]byte) []byte

Types

type DetectionOutput

type DetectionOutput struct {
	Boxes  [][][]float32
	Labels [][]string
}

type KeypointOutput

type KeypointOutput struct {
	Keypoints [][][]float32
	Scores    []float32
}

type Triton

type Triton interface {
	ServerLiveRequest() *inferenceserver.ServerLiveResponse
	ServerReadyRequest() *inferenceserver.ServerReadyResponse
	ModelMetadataRequest(modelName string, modelInstance string) *inferenceserver.ModelMetadataResponse
	ModelConfigRequest(modelName string, modelInstance string) *inferenceserver.ModelConfigResponse
	ModelInferRequest(task modelPB.ModelInstance_Task, rawInput [][]byte, modelName string, modelInstance string, modelMetadata *inferenceserver.ModelMetadataResponse, modelConfig *inferenceserver.ModelConfigResponse) (*inferenceserver.ModelInferResponse, error)
	PostProcess(inferResponse *inferenceserver.ModelInferResponse, modelMetadata *inferenceserver.ModelMetadataResponse, task modelPB.ModelInstance_Task) (interface{}, error)
	LoadModelRequest(modelName string) (*inferenceserver.RepositoryModelLoadResponse, error)
	UnloadModelRequest(modelName string) (*inferenceserver.RepositoryModelUnloadResponse, error)
	ListModelsRequest() *inferenceserver.RepositoryIndexResponse
	IsTritonServerReady() bool
	Init()
	Close()
}

func NewTriton

func NewTriton() Triton

Jump to

Keyboard shortcuts

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