This page uses cookies. For details and possible settings refer to our Privacy Policy.
Continuing to use this page means accepting the processing of cookie files.

Accept (hide info)
POL ENG GER 中文

Data Flow Programming

Important: Adaptive Vision Studio does not require the user to have any experience in low-level programming. Nevertheless, it is a highly specialized tool for professional engineers and a fully-fledged visual programming language. You will need to understand its 4 core concepts: Data, Filters, Connections and Macrofilters.

Data

Adaptive Vision Studio is a data processing environment so data is one of its central concepts. The most important fact about data that has to be understood is the distinction between types (e.g. Point2D) and values (e.g. the coordinates (15.7, 4.1)). Types define the protocol and guide the program construction, whereas values appear during program execution and represent information that is processed.

Adaptive Vision Studio also supports arrays, i.e. variable-sized collection of data items that can be processed together. For each data type, there is a corresponding array type. For example, just as 4 is a value of the Integer type, the collection {1, 5, 4} is a value of the IntegerArray type. Nested arrays are also possible.

Filters

Filters are the basic data processing elements in the data flow driven programming. In a typical machine vision application there is an image acquisition filter at the beginning followed by a sequence of filters that transform the images into regions, contours, geometrical primitives and then into final results such as a pass/fail indication.

A filter usually has several inputs and one or more outputs. Each of the ports has a specific type (e.g. Image, Point2D etc.) and only connections between ports with compatible types can be created. Values of unconnected inputs can be set in the Properties window, which also provides graphical editors for convenient defining of geometrical data. When a filter is invoked its output data can be displayed and analysed in the Data Preview panels.

Connections

Connections transmit data between filters, but they also play an important role in encapsulating much of the complexity typical for low-level programming constructs like loops and conditions. Different types of connections support: basic flow of data , automatic conversions , for-each processing and conditional processing . The good news is that the connection types are inferred automatically on the do what I mean basis.

Macrofilters

Macrofilters provide a means for building large real-life projects. They are reusable subprograms with their own inputs and outputs. Once a macrofilter is created it appears in the Project Explorer window and since then can be used in exactly the same drag and drop way as any regular filter.

Most macrofilters (we call them Steps) are just substitutions of several filters that help to keep the program clean and organized. Some other, however, can create nested data processing loops (Tasks) or direct the program execution into one of several clearly defined conditional paths (Variant Steps). These constructs provide an elegant way to create data flow programs of any complexity.

Data and their types are very similar to what you know from C++. We also have generic collection type – array which is very similar to std::vector. Filters and macrofilters are just equivalents of functions. But, instead of a single returned value they often have several output parameters. Connections correspond to variables, which do not have to be named. On the other hand loops and conditions in Adaptive Vision Studio are quite different to C++ – the former are done with array connections or with Task macrofilters, for the latter there are conditional connections and Variant Step macrofilters.