Commit 4f7a6b24 authored by Leo Gordon's avatar Leo Gordon
Browse files

A walkthrough-type test for visualize_jobs.pl

parent 60fd7a95
......@@ -50,7 +50,8 @@ sub main {
'accu_values|values!' => \$self->{'show_accu_values'}, # show accu keys & values (implies -accu_keys)
'accu_pointers|accu_ptrs!' => \$self->{'show_accu_pointers'}, # (attempt to) show which accu values come from which jobs
'o|out|output=s' => \$self->{'output'},
'o|out|output=s' => \$self->{'output'}, # output file name
'f|format=s' => \$self->{'format'}, # output format (if not guessable from -output)
'dot_input=s' => \$self->{'dot_input'}, # filename to store the intermediate dot input (valuable for debugging)
'h|help' => \$self->{'help'},
......
#!/usr/bin/env perl
# Copyright [1999-2015] Wellcome Trust Sanger Institute and the EMBL-European Bioinformatics Institute
# Copyright [2016-2017] EMBL-European Bioinformatics Institute
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
use strict;
use warnings;
use Getopt::Long qw(:config pass_through);
use File::Temp qw/tempfile/; # temporary local file to compare to the expected diagram
use Test::File::Contents; # import file_contents_eq_or_diff()
use Test::More;
use Bio::EnsEMBL::Hive::Utils::Config; # for Bio::EnsEMBL::Hive::Utils::Config->default_system_config
use Bio::EnsEMBL::Hive::Utils::Test qw(runWorker beekeeper run_sql_on_db get_test_url_or_die);
# eHive needs this to initialize the pipeline (and run db_cmd.pl)
$ENV{'EHIVE_ROOT_DIR'} ||= File::Basename::dirname( File::Basename::dirname( File::Basename::dirname( Cwd::realpath($0) ) ) );
my ($generate_files, $generate_format) = (0, 'dot');
GetOptions( # Example: "visualize_jobs.t -generate -format png" would yield a visualized walk-through
'generate!' => \$generate_files,
'format=s' => \$generate_format,
);
my $vj_url = get_test_url_or_die(-tag => 'vj', -no_user_prefix => 1);
my $ref_output_location = $ENV{'EHIVE_ROOT_DIR'}.'/t/03.scripts/visualize_jobs';
# A temporary file to store the output of generate_graph.pl
my ($fh, $generated_diagram_filename) = tempfile(UNLINK => 1);
close($fh);
sub test_command {
my $cmd_array = shift;
ok(!system(@$cmd_array), 'Can run '.join(' ', @$cmd_array));
}
my $conf_2_plan = {
'LongMult::PipeConfig::LongMult_conf' => [
[ ], # an empty list effectively skips running a worker (which is useful in the beginning)
[ 1, [ qw(-analyses_pattern add_together -sync) ] ],
[ 2, [ qw(-sync) ] ],
[ 4 ],
[ 10, 11 ],
[ 5, 6 ],
[ 8, 12, [ qw(-analyses_pattern add_together -sync) ] ],
[ 9, [ qw(-analyses_pattern add_together -sync) ] ],
[ 7, [ qw(-sync) ] ],
[ 3, [ qw(-sync) ] ],
],
};
foreach my $conf (keys %$conf_2_plan) {
subtest $conf, sub {
my $module_name = 'Bio::EnsEMBL::Hive::Examples::'.$conf;
my $jobs_in_order = $conf_2_plan->{$conf};
my @init_pipeline_args = ( $ENV{'EHIVE_ROOT_DIR'}.'/scripts/init_pipeline.pl',
$module_name,
-pipeline_url => $vj_url,
-hive_force_init => 1,
-tweak => 'pipeline.param[take_time]=0'
);
test_command(\@init_pipeline_args);
my $pipeline_name = Bio::EnsEMBL::Hive::HivePipeline->new( -url => $vj_url )->hive_pipeline_name;
my $ref_directory = "${ref_output_location}/${pipeline_name}";
if($generate_files) {
system('mkdir', '-p', $ref_directory);
}
foreach my $step_number (0..@$jobs_in_order-1) {
foreach my $job_id_or_bk_args ( @{ $jobs_in_order->[$step_number] } ) {
if( ref($job_id_or_bk_args) ) {
beekeeper($vj_url, $job_id_or_bk_args );
} else {
runWorker($vj_url, [ -job_id => $job_id_or_bk_args ] );
}
}
my @visualize_jobs_args = ( $ENV{'EHIVE_ROOT_DIR'}.'/scripts/visualize_jobs.pl',
# -config_file => Bio::EnsEMBL::Hive::Utils::Config->default_system_config, ## FIXME: not supported yet
-url => $vj_url,
-accu_values,
($generate_format eq 'dot')
? (
-output => '/dev/null',
-format => 'canon',
-dot_input => $generated_diagram_filename,
) : (
-format => $generate_format,
-output => $generated_diagram_filename,
)
);
test_command(\@visualize_jobs_args);
my $ref_filename = sprintf("%s/%s_jobs_%02d.%s", $ref_directory, $pipeline_name, $step_number+1, $generate_format);
if($generate_files) {
system('cp', '-f', $generated_diagram_filename, $ref_filename);
} else {
files_eq_or_diff($generated_diagram_filename, $ref_filename);
}
}
}
}
run_sql_on_db($vj_url, 'DROP DATABASE');
done_testing();
digraph test {
ratio="compress"; name = "JobDependencyGraph"; pad = "0"; ranksep = "1.4"; remincross = "true";
job_1__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>1</i></td></tr><tr><td>a_multiplier:</td><td> 9650156169</td></tr><tr><td>b_multiplier:</td><td> 327358788</td></tr></table>>, shape="box3d", style="filled"];
job_2__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>2</i></td></tr><tr><td>a_multiplier:</td><td> 327358788</td></tr><tr><td>b_multiplier:</td><td> 9650156169</td></tr></table>>, shape="box3d", style="filled"];
subgraph cluster_long_mult {
label="long_mult";
style="bold,filled";
colorscheme=pastel19;
fillcolor=3;
subgraph cluster_take_b_apart {
label="take_b_apart";
style="rounded,filled";
colorscheme=X11;
fillcolor=green;
job_1__long_mult;
job_2__long_mult;
}
}
}
digraph test {
ratio="compress"; name = "JobDependencyGraph"; pad = "0"; ranksep = "1.4"; remincross = "true";
job_1__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>1</i></td></tr><tr><td>a_multiplier:</td><td> 9650156169</td></tr><tr><td>b_multiplier:</td><td> 327358788</td></tr></table>>, shape="box3d", style="filled"];
job_3__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>3</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr></table>>, shape="box3d", style="filled"];
job_4__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>4</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 2</td></tr></table>>, shape="box3d", style="filled"];
semaphore_1__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 5</i></b></font></td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_5__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>5</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 3</td></tr></table>>, shape="box3d", style="filled"];
job_6__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>6</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
job_7__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>7</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 7</td></tr></table>>, shape="box3d", style="filled"];
job_8__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>8</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 8</td></tr></table>>, shape="box3d", style="filled"];
job_2__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>2</i></td></tr><tr><td>a_multiplier:</td><td> 327358788</td></tr><tr><td>b_multiplier:</td><td> 9650156169</td></tr></table>>, shape="box3d", style="filled"];
job_1__long_mult -> job_3__long_mult [color="blue"];
job_1__long_mult -> job_4__long_mult [color="blue"];
job_1__long_mult -> job_5__long_mult [color="blue"];
job_1__long_mult -> job_6__long_mult [color="blue"];
job_1__long_mult -> job_7__long_mult [color="blue"];
job_1__long_mult -> job_8__long_mult [color="blue"];
job_4__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_5__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_6__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_7__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_8__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
semaphore_1__long_mult -> job_3__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
subgraph cluster_long_mult {
label="long_mult";
style="bold,filled";
colorscheme=pastel19;
fillcolor=3;
subgraph cluster_add_together {
label="add_together";
style="rounded,filled";
colorscheme=X11;
fillcolor=grey;
job_3__long_mult;
semaphore_1__long_mult;
}
subgraph cluster_part_multiply {
label="part_multiply";
style="rounded,filled";
colorscheme=X11;
fillcolor=green;
job_4__long_mult;
job_5__long_mult;
job_6__long_mult;
job_7__long_mult;
job_8__long_mult;
}
subgraph cluster_take_b_apart {
label="take_b_apart";
style="rounded,filled";
colorscheme=X11;
fillcolor=yellow;
job_1__long_mult;
job_2__long_mult;
}
}
}
digraph test {
ratio="compress"; name = "JobDependencyGraph"; pad = "0"; ranksep = "1.4"; remincross = "true";
job_1__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>1</i></td></tr><tr><td>a_multiplier:</td><td> 9650156169</td></tr><tr><td>b_multiplier:</td><td> 327358788</td></tr></table>>, shape="box3d", style="filled"];
job_3__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>3</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr></table>>, shape="box3d", style="filled"];
job_4__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>4</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 2</td></tr></table>>, shape="box3d", style="filled"];
semaphore_1__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 5</i></b></font></td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_5__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>5</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 3</td></tr></table>>, shape="box3d", style="filled"];
job_6__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>6</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
job_7__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>7</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 7</td></tr></table>>, shape="box3d", style="filled"];
job_8__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>8</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 8</td></tr></table>>, shape="box3d", style="filled"];
job_2__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>2</i></td></tr><tr><td>a_multiplier:</td><td> 327358788</td></tr><tr><td>b_multiplier:</td><td> 9650156169</td></tr></table>>, shape="box3d", style="filled"];
job_9__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>9</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr></table>>, shape="box3d", style="filled"];
job_10__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>10</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
semaphore_2__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 3</i></b></font></td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_11__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>11</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 6</td></tr></table>>, shape="box3d", style="filled"];
job_12__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>12</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 9</td></tr></table>>, shape="box3d", style="filled"];
job_10__long_mult -> semaphore_2__long_mult [arrowhead="tee", color="red", style="dashed"];
job_11__long_mult -> semaphore_2__long_mult [arrowhead="tee", color="red", style="dashed"];
job_12__long_mult -> semaphore_2__long_mult [arrowhead="tee", color="red", style="dashed"];
job_1__long_mult -> job_3__long_mult [color="blue"];
job_1__long_mult -> job_4__long_mult [color="blue"];
job_1__long_mult -> job_5__long_mult [color="blue"];
job_1__long_mult -> job_6__long_mult [color="blue"];
job_1__long_mult -> job_7__long_mult [color="blue"];
job_1__long_mult -> job_8__long_mult [color="blue"];
job_2__long_mult -> job_10__long_mult [color="blue"];
job_2__long_mult -> job_11__long_mult [color="blue"];
job_2__long_mult -> job_12__long_mult [color="blue"];
job_2__long_mult -> job_9__long_mult [color="blue"];
job_4__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_5__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_6__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_7__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_8__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
semaphore_1__long_mult -> job_3__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
semaphore_2__long_mult -> job_9__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
subgraph cluster_long_mult {
label="long_mult";
style="bold,filled";
colorscheme=pastel19;
fillcolor=3;
subgraph cluster_add_together {
label="add_together";
style="rounded,filled";
colorscheme=X11;
fillcolor=grey;
job_3__long_mult;
job_9__long_mult;
semaphore_1__long_mult;
semaphore_2__long_mult;
}
subgraph cluster_part_multiply {
label="part_multiply";
style="rounded,filled";
colorscheme=X11;
fillcolor=green;
job_10__long_mult;
job_11__long_mult;
job_12__long_mult;
job_4__long_mult;
job_5__long_mult;
job_6__long_mult;
job_7__long_mult;
job_8__long_mult;
}
subgraph cluster_take_b_apart {
label="take_b_apart";
style="rounded,filled";
colorscheme=X11;
fillcolor=DeepSkyBlue;
job_1__long_mult;
job_2__long_mult;
}
}
}
digraph test {
ratio="compress"; name = "JobDependencyGraph"; pad = "0"; ranksep = "1.4"; remincross = "true";
job_1__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>1</i></td></tr><tr><td>a_multiplier:</td><td> 9650156169</td></tr><tr><td>b_multiplier:</td><td> 327358788</td></tr></table>>, shape="box3d", style="filled"];
job_3__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>3</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr></table>>, shape="box3d", style="filled"];
job_4__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>4</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 2</td></tr></table>>, shape="box3d", style="filled"];
semaphore_1__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 4</i></b></font></td></tr><tr><td colspan="3">&nbsp;</td></tr><tr><td></td><td><b><u>partial_product</u></b></td><td></td></tr><tr><td port="semaphore_1__long_mult_partial_product_4">{2}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;19300312338&quot;</td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_5__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>5</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 3</td></tr></table>>, shape="box3d", style="filled"];
job_6__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>6</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
job_7__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>7</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 7</td></tr></table>>, shape="box3d", style="filled"];
job_8__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>8</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 8</td></tr></table>>, shape="box3d", style="filled"];
job_2__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>2</i></td></tr><tr><td>a_multiplier:</td><td> 327358788</td></tr><tr><td>b_multiplier:</td><td> 9650156169</td></tr></table>>, shape="box3d", style="filled"];
job_9__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>9</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr></table>>, shape="box3d", style="filled"];
job_10__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>10</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
semaphore_2__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 3</i></b></font></td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_11__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>11</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 6</td></tr></table>>, shape="box3d", style="filled"];
job_12__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>12</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 9</td></tr></table>>, shape="box3d", style="filled"];
job_10__long_mult -> semaphore_2__long_mult [arrowhead="tee", color="red", style="dashed"];
job_11__long_mult -> semaphore_2__long_mult [arrowhead="tee", color="red", style="dashed"];
job_12__long_mult -> semaphore_2__long_mult [arrowhead="tee", color="red", style="dashed"];
job_1__long_mult -> job_3__long_mult [color="blue"];
job_1__long_mult -> job_4__long_mult [color="blue"];
job_1__long_mult -> job_5__long_mult [color="blue"];
job_1__long_mult -> job_6__long_mult [color="blue"];
job_1__long_mult -> job_7__long_mult [color="blue"];
job_1__long_mult -> job_8__long_mult [color="blue"];
job_2__long_mult -> job_10__long_mult [color="blue"];
job_2__long_mult -> job_11__long_mult [color="blue"];
job_2__long_mult -> job_12__long_mult [color="blue"];
job_2__long_mult -> job_9__long_mult [color="blue"];
job_4__long_mult -> semaphore_1__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_5__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_6__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_7__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_8__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
semaphore_1__long_mult -> job_3__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
semaphore_2__long_mult -> job_9__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
subgraph cluster_long_mult {
label="long_mult";
style="bold,filled";
colorscheme=pastel19;
fillcolor=3;
subgraph cluster_add_together {
label="add_together";
style="rounded,filled";
colorscheme=X11;
fillcolor=grey;
job_3__long_mult;
job_9__long_mult;
semaphore_1__long_mult;
semaphore_2__long_mult;
}
subgraph cluster_part_multiply {
label="part_multiply";
style="rounded,filled";
colorscheme=X11;
fillcolor=yellow;
job_10__long_mult;
job_11__long_mult;
job_12__long_mult;
job_4__long_mult;
job_5__long_mult;
job_6__long_mult;
job_7__long_mult;
job_8__long_mult;
}
subgraph cluster_take_b_apart {
label="take_b_apart";
style="rounded,filled";
colorscheme=X11;
fillcolor=DeepSkyBlue;
job_1__long_mult;
job_2__long_mult;
}
}
}
digraph test {
ratio="compress"; name = "JobDependencyGraph"; pad = "0"; ranksep = "1.4"; remincross = "true";
job_1__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>1</i></td></tr><tr><td>a_multiplier:</td><td> 9650156169</td></tr><tr><td>b_multiplier:</td><td> 327358788</td></tr></table>>, shape="box3d", style="filled"];
job_3__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>3</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr></table>>, shape="box3d", style="filled"];
job_4__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>4</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 2</td></tr></table>>, shape="box3d", style="filled"];
semaphore_1__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 4</i></b></font></td></tr><tr><td colspan="3">&nbsp;</td></tr><tr><td></td><td><b><u>partial_product</u></b></td><td></td></tr><tr><td port="semaphore_1__long_mult_partial_product_4">{2}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;19300312338&quot;</td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_5__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>5</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 3</td></tr></table>>, shape="box3d", style="filled"];
job_6__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>6</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
job_7__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>7</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 7</td></tr></table>>, shape="box3d", style="filled"];
job_8__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>8</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 8</td></tr></table>>, shape="box3d", style="filled"];
job_2__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>2</i></td></tr><tr><td>a_multiplier:</td><td> 327358788</td></tr><tr><td>b_multiplier:</td><td> 9650156169</td></tr></table>>, shape="box3d", style="filled"];
job_9__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>9</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr></table>>, shape="box3d", style="filled"];
job_10__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>10</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
semaphore_2__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 1</i></b></font></td></tr><tr><td colspan="3">&nbsp;</td></tr><tr><td></td><td><b><u>partial_product</u></b></td><td></td></tr><tr><td port="semaphore_2__long_mult_partial_product_10">{5}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;1636793940&quot;</td></tr><tr><td port="semaphore_2__long_mult_partial_product_11">{6}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;1964152728&quot;</td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_11__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>11</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 6</td></tr></table>>, shape="box3d", style="filled"];
job_12__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>12</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 9</td></tr></table>>, shape="box3d", style="filled"];
job_10__long_mult -> semaphore_2__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_11__long_mult -> semaphore_2__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_12__long_mult -> semaphore_2__long_mult [arrowhead="tee", color="red", style="dashed"];
job_1__long_mult -> job_3__long_mult [color="blue"];
job_1__long_mult -> job_4__long_mult [color="blue"];
job_1__long_mult -> job_5__long_mult [color="blue"];
job_1__long_mult -> job_6__long_mult [color="blue"];
job_1__long_mult -> job_7__long_mult [color="blue"];
job_1__long_mult -> job_8__long_mult [color="blue"];
job_2__long_mult -> job_10__long_mult [color="blue"];
job_2__long_mult -> job_11__long_mult [color="blue"];
job_2__long_mult -> job_12__long_mult [color="blue"];
job_2__long_mult -> job_9__long_mult [color="blue"];
job_4__long_mult -> semaphore_1__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_5__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_6__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_7__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_8__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
semaphore_1__long_mult -> job_3__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
semaphore_2__long_mult -> job_9__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
subgraph cluster_long_mult {
label="long_mult";
style="bold,filled";
colorscheme=pastel19;
fillcolor=3;
subgraph cluster_add_together {
label="add_together";
style="rounded,filled";
colorscheme=X11;
fillcolor=grey;
job_3__long_mult;
job_9__long_mult;
semaphore_1__long_mult;
semaphore_2__long_mult;
}
subgraph cluster_part_multiply {
label="part_multiply";
style="rounded,filled";
colorscheme=X11;
fillcolor=yellow;
job_10__long_mult;
job_11__long_mult;
job_12__long_mult;
job_4__long_mult;
job_5__long_mult;
job_6__long_mult;
job_7__long_mult;
job_8__long_mult;
}
subgraph cluster_take_b_apart {
label="take_b_apart";
style="rounded,filled";
colorscheme=X11;
fillcolor=DeepSkyBlue;
job_1__long_mult;
job_2__long_mult;
}
}
}
digraph test {
ratio="compress"; name = "JobDependencyGraph"; pad = "0"; ranksep = "1.4"; remincross = "true";
job_1__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>1</i></td></tr><tr><td>a_multiplier:</td><td> 9650156169</td></tr><tr><td>b_multiplier:</td><td> 327358788</td></tr></table>>, shape="box3d", style="filled"];
job_3__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>3</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr></table>>, shape="box3d", style="filled"];
job_4__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>4</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 2</td></tr></table>>, shape="box3d", style="filled"];
semaphore_1__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 2</i></b></font></td></tr><tr><td colspan="3">&nbsp;</td></tr><tr><td></td><td><b><u>partial_product</u></b></td><td></td></tr><tr><td port="semaphore_1__long_mult_partial_product_4">{2}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;19300312338&quot;</td></tr><tr><td port="semaphore_1__long_mult_partial_product_5">{3}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;28950468507&quot;</td></tr><tr><td port="semaphore_1__long_mult_partial_product_6">{5}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;48250780845&quot;</td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_5__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>5</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 3</td></tr></table>>, shape="box3d", style="filled"];
job_6__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>6</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
job_7__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>7</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 7</td></tr></table>>, shape="box3d", style="filled"];
job_8__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>8</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>1</i></td></tr><tr><td>digit:</td><td> 8</td></tr></table>>, shape="box3d", style="filled"];
job_2__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>2</i></td></tr><tr><td>a_multiplier:</td><td> 327358788</td></tr><tr><td>b_multiplier:</td><td> 9650156169</td></tr></table>>, shape="box3d", style="filled"];
job_9__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>9</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr></table>>, shape="box3d", style="filled"];
job_10__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>10</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 5</td></tr></table>>, shape="box3d", style="filled"];
semaphore_2__long_mult [fillcolor="grey", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td colspan="3"><font color="brown"><b><i>local: 1</i></b></font></td></tr><tr><td colspan="3">&nbsp;</td></tr><tr><td></td><td><b><u>partial_product</u></b></td><td></td></tr><tr><td port="semaphore_2__long_mult_partial_product_10">{5}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;1636793940&quot;</td></tr><tr><td port="semaphore_2__long_mult_partial_product_11">{6}</td><td>&nbsp;<b>--&gt;</b>&nbsp;</td><td>&quot;1964152728&quot;</td></tr></table>>, margin="0,0", shape="house", style="filled"];
job_11__long_mult [fillcolor="DeepSkyBlue", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>11</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 6</td></tr></table>>, shape="box3d", style="filled"];
job_12__long_mult [fillcolor="green", label=<<table border="0" cellborder="0" cellspacing="0" cellpadding="1"><tr><td><u><i>job_id:</i></u></td><td><i>12</i></td></tr><tr><td><u><i>params from:</i></u></td><td><i>2</i></td></tr><tr><td>digit:</td><td> 9</td></tr></table>>, shape="box3d", style="filled"];
job_10__long_mult -> semaphore_2__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_11__long_mult -> semaphore_2__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_12__long_mult -> semaphore_2__long_mult [arrowhead="tee", color="red", style="dashed"];
job_1__long_mult -> job_3__long_mult [color="blue"];
job_1__long_mult -> job_4__long_mult [color="blue"];
job_1__long_mult -> job_5__long_mult [color="blue"];
job_1__long_mult -> job_6__long_mult [color="blue"];
job_1__long_mult -> job_7__long_mult [color="blue"];
job_1__long_mult -> job_8__long_mult [color="blue"];
job_2__long_mult -> job_10__long_mult [color="blue"];
job_2__long_mult -> job_11__long_mult [color="blue"];
job_2__long_mult -> job_12__long_mult [color="blue"];
job_2__long_mult -> job_9__long_mult [color="blue"];
job_4__long_mult -> semaphore_1__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_5__long_mult -> semaphore_1__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_6__long_mult -> semaphore_1__long_mult [arrowhead="none", color="darkgreen", style="dashed"];
job_7__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
job_8__long_mult -> semaphore_1__long_mult [arrowhead="tee", color="red", style="dashed"];
semaphore_1__long_mult -> job_3__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
semaphore_2__long_mult -> job_9__long_mult [arrowhead="tee", color="red", headport="n", style="dashed", tailport="s"];
subgraph cluster_long_mult {
label="long_mult";
style="bold,filled";
colorscheme=pastel19;
fillcolor=3;
subgraph cluster_add_together {
label="add_together";
style="rounded,filled";
colorscheme=X11;
fillcolor=grey;
job_3__long_mult;
job_9__long_mult;
semaphore_1__long_mult;
semaphore_2__long_mult;
}
subgraph cluster_part_multiply {
label="part_multiply";
style="rounded,filled";
colorscheme=X11;
fillcolor=yellow;
job_10__long_mult;
job_11__long_mult;
job_12__long_mult;
job_4__long_mult;
job_5__long_mult;
job_6__long_mult;
job_7__long_mult;
job_8__long_mult;
}
subgraph cluster_take_b_apart {
label="take_b_apart";
style="rounded,filled";
colorscheme=X11;
fillcolor=DeepSkyBlue;
job_1__long_mult;