You are here: Start » Filter Reference » Common Filter Conventions

Common Filter Conventions

OfArray, OfLoop, OfSeries

Many operators, like the most simple example of AddIntegers, can process a pair of values, entire array or values appearing in consecutive iterations. For all the three case, a standard schema of filter names is used:

  • AddIntegers just adds two values.
  • AddIntegers_OfArray takes one array of integers and returns the sum of its elements.
  • AddIntegers_OfLoop has one input and one output, and sums up the values appearing in consecutive iterations until the current Task is finished.

Some other examples of useful filters:

  • AverageReals_OfArray – computes the average of the values contained in the input array.
  • All – can be used to check if all individual inspections (collected into an array) have passed.
  • FlattenArray – can be used to join results from many arrays into a single array.
  • MaximumImage_OfLoop – can be used to accumulate the brightest pixel value at each location.

There are also some cases when a filter should work in cycles, accumulating data from several iterations before it passes it for further processing. We use OfSeries suffix in that case. There is an input named inSeriesSize and for inSeriesSize - 1 iterations the Nil value is returned, until at one iteration we get the composite result. There are two such filters:

  • JoinImages_OfSeries – can be used to get N images, join them and return as one; useful sometimes with line scan cameras.
  • JoinProfilesIntoImage_OfSeries – can be used in laser triangulation applications to create the composite image of depth from many recognized laser lines.

Variants of an Operation

In some cases there is an operation that can be implemented in several different ways. In Aurora Vision Studio we then have several different filters with different suffixes. For example:

Wrappers on Third Party APIs

There can also be very similar functions that come from different third party libraries. The most typical example are the GrabImage filters coming from SDKs of different camera manufacturers. We use different prefixes to distinguish the filters:

Single, Exactly N and Multiple Objects

When using tools that detect objects, one particular question has to be answered by the user: "How many objects do I expect in the result?". Aurora Vision Studio emphasizes strong typing of data, so at each point we need to know if there is going to be a single object or an array. For example, we have two variants of each template matching filter:

Filter returning a single object (Rectangle2D)

Filter returning an array of objects (Rectangle2DArray)

Please also note, that there can be some parameters, like inMinDistance (minimum distance between objects), that make sense only in one of the functions.

There are also tools, for which we can achieve better reliability, if we know how many, exactly, objects we are looking for. It is for example much easier to divide a text into characters, if we know that this is a date in the format YYYY/MM/DD and there will be exactly 10 characters. In such cases we use "ExactlyN" phrase. Here is another remarkable example from 1D Edge Detection:

Detects a single edge point or returns Nil if it can not be found (Point2D?).

Detects all edges that meet the specified criteria (Point2DArray).

Detects the specified number of edges or returns Nil if this number of edges can not be found (Point2DArray?)

Previous: Filter Reference Next: Library: GenICam and GigE Vision