22std::string quote(std::string
const&
s) {
return R
"(")" + s + R"(")"; }
27 std::vector<std::pair<int, int>>
const&
edges)
29 out <<
"digraph structs {\n";
30 out <<
" node[shape=record]\n";
31 for (
auto& spec : specs) {
32 std::string
labels =
" xlabel=\"";
33 for (
auto&
label : spec.labels) {
38 out << fmt::format(
" \"{}\" [label=\"{}\"{}];\n", spec.name, spec.name,
labels !=
" xlabel=\"\"" ?
labels :
"");
41 out << fmt::format(
" \"{}\" -> \"{}\"\n", specs[
e.first].name, specs[
e.second].name);
49 out << R
"GRAPHVIZ(digraph structs {
52 std::map<std::string, std::string> outputChannel2Device;
53 std::map<std::string, unsigned int> outputChannel2Port;
55 for (
auto& spec : specs) {
57 out <<
" " << quote(
id) << R
"( [label="{{)";
58 bool firstInput =
true;
59 for (
auto&& input : spec.inputChannels) {
60 if (firstInput ==
false) {
64 out <<
"<" << input.name <<
">" << input.name;
67 auto totalChannels = spec.inputChannels.size() +
68 spec.outputChannels.size();
69 out <<
id <<
"(" << totalChannels <<
")";
71 bool firstOutput =
true;
72 for (
auto&&
output : spec.outputChannels) {
73 outputChannel2Device.insert(std::make_pair(
output.name,
id));
74 outputChannel2Port.insert(std::make_pair(
output.name,
output.port));
75 if (firstOutput ==
false) {
84 for (
auto& spec : specs) {
85 for (
auto& input : spec.inputChannels) {
87 auto outputName = input.name;
88 out <<
" " << quote(outputChannel2Device[outputName]) <<
":" << quote(outputName) <<
"-> " << quote(spec.id)
89 <<
":" << quote(input.name) << R
"( [label=")" << input.port << R"(")"
Timeframe settings Average distance in cm of events merged into Randomize distance around average distance of merged events Simulate correct bunch interactions instead of placing only the average number of events A value[n] sets TFlen for[n] collisions in Number of bunches per trainsort Number of bunch trains Instantaneous interaction rate Do not simulate border Total number of collisions to be placed in the interior of all time Do not select random but walk over array of events in stride steps h Event generator settings h configStandalone Use CPU for GPU Force usage of the specified GPU device no CPU fallback Continue processing after an error s
Timeframe settings Average distance in cm of events merged into Randomize distance around average distance of merged events Simulate correct bunch interactions instead of placing only the average number of events A value[n] sets TFlen for[n] collisions in Number of bunches per trainsort Number of bunch trains Instantaneous interaction rate Do not simulate border Total number of collisions to be placed in the interior of all time Do not select random but walk over array of events in stride steps h Event generator settings h configStandalone Use CPU for GPU Force usage of the specified GPU device no CPU fallback Continue processing after an error First event to Number of events to Number of iterations to Number of iterations to Number of initial iterations excluded from const char e
std::vector< o2::MCCompLabel > labels
std::vector< SidecarEdge > edges
GLuint GLsizei const GLchar * label
Defining ITS Vertex explicitly as messageable.
static void dumpDeviceSpec2Graphviz(std::ostream &, const Devices &specs)
Helper to dump a set of devices as a graphviz file.
static void dumpDataProcessorSpec2Graphviz(std::ostream &, const WorkflowSpec &specs, std::vector< std::pair< int, int > > const &edges={})
Helper to dump a workflow as a graphviz file.