Object Detection package

Submodules

i_object_detection module

class dronebuddylib.atoms.objectdetection.i_object_detection.IObjectDetection(engine_configurations: EngineConfigurations)[source]

Bases: IDBLFunction

abstract get_bounding_boxes_of_detected_objects(image) list[source]

Detects objects in the provided image and returns a list of bounding boxes for the detected objects.

Parameters:

image – The image in which to detect objects.

Returns:

A list of bounding boxes for the detected objects.

Return type:

list

abstract get_detected_objects(image) ObjectDetectionResult[source]

Detects objects in the provided image and returns a list of detected objects.

Parameters:

image – The image in which to detect objects.

Returns:

A result containing a list of detected objects.

Return type:

ObjectDetectionResult

mp_object_detection_impl module

class dronebuddylib.atoms.objectdetection.mp_object_detection_impl.MPObjectDetectionImpl(engine_configurations: EngineConfigurations)[source]

Bases: IObjectDetection

get_algorithm_name() str[source]

Returns the algorithm name.

Returns:

The algorithm name.

Return type:

str

get_bounding_boxes_of_detected_objects(image) list[source]

Detects objects in the provided image and returns a list of bounding boxes for the detected objects.

Parameters:

image – The image in which to detect objects.

Returns:

A list of bounding boxes for the detected objects.

Return type:

list

get_class_name() str[source]

Returns the class name.

Returns:

The class name.

Return type:

str

get_detected_objects(image) ObjectDetectionResult[source]

Detects objects in the provided image and returns a result containing a list of detected objects.

Parameters:

image – The image in which to detect objects.

Returns:

A result containing a list of detected objects.

Return type:

ObjectDetectionResult (ObjectDetectionResult)

get_optional_params() list[source]

Returns a list of optional configuration parameters.

Returns:

A list of optional configuration parameters.

Return type:

list

get_required_params() list[source]

Returns a list of required configuration parameters.

Returns:

A list of required configuration parameters.

Return type:

list

object_detection_engine module

class dronebuddylib.atoms.objectdetection.object_detection_engine.ObjectDetectionEngine(algorithm: VisionAlgorithm, config: EngineConfigurations)[source]

Bases: object

get_bounding_boxes_of_detected_objects(frame) list[source]

Retrieves bounding boxes for objects in a given frame using the specified vision algorithm.

Parameters:

frame – The input frame for which bounding boxes are to be retrieved.

Returns:

A list of bounding boxes for the detected objects.

Return type:

list

get_class_name() str[source]

Returns the class name.

Returns:

The class name.

Return type:

str

get_detected_objects(frame) ObjectDetectionResult[source]

Detects objects in a given frame using the specified vision algorithm.

Parameters:

frame – The input frame for which objects need to be detected.

Returns:

The result of the object detection, including a list of detected objects.

Return type:

ObjectDetectionResult (ObjectDetectionResult)

yolo_object_detection_impl module

class dronebuddylib.atoms.objectdetection.yolo_object_detection_impl.YOLOObjectDetectionImpl(engine_configurations: EngineConfigurations)[source]

Bases: IObjectDetection

get_algorithm_name() str[source]

Gets the algorithm name of the object detection implementation.

Returns:

The algorithm name of the object detection implementation.

Return type:

str

get_bounding_boxes_of_detected_objects(image) list[source]

Gets the bounding boxes of objects detected in an image using YOLO V8 object detection engine.

Parameters:

image – The image to detect objects in.

Returns:

A list of bounding boxes corresponding to the objects detected in the image.

Return type:

list

get_class_name() str[source]

Gets the class name of the object detection implementation.

Returns:

The class name of the object detection implementation.

Return type:

str

get_detected_objects(image) ObjectDetectionResult[source]

Detects objects in the given image using YOLO V8 object detection engine.

Parameters:

image – The image to detect objects in.

Returns:

The result of the object detection, including a list of detected objects.

Return type:

ObjectDetectionResult (ObjectDetectionResult)

get_detected_objects_temp(image) ObjectDetectionResult[source]

Detects objects in the given image using YOLO V8 object detection engine.

Parameters:

image – The image to detect objects in.

Returns:

The result of the object detection, including a list of detected objects.

Return type:

ObjectDetectionResult (ObjectDetectionResult)

get_optional_params() list[source]

Gets the list of optional configuration parameters for YOLO V8 object detection engine.

Returns:

The list of optional configuration parameters.

Return type:

list

get_required_params() list[source]

Gets the list of required configuration parameters for YOLO V8 object detection engine.

Returns:

The list of required configuration parameters.

Return type:

list

Module contents