FindImage¶
ID: Multimedia/FindImage
Searches for a sub-image in each video frame.
Signals¶
VideoFrames¶
The video signal to be analyzed.
Direction: IN
Optional: False
ContainsImage¶
Optional output signal, which stores the number of matches found for each frame.
Direction: OUT
Optional: True
Matches¶
Optional output signal, which stores a MatchList[ImageMatch] object for each frame. The MatchList and ImageMatch classes are described in the API documentation of media related objects. The Matches signal can be fed into the ReportFramesAtStartTrigger trace step template for visualizing found matches.
Direction: OUT
Optional: True
Parameters¶
Image¶
Image to be searched for. The image is converted to grayscale automatically, when the input video signal is a grayscale video. The Image object can be constructed from an image file path. Alternatively, api.DataBrowser.BrowseMultimedia(deviceKey) can be used.
Direction: IN
Mask¶
Optional mask, to limit the area where the image is searched. The Mask object can be constructed from a mask file path. Alternatively, api.DataBrowser.BrowseMultimedia(deviceKey) can be used.
Direction: IN
MaxOccurrences¶
The maximum number of occurrences to find. Set to 0 to find all occurrences. Limiting this number can improve performance when using low thresholds. Defaults to 100.
Direction: IN
Threshold¶
The similarity threshold in percent from 0 to 1. Determines how similar an image must be to be considered a match. A threshold of 1 will search only for perfect matches, which are unlikely in videos, due to compression artifacts. Values of 0.9 (which is the default value) and above will usually find closely matching regions in the image while ignoring noise. Note that a too low threshold might lead to wrong matches.
Direction: IN