Questions tagged [tbb-flow-graph]

The Flow Graph interface extends capabilities of TBB to allow fast, efficient implementations of dependency graph and data flow algorithms, enabling developers to exploit parallelism at higher levels in their application.

The Flow Graph interface extends capabilities of Intel Threading Building Blocks (TBB) to allow fast, efficient implementations of dependency graph and data flow algorithms, enabling developers to exploit parallelism at higher levels in their application.

47 questions
0
votes
1 answer

How to go about parallelizing my processing using tbb::parallel_for and tbb::dataflow?

I have a source of files that I need to process. From each file, my code generates a variable number of data objects, let's call it N. I have K number of processing objects that can be used to process the N data objects. I'm thinking of doing the…
user3134182
  • 77
  • 1
  • 7
0
votes
1 answer

Intel TBB file access

I am learning to use the Intel TBB library but have run into a weird error. My source node reads data in from a file using fstream but if I try to close the fstream in the class destructor, the program seg faults. Does anyone know why you can't…
JTM
  • 1
  • 1
0
votes
1 answer

Can master thread later join the TBB arena group?

Say, there is a master thread that deploys TBB to spawn additional worker threads, as shown in the code snippet below. The master thread continues with its business, without waiting for arena group to finish. However, the master thread may happen to…
Dmitry Mikushin
  • 1,478
  • 15
  • 16
0
votes
1 answer

Manually manage and update Intel TBB flow graph?

I have successfully prototyped an application using Intel's awesome TBB flow graph library. It seems to work quite well, but now I need to refactor the code into a production-ready version. Previously, I have worked with some larger and more…
DaveStance
  • 421
  • 1
  • 4
  • 17
0
votes
1 answer

Intel TBB computational graph: how to specify input queue capacity of the node

I'm looking for C++ analog of .NET TPL Dataflow library. In TPL Dataflow you can specify parallelism & blocks' capacity options. If the size of the block's input queue reaches it's capacity then the execution of the producer of the corresponding…
Dmitry Katkevich
  • 883
  • 7
  • 26
0
votes
1 answer

Does TBB support OpenCV types?

I am building an image processing pipeline using OpenCV3 and TBB. When passing the image in a flow graph, it is being altered. Here is a sample result of the image when passing through a inverse filter: I wrote a unit test that passes images…
Thibaut Mattio
  • 822
  • 9
  • 17
0
votes
1 answer

TBB C++ multithreading error: No matching function for call

The following C++ code is for Intel TBB. This code was generated by the Flow Graph as well. I have 2 compilation errors: No matching function for call to 'make_edge' No matching function for call to 'make_edge' Here is code with definitions: …
Bryan Downing
  • 207
  • 2
  • 14
0
votes
1 answer

TBB flow graph conditional execution AND multiple in - and outputs

I've read TBB flow graph conditional execution and have a slightly different problem. Is it possible to create a node with multiple inputs and multiple outputs AND to control the execution by a conditional variable? Maybe without ugly casts. I've…
user1587451
  • 978
  • 3
  • 15
  • 30
0
votes
1 answer

Problems with nested object in functional object of the tbb::flow::graph

I have a functional object that I'm using as body for multifunction_node: class module { private: bool valid; QString description; bool hasDetectionBranch; tDataDescription bufData; void* dllObject; //<-- This is a pointer to…
Max Pashkov
  • 404
  • 1
  • 3
  • 12
0
votes
1 answer

Intel Threading Building Blocks, source_node of type std::shared_ptr

In short, i have a data source that provides a shared_ptr type. This pointer seems to go directly out of scope in source_node's operator overload. I have added a fully simplified example demonstrating the issue. My question: what is an elegant why…
user1875444
  • 337
  • 1
  • 2
  • 8
0
votes
1 answer

Threading Building Blocks using std::shared_ptr

i've just started to work with TBB. Have to say it looks very nice, however I ran into the following issue. Using a lambda with std::shared_ptr does not seem to work. source_node(g,[&](int& val) -> bool {val = 0; return…
user1875444
  • 337
  • 1
  • 2
  • 8
0
votes
1 answer

What's the difference between data flow graph and dependence graph in TBB

I have read about data flow graph and dependence graph from the Intel TBB Tutorial, and feel a bit confusing about these two concepts. Can I say that the key difference between data flow graph and dependence graph is whether there are explicitly…
oneg
  • 38
  • 5
0
votes
1 answer

Running multiple tasks in parallel with dependencies

I have number of "sites" (m) that each has to process an event (chunks of data. all available on the get go). Each event (n of them) is sent to each site for processing. So you may think that I have nxm tasks. The order of processing is not…
aivision2020
  • 619
  • 6
  • 14
0
votes
1 answer

Generating thread safe random numbers in Intel TBB function objects (same seed/different seed)

I am using Intel TBB where each thread calls a const function object. the code is as follows #include "process_edge.hpp" // process a vertex in graph template struct my_func{ public: my_func() { } …
pugs
  • 155
  • 1
  • 8
0
votes
2 answers

TBB Flow Graph: how wait for a specific token from the output?

I'm trying to write an adapter to Flow Graph that imitates a pipeline-like synchronous function call. But I don't understand how to block and wait for the output for a specific token. Calling wait_for_all on the graph doesn't help as I don't need to…
lizarisk
  • 7,562
  • 10
  • 46
  • 70