robokudo.exceptions

RoboKudo-specific exception types.

Exceptions

ColorToDepthRatioMissing

Raised when COLOR2DEPTH_RATIO is required but missing.

UnknownMode

Raised when a configured mode value is not supported.

CVBridgeImageConversionError

Raised when image conversion through the cv_bridge workaround fails.

CVBridgeImageShapeError

Raised when an image array shape cannot represent a ROS image.

CVBridgeROSImageShapeError

Raised when a ROS image message has invalid dimensions.

CVBridgeROSImageStepError

Raised when a ROS image row step cannot contain one pixel row.

CVBridgeROSImagePayloadError

Raised when a ROS image payload is too small for its metadata.

CVBridgeUnsupportedImageData

Raised when image data cannot be mapped to a ROS image encoding.

CVBridgeUnsupportedEncoding

Raised when the cv_bridge workaround receives an unknown encoding.

CVBridgeUnsupportedTargetEncoding

Raised when the cv_bridge workaround cannot produce an encoding.

CASCheckConfigurationError

Raised when a CAS check annotator is not configured correctly.

WorldDescriptorLoadError

Raised when loading a world descriptor fails.

WorldDescriptorBootstrapError

Raised when merging or removing world descriptor content fails.

Classes

RoboKudoError

Base class for RoboKudo-specific errors.

CameraDataMissing

Raised when a camera callback requires a message that was not provided.

StoredCameraTransformFrameMetadataMissing

Raised when stored camera transform frame metadata is missing.

AnalysisPreconditionError

Base class for unmet analysis preconditions.

CASCheckFailed

Raised when a configured CAS check condition fails.

PointCloudThresholdRelation

Relative position of a point cloud size to a configured threshold.

PointCloudThresholdError

Raised when point cloud size violates a configured threshold.

PlaneModelMissing

Raised when an algorithm requires a plane model in the CAS.

PointCloudTooSmallForClustering

Raised when too few points are available for point-cloud clustering.

EmptyPointCloud

Raised when an algorithm requires a non-empty point cloud.

ImageContourMissing

Raised when an algorithm requires an image contour but none was found.

WorldDescriptorError

Base class for world descriptor related errors.

Module Contents

class robokudo.exceptions.RoboKudoError

Bases: krrood.exceptions.DataclassException, abc.ABC

Base class for RoboKudo-specific errors.

exception robokudo.exceptions.ColorToDepthRatioMissing

Bases: RoboKudoError, RuntimeError

Raised when COLOR2DEPTH_RATIO is required but missing.

operation: str = 'continue'
error_message() str
suggest_correction() str
exception robokudo.exceptions.UnknownMode

Bases: RoboKudoError, ValueError

Raised when a configured mode value is not supported.

mode: typing_extensions.Any
context: str = 'RoboKudo component'
error_message() str
suggest_correction() str
class robokudo.exceptions.CameraDataMissing

Bases: RoboKudoError

Raised when a camera callback requires a message that was not provided.

data_name: str
context: str
error_message() str
suggest_correction() str
exception robokudo.exceptions.CVBridgeImageConversionError

Bases: RoboKudoError, ValueError

Raised when image conversion through the cv_bridge workaround fails.

source_encoding: str

Source ROS image encoding.

target_encoding: str

Requested target image encoding.

reason: str

Reason why the image conversion cannot be performed.

error_message() str
suggest_correction() str
exception robokudo.exceptions.CVBridgeImageShapeError

Bases: RoboKudoError, ValueError

Raised when an image array shape cannot represent a ROS image.

shape: tuple[int, Ellipsis]

Image array shape.

dimensions: int

Number of image array dimensions.

error_message() str
suggest_correction() str
exception robokudo.exceptions.CVBridgeROSImageShapeError

Bases: RoboKudoError, ValueError

Raised when a ROS image message has invalid dimensions.

height: int

ROS image height.

width: int

ROS image width.

error_message() str
suggest_correction() str
exception robokudo.exceptions.CVBridgeROSImageStepError

Bases: RoboKudoError, ValueError

Raised when a ROS image row step cannot contain one pixel row.

row_bytes: int

Configured ROS image row size in bytes.

pixel_row_bytes: int

Minimum row size required by width, channels, and dtype.

error_message() str
suggest_correction() str
exception robokudo.exceptions.CVBridgeROSImagePayloadError

Bases: RoboKudoError, ValueError

Raised when a ROS image payload is too small for its metadata.

actual_bytes: int

Number of bytes available in the ROS image payload.

required_bytes: int

Minimum number of bytes required by height and row step.

error_message() str
suggest_correction() str
exception robokudo.exceptions.CVBridgeUnsupportedImageData

Bases: RoboKudoError, ValueError

Raised when image data cannot be mapped to a ROS image encoding.

dtype: str

Image array data type.

channel_count: int

Number of image channels.

error_message() str
suggest_correction() str
exception robokudo.exceptions.CVBridgeUnsupportedEncoding

Bases: RoboKudoError, ValueError

Raised when the cv_bridge workaround receives an unknown encoding.

encoding: str

Unsupported ROS image encoding.

error_message() str
suggest_correction() str
exception robokudo.exceptions.CVBridgeUnsupportedTargetEncoding

Bases: RoboKudoError, ValueError

Raised when the cv_bridge workaround cannot produce an encoding.

target_encoding: str

Requested target image encoding.

error_message() str
suggest_correction() str
class robokudo.exceptions.StoredCameraTransformFrameMetadataMissing

Bases: RoboKudoError

Raised when stored camera transform frame metadata is missing.

error_message() str
suggest_correction() str
class robokudo.exceptions.AnalysisPreconditionError

Bases: RoboKudoError, abc.ABC

Base class for unmet analysis preconditions.

exception robokudo.exceptions.CASCheckConfigurationError

Bases: AnalysisPreconditionError, ValueError

Raised when a CAS check annotator is not configured correctly.

component_name: str
error_message() str
suggest_correction() str
class robokudo.exceptions.CASCheckFailed

Bases: AnalysisPreconditionError

Raised when a configured CAS check condition fails.

reason: str
error_message() str
suggest_correction() str
class robokudo.exceptions.PointCloudThresholdRelation

Bases: enum.StrEnum

Relative position of a point cloud size to a configured threshold.

BELOW = 'below'
ABOVE = 'above'
class robokudo.exceptions.PointCloudThresholdError

Bases: AnalysisPreconditionError

Raised when point cloud size violates a configured threshold.

point_count: int
threshold: int
relation: PointCloudThresholdRelation
error_message() str
suggest_correction() str
class robokudo.exceptions.PlaneModelMissing

Bases: AnalysisPreconditionError

Raised when an algorithm requires a plane model in the CAS.

context: str
error_message() str
suggest_correction() str
class robokudo.exceptions.PointCloudTooSmallForClustering

Bases: AnalysisPreconditionError

Raised when too few points are available for point-cloud clustering.

point_count: int
minimum_point_count: int
context: str = 'point cloud clustering'
error_message() str
suggest_correction() str
class robokudo.exceptions.EmptyPointCloud

Bases: AnalysisPreconditionError

Raised when an algorithm requires a non-empty point cloud.

context: str
error_message() str
suggest_correction() str
class robokudo.exceptions.ImageContourMissing

Bases: AnalysisPreconditionError

Raised when an algorithm requires an image contour but none was found.

context: str
error_message() str
suggest_correction() str
class robokudo.exceptions.WorldDescriptorError

Bases: RoboKudoError, abc.ABC

Base class for world descriptor related errors.

exception robokudo.exceptions.WorldDescriptorLoadError

Bases: WorldDescriptorError, RuntimeError

Raised when loading a world descriptor fails.

ros_package: str
module_name: str
error_message() str
suggest_correction() str
exception robokudo.exceptions.WorldDescriptorBootstrapError

Bases: WorldDescriptorError, RuntimeError

Raised when merging or removing world descriptor content fails.

operation: str
error_message() str
suggest_correction() str