Filter Objects Node

Filters objects from the current frame metadata if they're within or outside a certain ROI area

Overview

This node can be used if you want to select the objects to process on downstream pipeline nodes based on their current position on image.

Requires a AI Model Node before it in order to function properly. Having a Track Objects Node before is optional, but it's required to get proper results on filtered_object_entered_delta and filtered_object_exited_delta metadata fields.

Inputs & Outputs

  • Inputs : 1, Media Format : Raw Video
  • Outputs : 1, Media Format: Raw Video
  • Output Metadata : Filtered Objects Information

Properties

Property

Value

roi_labels

Comma separated list of labels for each ROI in the rois list above.

Format: label1, label2

Ex: roi_entrance, street_name

rois

Semicolon separated list of areas in the video within which the node tracks these objects.

Format: roi1_pt1_x,roi1_pt1_y,roi1_pt2_x,roi1_pt2_y,roi1_pt3_x,roi1_pt3_y;roi2_pt1_x,roi2_pt1_y,roi2_pt2_x,roi2_pt2_y,roi2_pt3_x,roi2_pt3_y

objects_to_track

Comma separated list of Detected Object labels to filter, 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)

filter_mode

The filter mode to be used. Keeps the objects for downstream nodes depending on whether object's centroid is within or outside the ROI area.

include_within_roi => Include if object's centroid is within ROI

include_outside_roi => Include if object's centroid is outside ROI

Ex: include_within_roi

display_roi

Boolean. If true, ROI area will be drawn on video

Ex. true / false

display_objects

Boolean. If true, Filtered Objects bounding box will be drawn on video

Ex. true / false

Metadata

Metadata Property

Description

nodes.<node_id>

Describes the Filtered objects by this node, and their properties.
Format : as defined in the table below.

<node_id> for Filter Object Nodes is of the form filter_objectsX (ex. filter_objects1)

Example

"nodes": {
    "filter_objects1": {
        "type": "filter_objects",
        "filtered_objects": { ... },
        "filtered_object_count": <int>,
        "filtered_object_entered_delta": <int>,
        "filtered_object_exited_delta": <int>
    }
}

Format

Key

Type

Description

<filtered_objects>

Array of dictionaries

Information about the objects currently in the ROI

filtered_object_count

Integer

Current total number of filtered objects

filtered_object_entered_delta

Integer

Number of objects that entered the filtered_objects list between last frame and the current frame.

Note: An upstream Track Objects Node is required to get proper results.

filtered_object_exited_delta

Integer

Number of objects that left the filtered_objects list between last frame and the current frame.

Nodte: An upstream Track Objects Node is required to get proper results.


Did this page help you?