Object Detection Module

Classes

class  ObjectData
 Class containing data of a detected object such as its bounding_box, label, id and its 3D position. More...
 
class  CustomBoxObjectData
 Class that store externally detected objects. More...
 
class  CustomMaskObjectData
 Class that store externally detected objects with mask. More...
 
class  Objects
 Class containing the results of the object detection module. More...
 
class  ObjectsBatch
 Class containing batched data of a detected objects from the object detection module. More...
 
class  BatchParameters
 Structure containing a set of parameters for batch object detection. More...
 
class  ObjectDetectionParameters
 Structure containing a set of parameters for the object detection module. More...
 
class  ObjectDetectionRuntimeParameters
 Structure containing a set of runtime parameters for the object detection module. More...
 
class  CustomObjectDetectionProperties
 Structure containing a set of runtime properties of a certain class ID for the object detection module using a custom model. More...
 
class  CustomObjectDetectionRuntimeParameters
 Structure containing a set of runtime parameters for the object detection module using your own model ran by the SDK. More...
 

Enumerations

enum class  OBJECT_CLASS
 Lists available object classes. More...
 
enum class  OBJECT_SUBCLASS
 List available object subclasses. More...
 
enum class  OBJECT_TRACKING_STATE
 Lists the different states of object tracking. More...
 
enum class  OBJECT_ACTION_STATE
 Lists the different states of an object's actions. More...
 
enum class  OBJECT_FILTERING_MODE
 Lists supported bounding box preprocessing. More...
 

Functions

AI_Model_status checkAIModelStatus (AI_MODELS model, int gpu_id=0)
 Checks if a corresponding optimized engine is found for the requested Model based on your rig configuration. More...
 
ERROR_CODE downloadAIModel (sl::AI_MODELS model, int gpu_id=0)
 Downloads the requested model. More...
 
ERROR_CODE optimizeAIModel (sl::AI_MODELS model, int gpu_id=0)
 Optimizes the requested model (and download the model if it is not present on the host). More...
 
String generate_unique_id ()
 Generate a UUID like unique id to help identify and track AI detections. More...
 

Enumeration Type Documentation

◆ OBJECT_CLASS

enum OBJECT_CLASS
strong

Lists available object classes.

Enumerator
PERSON 

For people detection

VEHICLE 

For vehicle detection (cars, trucks, buses, motorcycles, etc.)

BAG 

For bag detection (backpack, handbag, suitcase, etc.)

ANIMAL 

For animal detection (cow, sheep, horse, dog, cat, bird, etc.)

ELECTRONICS 

For electronic device detection (cellphone, laptop, etc.)

FRUIT_VEGETABLE 

For fruit and vegetable detection (banana, apple, orange, carrot, etc.)

SPORT 

For sport-related object detection (sport ball, etc.)

◆ OBJECT_SUBCLASS

enum OBJECT_SUBCLASS
strong

List available object subclasses.

Given as hint, when using object tracking an object can change of sl::OBJECT_SUBCLASS while keeping the same sl::OBJECT_CLASS (i.e.: frame n: MOTORBIKE, frame n+1: BICYCLE).

Enumerator
PERSON 

PERSON

PERSON_HEAD 

PERSON

BICYCLE 

VEHICLE

CAR 

VEHICLE

MOTORBIKE 

VEHICLE

BUS 

VEHICLE

TRUCK 

VEHICLE

BOAT 

VEHICLE

BACKPACK 

BAG

HANDBAG 

BAG

SUITCASE 

BAG

BIRD 

ANIMAL

CAT 

ANIMAL

DOG 

ANIMAL

HORSE 

ANIMAL

SHEEP 

ANIMAL

COW 

ANIMAL

CELLPHONE 

ELECTRONICS

LAPTOP 

ELECTRONICS

BANANA 

FRUIT_VEGETABLE

APPLE 

FRUIT_VEGETABLE

ORANGE 

FRUIT_VEGETABLE

CARROT 

FRUIT_VEGETABLE

SPORTSBALL 

SPORT

◆ OBJECT_TRACKING_STATE

enum OBJECT_TRACKING_STATE
strong

Lists the different states of object tracking.

Enumerator
OFF 

The tracking is not yet initialized.
The object id is not usable.

OK 

The object is tracked.

SEARCHING 

The object could not be detected in the image and is potentially occluded.
The trajectory is estimated.

TERMINATE 

This is the last searching state of the track.
The track will be deleted in the next sl::Camera.retrieveObjects().

◆ OBJECT_ACTION_STATE

enum OBJECT_ACTION_STATE
strong

Lists the different states of an object's actions.

Enumerator
IDLE 

The object is staying static.

MOVING 

The object is moving.

◆ OBJECT_FILTERING_MODE

enum OBJECT_FILTERING_MODE
strong

Lists supported bounding box preprocessing.

Enumerator
NONE 

The ZED SDK will not apply any preprocessing to the detected objects.

NMS3D 

The ZED SDK will remove objects that are in the same 3D position as an already tracked object (independent of class id).

NMS3D_PER_CLASS 

The ZED SDK will remove objects that are in the same 3D position as an already tracked object of the same class id.

Function Documentation

◆ checkAIModelStatus()

AI_Model_status sl::checkAIModelStatus ( AI_MODELS  model,
int  gpu_id = 0 
)

Checks if a corresponding optimized engine is found for the requested Model based on your rig configuration.

Returns
The status of the given model for the specified GPU.

◆ downloadAIModel()

ERROR_CODE sl::downloadAIModel ( sl::AI_MODELS  model,
int  gpu_id = 0 
)

Downloads the requested model.

Returns
sl::ERROR_CODE::SUCCESS if the model is already download.

◆ optimizeAIModel()

ERROR_CODE sl::optimizeAIModel ( sl::AI_MODELS  model,
int  gpu_id = 0 
)

Optimizes the requested model (and download the model if it is not present on the host).

Returns
sl::ERROR_CODE::SUCCESS if the model is well optimized.

◆ generate_unique_id()

String sl::generate_unique_id ( )

Generate a UUID like unique id to help identify and track AI detections.