Documentation
¶
Index ¶
Constants ¶
View Source
const B64KeySuffix string = "_bytes"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TFDType ¶
type TFDType int
const ( // all the possible constants that can be JSON-ified according to // https://www.tensorflow.org/tfx/serving/api_rest#json_mapping // along with a representation for B64 strings DtBool TFDType = iota DtB64String DtString DtInt8 DtUInt8 DtInt16 DtInt32 DtUInt32 DtInt64 DtUInt64 DtFloat DtDouble )
type TFMetaGraph ¶
type TFMetaGraph struct {
SignatureDefs []TFSignatureDef
Tags []string
}
func NewTFMetaGraph ¶
func NewTFMetaGraph(metaGraph *pb.MetaGraphDef) (TFMetaGraph, error)
func (*TFMetaGraph) Schema ¶
func (t *TFMetaGraph) Schema() *openapi3.Schema
type TFSavedModel ¶
type TFSavedModel struct {
MetaGraphs []TFMetaGraph
}
func NewTFSavedModel ¶
func NewTFSavedModel(model *pb.SavedModel) (TFSavedModel, error)
func (*TFSavedModel) Schema ¶
func (t *TFSavedModel) Schema() *openapi3.Schema
type TFShape ¶
type TFShape []int64
func NewTFShape ¶
func NewTFShape(dimensions []*fw.TensorShapeProto_Dim) TFShape
type TFSignatureDef ¶
func NewTFSignatureDef ¶
func NewTFSignatureDef(key string, method string, inputs map[string]*pb.TensorInfo, outputs map[string]*pb.TensorInfo) (TFSignatureDef, error)
func (*TFSignatureDef) Schema ¶
func (t *TFSignatureDef) Schema() *openapi3.Schema
type TFTensor ¶
type TFTensor struct {
// Name of the logical tensor
Name string
// Data type contained in this tensor
DType TFDType
// Length of the shape is rank when rank >= 0, nil otherwise
Shape TFShape
// If rank = -1, the shape is unknown. Otherwise, rank corresponds to the number of dimensions in this tensor
Rank int64
}
func NewTFTensor ¶
func NewTFTensor(name string, tensor *pb.TensorInfo) (TFTensor, error)
Click to show internal directories.
Click to hide internal directories.