viam.gen.service.mlmodel.v1.mlmodel_pb2
@generated by mypy-protobuf. Do not edit manually! isort:skip_file
Attributes
the value of the arrays/tensor is the label index |
|
the position of the tensor value in the axis is the label index |
|
Classes
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
|
Abstract base class for protocol messages. |
Module Contents
- viam.gen.service.mlmodel.v1.mlmodel_pb2.DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.LabelType
Bases:
_LabelType
- viam.gen.service.mlmodel.v1.mlmodel_pb2.LABEL_TYPE_TENSOR_VALUE: LabelType
the value of the arrays/tensor is the label index
- viam.gen.service.mlmodel.v1.mlmodel_pb2.LABEL_TYPE_TENSOR_AXIS: LabelType
the position of the tensor value in the axis is the label index
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.InferRequest(*, name: str = ..., input_tensors: Global___FlatTensors | None = ..., extra: google.protobuf.struct_pb2.Struct | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- name: str
name of the model service
- input_tensors() Global___FlatTensors
the input data is provided as set of named flat tensors
- extra() google.protobuf.struct_pb2.Struct
Additional arguments to the method
- HasField(field_name: _HasFieldArgType) bool
Checks if a certain field is set for the message.
For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor,
ValueErrorwill be raised.- Parameters:
field_name (str) – The name of the field to check for presence.
- Returns:
Whether a value has been set for the named field.
- Return type:
bool
- Raises:
ValueError – if the field_name is not a member of this message.
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___InferRequest = InferRequest
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.InferResponse(*, output_tensors: Global___FlatTensors | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- output_tensors() Global___FlatTensors
the output data is provided as a set of named flat tensors
- HasField(field_name: _HasFieldArgType) bool
Checks if a certain field is set for the message.
For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor,
ValueErrorwill be raised.- Parameters:
field_name (str) – The name of the field to check for presence.
- Returns:
Whether a value has been set for the named field.
- Return type:
bool
- Raises:
ValueError – if the field_name is not a member of this message.
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___InferResponse = InferResponse
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.MetadataRequest(*, name: str = ..., extra: google.protobuf.struct_pb2.Struct | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- name: str
name of the model service
- extra() google.protobuf.struct_pb2.Struct
Additional arguments to the method
- HasField(field_name: _HasFieldArgType) bool
Checks if a certain field is set for the message.
For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor,
ValueErrorwill be raised.- Parameters:
field_name (str) – The name of the field to check for presence.
- Returns:
Whether a value has been set for the named field.
- Return type:
bool
- Raises:
ValueError – if the field_name is not a member of this message.
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___MetadataRequest = MetadataRequest
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.MetadataResponse(*, metadata: Global___Metadata | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- metadata() Global___Metadata
this is the metadata associated with the ML model
- HasField(field_name: _HasFieldArgType) bool
Checks if a certain field is set for the message.
For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor,
ValueErrorwill be raised.- Parameters:
field_name (str) – The name of the field to check for presence.
- Returns:
Whether a value has been set for the named field.
- Return type:
bool
- Raises:
ValueError – if the field_name is not a member of this message.
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___MetadataResponse = MetadataResponse
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.Metadata(*, name: str = ..., type: str = ..., description: str = ..., input_info: collections.abc.Iterable[Global___TensorInfo] | None = ..., output_info: collections.abc.Iterable[Global___TensorInfo] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- name: str
name of the model
- type: str
type of model e.g. object_detector, text_classifier
- description: str
description of the model
- input_info() google.protobuf.internal.containers.RepeatedCompositeFieldContainer[Global___TensorInfo]
the necessary input arrays/tensors for an inference, order matters
- output_info() google.protobuf.internal.containers.RepeatedCompositeFieldContainer[Global___TensorInfo]
the output arrays/tensors of the model, order matters
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.TensorInfo(*, name: str = ..., description: str = ..., data_type: str = ..., shape: collections.abc.Iterable[int] | None = ..., associated_files: collections.abc.Iterable[Global___File] | None = ..., extra: google.protobuf.struct_pb2.Struct | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- name: str
name of the data in the array/tensor
- description: str
description of the data in the array/tensor
- data_type: str
data type of the array/tensor, e.g. float32, float64, uint8
- shape() google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]
shape of the array/tensor (-1 for unknown)
- associated_files() google.protobuf.internal.containers.RepeatedCompositeFieldContainer[Global___File]
files associated with the array/tensor, like for category labels
- extra() google.protobuf.struct_pb2.Struct
anything else you want to say
- HasField(field_name: _HasFieldArgType) bool
Checks if a certain field is set for the message.
For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor,
ValueErrorwill be raised.- Parameters:
field_name (str) – The name of the field to check for presence.
- Returns:
Whether a value has been set for the named field.
- Return type:
bool
- Raises:
ValueError – if the field_name is not a member of this message.
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___TensorInfo = TensorInfo
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.File(*, name: str = ..., description: str = ..., label_type: Global___LabelType = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- name: str
name of the file, with file extension
- description: str
description of what the file contains
- label_type: Global___LabelType
How to associate the arrays/tensors to the labels in the file
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataInt8(*, data: bytes = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data: bytes
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataInt8 = FlatTensorDataInt8
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataUInt8(*, data: bytes = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data: bytes
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataUInt8 = FlatTensorDataUInt8
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataInt16(*, data: collections.abc.Iterable[int] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data() google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]
packs two 16-bit numbers per entry - explicitly little-endian so big-endian producers/consumers must compensate
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataInt16 = FlatTensorDataInt16
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataUInt16(*, data: collections.abc.Iterable[int] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data() google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]
packs two 16-bit numbers per entry - explicitly little-endian so big-endian producers/consumers must compensate
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataUInt16 = FlatTensorDataUInt16
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataInt32(*, data: collections.abc.Iterable[int] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data() google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataInt32 = FlatTensorDataInt32
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataUInt32(*, data: collections.abc.Iterable[int] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data() google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataUInt32 = FlatTensorDataUInt32
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataInt64(*, data: collections.abc.Iterable[int] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data() google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataInt64 = FlatTensorDataInt64
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataUInt64(*, data: collections.abc.Iterable[int] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data() google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataUInt64 = FlatTensorDataUInt64
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataFloat(*, data: collections.abc.Iterable[float] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data() google.protobuf.internal.containers.RepeatedScalarFieldContainer[float]
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataFloat = FlatTensorDataFloat
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensorDataDouble(*, data: collections.abc.Iterable[float] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- data() google.protobuf.internal.containers.RepeatedScalarFieldContainer[float]
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensorDataDouble = FlatTensorDataDouble
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensor(*, shape: collections.abc.Iterable[int] | None = ..., int8_tensor: Global___FlatTensorDataInt8 | None = ..., uint8_tensor: Global___FlatTensorDataUInt8 | None = ..., int16_tensor: Global___FlatTensorDataInt16 | None = ..., uint16_tensor: Global___FlatTensorDataUInt16 | None = ..., int32_tensor: Global___FlatTensorDataInt32 | None = ..., uint32_tensor: Global___FlatTensorDataUInt32 | None = ..., int64_tensor: Global___FlatTensorDataInt64 | None = ..., uint64_tensor: Global___FlatTensorDataUInt64 | None = ..., float_tensor: Global___FlatTensorDataFloat | None = ..., double_tensor: Global___FlatTensorDataDouble | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- shape() google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]
the shape of the provided tensor as a list of integer extents
- int8_tensor() Global___FlatTensorDataInt8
- uint8_tensor() Global___FlatTensorDataUInt8
- int16_tensor() Global___FlatTensorDataInt16
- uint16_tensor() Global___FlatTensorDataUInt16
- int32_tensor() Global___FlatTensorDataInt32
- uint32_tensor() Global___FlatTensorDataUInt32
- int64_tensor() Global___FlatTensorDataInt64
- uint64_tensor() Global___FlatTensorDataUInt64
- float_tensor() Global___FlatTensorDataFloat
- double_tensor() Global___FlatTensorDataDouble
- HasField(field_name: _HasFieldArgType) bool
Checks if a certain field is set for the message.
For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor,
ValueErrorwill be raised.- Parameters:
field_name (str) – The name of the field to check for presence.
- Returns:
Whether a value has been set for the named field.
- Return type:
bool
- Raises:
ValueError – if the field_name is not a member of this message.
- WhichOneof(oneof_group: _WhichOneofArgType_tensor) _WhichOneofReturnType_tensor | None
Returns the name of the field that is set inside a oneof group.
If no field is set, returns None.
- Parameters:
oneof_group (str) – the name of the oneof group to check.
- Returns:
The name of the group that is set, or None.
- Return type:
str or None
- Raises:
ValueError – no group with the given name exists
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensor = FlatTensor
- class viam.gen.service.mlmodel.v1.mlmodel_pb2.FlatTensors(*, tensors: collections.abc.Mapping[str, Global___FlatTensor] | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- class TensorsEntry(*, key: str = ..., value: Global___FlatTensor | None = ...)
Bases:
google.protobuf.message.MessageAbstract base class for protocol messages.
Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below.
- key: str
- value() Global___FlatTensor
- HasField(field_name: _HasFieldArgType) bool
Checks if a certain field is set for the message.
For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor,
ValueErrorwill be raised.- Parameters:
field_name (str) – The name of the field to check for presence.
- Returns:
Whether a value has been set for the named field.
- Return type:
bool
- Raises:
ValueError – if the field_name is not a member of this message.
- tensors() google.protobuf.internal.containers.MessageMap[str, Global___FlatTensor]
A name-indexed collection of flat tensor objects
- type viam.gen.service.mlmodel.v1.mlmodel_pb2.Global___FlatTensors = FlatTensors