Scene Change Detection
Performs scene change and obstruction detection in a specified region of the video for OSHA compliance and other use cases.
Overview
The Scene Change Detection node keeps track of the changes in the ROI area in order to generate alarms if some anomaly is detected. It performs differentiated handling for objects types allowed to be within the ROI area bypassing the alarm in such case, and adds the OSHA analytics metadata to the frame metadata.
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 |
osha_compliance_type | OSHA compliance monitoring type.stacking (Stacking of boxes/palettes < 7ft high)pathway (Pathways unblocked)fire_extinguisher (Fire Extinguishers unblocked)electrical_panel (Electrical panels unblocked)door (Doors unblocked)other (Other - Generic) |
objects_allowed | Comma separated list of Detected Object labels to track, as specified in Model Labels ex. car, person Objects classes that will bypass the alarm when present in the ROIs. |
change_threshold | Amount of change above which an alarm will be triggered for an ROI, adjusted for ROi size. Increase to reduce false alarms and reduce to detect smaller obstructions Ex. 1.5 |
alarm_buffer_seconds | Number of seconds for which an obstruction should be detected to trigger an alarm Ex. 10 |
reference_update_interval | When set as 0 the reference frame is just loaded in deployment initialization, else updated every X seconds if no alarm is triggered. Ex. 0 |
tracking_mode | The point to be used as tracking point, refers to the position on the object's bounding box.centroid top-center bottom-center left-center right-center all |
display_roi | Boolean. If true, ROI info will be drawn on video. Ex. true / false |
display_objects | Boolean. If true, the object's info is drawn on video. Ex. true / false |
display_debug_info | Boolean. If true, debugging information will be drawn on video for troubleshooting. Ex. true / false |
Metadata
Metadata Property | Description |
---|---|
nodes.<node_id> | <node_id> for the Scene Change Detection is of the form scene_change_detectionX (ex. scene_change_detection1 )Format : as defined in the table below. |
Example
"nodes": {
"scene_change_detection1": {
"type": "scene_change_detection",
"clear_rois_count": 0,
"clear_rois_delta": 0,
"description":"Scene Change Detection",
"exception_alarm_rois_count": 1,
"exception_alarm_rois_delta": 0,
"exception_alarm_rois_ids":[
"polygon1"
],
"exception_allowed_rois_count": 0,
"exception_allowed_rois_delta": 0,
"exception_allowed_rois_ids": [],
"monitoring_type": "pathway",
"reference_image_updated": false,
"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_objects":{
"1496812582445515449":{
"allowed": false,
"first_seen": 248.4,
"first_seen_utc": "2023-02-10T03:32:09.180692Z",
"time_present": 0.867
},
"1496812582445515453":{
"allowed": false,
"first_seen": 249.0,
"first_seen_utc": "2023-02-10T03:32:09.266444Z",
"time_present": 0.267
}
},
"state":"alarm",
"time_since_last_state_change": 37.6,
"type":"pathway",
"change_threshold": 1.0,
"change_score": 0.3
}
}
}
}
Format
Key | Type | Description |
---|---|---|
clear_rois_count | Integer | Number of ROIs that are not triggering any alarm |
clear_rois_delta | Integer | Difference of clear ROIs between last frame and this frame |
description | String | |
exception_alarm_rois_count | Integer | Number of ROIs that are triggering an alarm |
exception_alarm_rois_delta | Integer | Difference of the number of ROIs creating alarm between last frame and this frame |
exception_alarm_rois_ids | List | The IDs of the ROIs that are generating an exception alarm |
exception_allowed_rois_count | Integer | Number of ROIs that are bypassing an alarm because there's an allowed object within the ROI area |
exception_allowed_rois_delta | Integer | Difference of the number of ROIs bypassing alarm between last frame and this frame |
exception_allowed_rois_ids | List | The IDs of the ROIs that are bypassing an exception alarm |
monitoring_type | String | OSHA compliance monitoring type |
reference_image_updated | Boolean | Set as True in the frame the reference image is updated |
<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>.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 Model Inference Node )allowed : Boolean. If the object's class is allowed or not to be within the ROI areafirst_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 |
state | String | The state of the ROI can be either clear or alarm |
time_since_last_state_change | Float | The amount of seconds passed since the state changed |
type | String | OSHA compliance monitoring type |
change_threshold | Float | Amount of change above which an alarm will be triggered for an ROI |
change_score | Float | The change score obtained from the comparison between the reference image and current frame |
Updated about 2 months ago