Occupancy Monitor
Extracts queue, dwell and occupancy information based in how long detected objects have been present in a specified region in the video
Overview
The Occupancy Monitor (previously known as Queue Length Counter) node keeps track of the number and how long each detected, tracked object has been present in the specified region in the video, can highlight objects and generate max time alarms, and adds the queue analytics metadata to the frame metadata.
This node generates diverse queue metrics: the total number of objects served, the minimum and maximum queue size, the number of objects that waited on queue more than a pre-specified time (so-called alarms), the minimum, maximum and mean waiting time, etc.
This node requires a AI Model Node and a Track Objects Node before it in order to function properly.
Inputs & Outputs
- Inputs : 1, Media Format : Raw Video
- Outputs : 1, Media Format: Raw Video
- Output Metadata : Queue Information
Properties
Property | Value |
---|---|
roi_labels | Comma separated list of labels for each ROI in the rois list above.Format: label1, label2 Ex: queue_entrance, queue_store |
rois | Semicolon separated list of areas in the video within which the node tracks these objects. If none is specified, the Queue Length Counter tracks objects within the entire frame. Format: left1,top1,right1,bottom1; left2,top2,right2,bottom2 Ex: 10,10,100,100; 200,200,300,300 |
objects_to_track | Comma separated list of Detected Object labels to track, as specified in Model Labels ex. car, person Accepted formats: object_label : any object of this type, with or without a classifier attribute. Example: car object_label.class_type : any object of this type that has a specific classifier attribute. Example: car.red object_label.* : any object of this type that has at least one classifier attribute. Example: car.* (this will match car.red , car.yellow , etc) |
min_queue_activation_time | The minimal time in seconds a object should be present in the queue in order be considered on the analytics. Ex: 10 |
presence_threshold | Creates an alarm and shows an orange bounding box around object if present more than these seconds in the ROI Ex. 60 |
max_occupancy_threshold | Set a trigger when number of objects in the ROI exceeds, or drops below this threshold Ex. 10 Output metadata fields: objects_above_max_occupancy_count occupancy_above_max_threshold_delta occupancy_below_max_threshold_delta |
crossing_buffer | The interval (in seconds) during which an object will not be repeat counted if it leaves and reenters the ROI Ex. 0.5 |
display_roi | Boolean. If true, ROI info will be drawn on video Ex. true / false |
display_objects | Boolean. If true, Object info (presence duration, as well as highlight when it crosses presence threshold) will be drawn on video Ex. true / false |
persistent_storage | Boolean. If true, the following analytics will be stored in disk and restored when the pipeline restarts: [roi_label]['queue_total_objects_served'] [roi_label]['queue_total_max_wait_alarms'] [roi_label]['queue_size_min'] [roi_label]['queue_size_max'] [roi_label]['queue_min_wait_time'] [roi_label]['queue_max_wait_time'] [roi_label]['queue_mean_wait_time'] Ex. true / false |
Metadata
Metadata Property | Description |
---|---|
nodes.<node_id> | Describes the Queue ROIs monitored by this node, and their properties. Format : as defined in the table below. <node_id> for Queue Length Nodes is of the form annotate_queueX (ex. annotate_queue1 ) |
Example
"nodes": {
"annotate_queue1": {
"type": "annotate_queue",
"rois": {
"<roi_label>": {
"coords": [
[468, 172],
[597, 307],
[912, 206],
[1227, 277],
[1247, 135],
[1054, 91],
[946, 121],
[797, 87],
[645, 104],
[468, 172]
],
"current_queue_size": 1,
"max_queue_size": 2,
"max_wait_time": 15,
"mean_wait_time": 12,
"min_queue_size": 0,
"min_wait_time": 5,
"objects_above_max_occupancy_count": 0,
"objects_above_max_waiting_time_count": 1,
"objects_above_max_waiting_time_delta": 0,
"objects_entered_delta": 0,
"objects_exited_delta": 1,
"occupancy_above_max_threshold_delta": false,
"occupancy_below_max_threshold_delta": false,
"total_served": 0,
"wait_alarms": 2,
"current_objects": {
"<object_tracking_id>": {
"first_seen": 19.0,
"first_seen_utc": "2022-10-21T16:16:06.363395Z",
"time_present": 10.0
}
},
"exited_objects": {
"<object_tracking_id>": {
"first_seen": 13.0,
"first_seen_utc": "2022-10-21T16:16:05.072938Z",
"time_present": 15.933
}
}
}
}
}
}
Format
Key | Type | Description |
---|---|---|
<roi_label> | Array of dictionaries | Contains information about this specific ROI |
<roi_label>.coords | Dictionary | Contains the bounding box coordinates that represent this ROI |
<roi_label>.total_served | Integer | Number of objects seen in this ROI since the start of the pipeline |
<roi_label>.wait_alarms | Integer | Total number of wait alarms generated. This counter is incremented every time an object reaches the maximum waiting time defined in the node properties. |
<roi_label>.current_queue_size | Integer | Current number objects in queue |
<roi_label>.objects_entered_delta | Integer | Number of objects that entered the ROI between last frame and this frame |
<roi_label>.objects_exited_delta | Integer | Number of objects that left the ROI between last frame and this frame |
<roi_label>.objects_above_max_waiting_time_count | Integer | Number of objects currently inside the ROI above the specified temporal threshold |
<roi_label>.objects_above_max_waiting_time_delta | Integer | Number of new objects that exceeded the threshold between the last frame and this frame |
<roi_label>.objects_above_max_occupancy_count | Integer | Number of new objects that exceeded the max occupancy threshold |
<roi_label>.occupancy_above_max_threshold_delta | Bool | True when the total number of objects is above the max occupancy threshold |
<roi_label>.occupancy_below_max_threshold_delta | Bool | True when the total number of objects is below the max occupancy threshold |
<roi_label>.min_queue_size | Integer | Minimum number of objects in queue |
<roi_label>.max_queue_size | Integer | Maximum number of objects in queue |
<roi_label>.min_wait_time | Integer | The minimum queue waiting time in seconds |
<roi_label>.max_wait_time | Integer | The maximum queue waiting time in seconds |
<roi_label>.mean_wait_time | Integer | The mean queue waiting time in seconds |
<roi_label>.current_objects | Array of dictionaries | Information about the objects currently in the ROIobject_tracking_id : Unique identifier for a specific object, as specified by object.id property (see AI Model Node )first_seen : Time in seconds (since start of deployment) when the object was first seen in the ROIfirst_seen_utc : UTC time in ISO 8601 format when the object was first seen in the ROItime_present : Time in seconds that the object has been present in the ROI |
<roi_label>.exited_objects | Array of dictionaries | Information about the objects that left the ROI in the previous frameobject_tracking_id : Unique identifier for a specific object, as specified by object.id property (see AI Model Node )first_seen : Time in seconds (since start of deployment) when the object was first seen in the ROIfirst_seen_utc : UTC time in ISO 8601 format when the object was first seen in the ROItime_present : Time in seconds that the object was present in the ROI |
Updated about 2 months ago