Metavision SDK contains a set of C++ utility classes aimed at simplifying the implementation of algorithms using data pipelines.
Pipeline class allows you to organize data processing in a pipeline of processing
units, called stages, and control their execution. In a pipeline, each processing stage can have previous stages and next
stages, thus forming a directed graph, for example:
In a pipeline, the goal of each stage is to perform some processes, typically from input data, and output data for the
next stages. The type of input and output data from a stage does not need to be the same.
For example, a stage could take a buffer of
Event2d as input and output a buffer
As another example, a stage could take
EventCD as input and generate
cv::Mat as output.
It is also possible for stages to have no input data or no output data.
Most stages extend from the
The main advantages of using the
Pipeline class are:
it transparently manages data transfer, without unnecessary copies;
it manages multi-threading, allowing to easily run each stage in its own thread if needed.
In the next sections, we will present how to use pipelines, and we will provide some examples of how to build pipelines and create custom stages.
The SDK pipeline class is not the only way to process events with multiple algorithms in a row. As mentioned above,
SDK pipelines simplify the code, but also comes with some limitations (e.g. some pipelines flows can not be implemented).
And if you want to discover our SDK from the ground up, you might prefer to start with some
code samples that don’t use the pipelines. A good example of such a sample is
metavision_psm that leverages