viam.proto.component.camera

@generated by Viam. Do not edit manually!

Classes

CameraServiceBase

Helper class that provides a standard way to create an ABC using

CameraServiceStub

UnimplementedCameraServiceBase

Helper class that provides a standard way to create an ABC using

DistortionParameters

Abstract base class for protocol messages.

Format

GetImageRequest

Abstract base class for protocol messages.

GetImageResponse

Abstract base class for protocol messages.

GetImagesRequest

Abstract base class for protocol messages.

GetImagesResponse

Abstract base class for protocol messages.

GetPointCloudRequest

Abstract base class for protocol messages.

GetPointCloudResponse

Abstract base class for protocol messages.

GetPropertiesRequest

Abstract base class for protocol messages.

GetPropertiesResponse

Abstract base class for protocol messages.

Image

Abstract base class for protocol messages.

IntrinsicParameters

Abstract base class for protocol messages.

Property

Abstract base class for protocol messages.

RenderFrameRequest

Abstract base class for protocol messages.

Webcam

Abstract base class for protocol messages.

Webcams

Abstract base class for protocol messages.

Package Contents

class viam.proto.component.camera.CameraServiceBase[source]

Bases: abc.ABC

Helper class that provides a standard way to create an ABC using inheritance.

abstract GetImage(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.GetImageRequest, component.camera.v1.camera_pb2.GetImageResponse]) None[source]
Async:

abstract GetImages(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.GetImagesRequest, component.camera.v1.camera_pb2.GetImagesResponse]) None[source]
Async:

abstract RenderFrame(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.RenderFrameRequest, google.api.httpbody_pb2.HttpBody]) None[source]
Async:

abstract GetPointCloud(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.GetPointCloudRequest, component.camera.v1.camera_pb2.GetPointCloudResponse]) None[source]
Async:

abstract GetProperties(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.GetPropertiesRequest, component.camera.v1.camera_pb2.GetPropertiesResponse]) None[source]
Async:

abstract DoCommand(stream: grpclib.server.Stream[common.v1.common_pb2.DoCommandRequest, common.v1.common_pb2.DoCommandResponse]) None[source]
Async:

abstract GetGeometries(stream: grpclib.server.Stream[common.v1.common_pb2.GetGeometriesRequest, common.v1.common_pb2.GetGeometriesResponse]) None[source]
Async:

__mapping__() Dict[str, grpclib.const.Handler][source]
class viam.proto.component.camera.CameraServiceStub(channel: grpclib.client.Channel)[source]
GetImage
GetImages
RenderFrame
GetPointCloud
GetProperties
DoCommand
GetGeometries
class viam.proto.component.camera.UnimplementedCameraServiceBase[source]

Bases: CameraServiceBase

Helper class that provides a standard way to create an ABC using inheritance.

async GetImage(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.GetImageRequest, component.camera.v1.camera_pb2.GetImageResponse]) None[source]
async GetImages(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.GetImagesRequest, component.camera.v1.camera_pb2.GetImagesResponse]) None[source]
async RenderFrame(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.RenderFrameRequest, google.api.httpbody_pb2.HttpBody]) None[source]
async GetPointCloud(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.GetPointCloudRequest, component.camera.v1.camera_pb2.GetPointCloudResponse]) None[source]
async GetProperties(stream: grpclib.server.Stream[component.camera.v1.camera_pb2.GetPropertiesRequest, component.camera.v1.camera_pb2.GetPropertiesResponse]) None[source]
async DoCommand(stream: grpclib.server.Stream[common.v1.common_pb2.DoCommandRequest, common.v1.common_pb2.DoCommandResponse]) None[source]
async GetGeometries(stream: grpclib.server.Stream[common.v1.common_pb2.GetGeometriesRequest, common.v1.common_pb2.GetGeometriesResponse]) None[source]
class viam.proto.component.camera.DistortionParameters(*, model: str = ..., parameters: collections.abc.Iterable[float] | None = ...)

Bases: google.protobuf.message.Message

Abstract 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.

model: str
property parameters: google.protobuf.internal.containers.RepeatedScalarFieldContainer[float]
class viam.proto.component.camera.Format

Bases: _Format

class viam.proto.component.camera.GetImageRequest(*, name: str = ..., mime_type: str = ..., extra: google.protobuf.struct_pb2.Struct | None = ...)

Bases: google.protobuf.message.Message

Abstract 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 a camera

mime_type: str

Requested MIME type of response

property extra: google.protobuf.struct_pb2.Struct

Additional arguments to the method

HasField(field_name: Literal['extra', b'extra']) 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, ValueError will 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.

class viam.proto.component.camera.GetImageResponse(*, mime_type: str = ..., image: bytes = ...)

Bases: google.protobuf.message.Message

Abstract 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.

mime_type: str

Actual MIME type of response

image: bytes

Frame in bytes

class viam.proto.component.camera.GetImagesRequest(*, name: str = ...)

Bases: google.protobuf.message.Message

Abstract 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 a camera

class viam.proto.component.camera.GetImagesResponse(*, images: collections.abc.Iterable[global___Image] | None = ..., response_metadata: viam.gen.common.v1.common_pb2.ResponseMetadata | None = ...)

Bases: google.protobuf.message.Message

Abstract 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.

property images: google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___Image]

list of images returned from the camera system

property response_metadata: viam.gen.common.v1.common_pb2.ResponseMetadata

contains timestamp data

HasField(field_name: Literal['response_metadata', b'response_metadata']) 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, ValueError will 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.

class viam.proto.component.camera.GetPointCloudRequest(*, name: str = ..., mime_type: str = ..., extra: google.protobuf.struct_pb2.Struct | None = ...)

Bases: google.protobuf.message.Message

Abstract 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 a camera

mime_type: str

Requested MIME type of response

property extra: google.protobuf.struct_pb2.Struct

Additional arguments to the method

HasField(field_name: Literal['extra', b'extra']) 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, ValueError will 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.

class viam.proto.component.camera.GetPointCloudResponse(*, mime_type: str = ..., point_cloud: bytes = ...)

Bases: google.protobuf.message.Message

Abstract 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.

mime_type: str

Actual MIME type of response

point_cloud: bytes

Frame in bytes

class viam.proto.component.camera.GetPropertiesRequest(*, name: str = ...)

Bases: google.protobuf.message.Message

Abstract 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 a camera

class viam.proto.component.camera.GetPropertiesResponse(*, supports_pcd: bool = ..., intrinsic_parameters: global___IntrinsicParameters | None = ..., distortion_parameters: global___DistortionParameters | None = ..., mime_types: collections.abc.Iterable[str] | None = ..., frame_rate: float | None = ...)

Bases: google.protobuf.message.Message

Abstract 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.

supports_pcd: bool

A boolean property determining whether the camera supports the return of pointcloud data

frame_rate: float

Optional camera frame rate for image capture timing

property intrinsic_parameters: global___IntrinsicParameters

Parameters for doing a perspective of a 3D scene to a 2D plane If camera does not provide intrinsic parameters, leave the field empty Initializing the parameters with 0-values is considered an error

property distortion_parameters: global___DistortionParameters

Parameters for modeling lens distortion in cameras If camera does not provide distortion parameters, leave the field empty Initializing the parameters with 0-values is considered an error

property mime_types: google.protobuf.internal.containers.RepeatedScalarFieldContainer[str]

Supported MIME types by the camera

HasField(field_name: Literal['_frame_rate', b'_frame_rate', 'distortion_parameters', b'distortion_parameters', 'frame_rate', b'frame_rate', 'intrinsic_parameters', b'intrinsic_parameters']) 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, ValueError will 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: Literal['_frame_rate', b'_frame_rate']) Literal['frame_rate'] | 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

class viam.proto.component.camera.Image(*, source_name: str = ..., format: global___Format = ..., image: bytes = ...)

Bases: google.protobuf.message.Message

Abstract 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.

source_name: str

the name of the sensor where the image came from

format: global___Format

format of the response image bytes

image: bytes

image in bytes

class viam.proto.component.camera.IntrinsicParameters(*, width_px: int = ..., height_px: int = ..., focal_x_px: float = ..., focal_y_px: float = ..., center_x_px: float = ..., center_y_px: float = ...)

Bases: google.protobuf.message.Message

Abstract 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.

width_px: int
height_px: int
focal_x_px: float
focal_y_px: float
center_x_px: float
center_y_px: float
class viam.proto.component.camera.Property(*, width_px: int = ..., height_px: int = ..., frame_format: str = ..., frame_rate: float = ...)

Bases: google.protobuf.message.Message

Abstract 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.

width_px: int

Video resolution width in px

height_px: int

Video resolution height in px

frame_format: str

Video frame format

frame_rate: float

Video frame rate in fps

class viam.proto.component.camera.RenderFrameRequest(*, name: str = ..., mime_type: str = ..., extra: google.protobuf.struct_pb2.Struct | None = ...)

Bases: google.protobuf.message.Message

Abstract 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 a camera

mime_type: str

Requested MIME type of response

property extra: google.protobuf.struct_pb2.Struct

Additional arguments to the method

HasField(field_name: Literal['extra', b'extra']) 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, ValueError will 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.

class viam.proto.component.camera.Webcam(*, label: str = ..., status: str = ..., properties: collections.abc.Iterable[global___Property] | None = ..., name: str = ..., id: str = ...)

Bases: google.protobuf.message.Message

Abstract 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.

label: str

Camera driver label (for internal use only)

status: str

Camera driver status

name: str

Camera human-readable driver name

id: str

Camera unique identifier

property properties: google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___Property]

Camera properties

class viam.proto.component.camera.Webcams(*, webcams: collections.abc.Iterable[global___Webcam] | None = ...)

Bases: google.protobuf.message.Message

Abstract 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.

property webcams: google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___Webcam]