Open topic with navigation
The AndNotThen engine compares two tracks and produces a track containing records from the first track for events that are not followed within a specified time interval by events in the second track.
The AndNotThen engine enforces the order of events in the two tracks: the first track's event is considered isolated only if an event in the second track does not occur after (or at the same time as) it. If you want to consider events in the second track occurring both before or after events in the first track, use the AndNot engine (see Identify Isolated Events–AndNot Engine).
To identify isolated events
Create a new configuration to send to Media Server with the
process action, or open an existing configuration that you want to modify.
[EventProcessing] section, add a new task by setting the
EventProcessingEngineN parameter. You can give the task any name, for example:
Create a configuration section for the task and set the following parameters:
||The ESP engine to use. Set this parameter to
||The first input track. This track must be an output track produced by another task.|
||The second input track. This track must be an output track produced by another task.|
||The maximum time from the record in the first track to the record in the second track. (The engine compares the timestamp values.) If an event in the second track occurs within this time interval from the event in the first track, the engine discards the event in the first track.|
||(Optional) The minimum time from the record in the first track to the record in the second track. (The engine compares the timestamp values.)|
||(Optional) The name of a Lua script that defines conditions for a discarding a record from the first track. For information about writing the script, see Write a Lua Script for an ESP Engine.|
For more information about these parameters, including the values that they accept, refer to the Media Server Reference.
Save and close the configuration file. HPE recommends that you save your configuration files in the location specified by the
The following example produces an output track containing records produced when a number plate is not detected within thirty seconds (30,000 milliseconds) of a barrier being raised. The AndNot engine takes tracks produced by SceneAnalysis and NumberPlate engines. The SceneAnalysis output track contains a record for every time a barrier is raised. The Numberplate output track contains a record for every number plate detected in the video. The AndNot engine output track contains all records from the SceneAnalysis output track that are not followed within thirty seconds by an event in the NumberPlate track.
[Barrier] Type=andnotthen Input0=sceneanalysis.Result Input1=numberplate.Result MaxTimeInterval=30000ms