Open topic with navigation

# Identify Isolated Events–AndNot Engine

The AndNot engine compares two tracks to identify when an event occurs in the first track and nothing happens in the second track.

For example, you can identify all the occasions when a company logo appears in a video without mention of the company name in the speech:

1. An object recognition task recognizes the logo.
2. A speech-to-text task produces a transcript of the speech.
3. An ESP filter task extracts records from the speech-to-text output that contain the company name and outputs them to a new track.
4. An ESP task (using the AndNot engine) uses the output tracks from the object recognition and filter tasks. It compares events in both tracks and identifies isolated events in the first track (the object track). The engine produces an output track containing records from the object track for when a logo is recognized but is not followed within the specified time interval by the company name in the filtered SpeechToText track.

NOTE:

The AndNot engine does not enforce an 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 either before or after it. If you want to consider only events in the second track occurring after (or at the same time as) events in the first track, use the AndNotThen engine (see Identify Isolated Events–AndNotThen Engine).

To identify isolated events

1. Create a new configuration to send to HPE Media Server with the `process` action, or open an existing configuration that you want to modify.

2. In the `[EventProcessing]` section, add a new task by setting the `EventProcessingEngineN` parameter. You can give the task any name, for example:

       [EventProcessing]
       EventProcessingEngine0=IsolatedEvents

3. Create a new configuration section for the task and set the following parameters:

   `Type` | The ESP engine to use. Set this parameter to `and` `Not`.
   `Input0` | The first input track. This track must be an output track produced by another task.
   `Input1` | The second input track. This track must be an output track produced by another task.
   `MaxTimeInterval` | The maximum time in milliseconds 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. If you are processing images or documents this parameter is ignored.
   `MinTimeInterval` | (Optional) The minimum time in milliseconds from the record in the first track to the record in the second track, for the two records to be considered a pair. (The engine compares the timestamp values.) The default value is the negative of the `MaxTimeInterval` value, meaning that the event in the second track can occur before the event in the first track (up to the specified number of milliseconds). If you are processing images or documents this parameter is ignored.
   `LuaScript` | (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 details about the parameters, including the values that they accept, refer to the HPE Media Server Reference.

4. Save and close the configuration file. HPE recommends that you save your configuration files in the location specified by the `ConfigDirectory` parameter.

Example

The following example produces an output track called `LogoWithoutCompanyName.Output`. This track contains records from an object recognition task that indicate when the company logo was recognized. However, the track only contains the appearances when the company name was not mentioned in the audio within five seconds.

    [EventProcessing]
    EventProcessingEngine0=FilterAudio
    EventProcessingEngine1=LogoWithoutCompanyName

    [FilterAudio]
    Type=filter
    ...

    [LogoWithoutCompanyName]
    Type=andnot
    Input0=RecognizeCompanyLogo.Result
    Input1=FilterAudio.output
    MaxTimeInterval=5000

© 2017 Hewlett Packard Enterprise Development LP | Send documentation feedback to HPE Close Send documentation feedback To open the configured email client on this computer, open an email window. Otherwise, copy the information below to a web mail client, and send this email to AutonomyTPFeedback@hpe.com. We appreciate your feedback! Product: Topic Title: Help Topic: Feedback:

_HP_HTML5_bannerTitle.htm