diff --git a/TerroristNetworkModel.yml b/TerroristNetworkModel.yml index 5b4affb..4874b62 100644 --- a/TerroristNetworkModel.yml +++ b/TerroristNetworkModel.yml @@ -1,13 +1,13 @@ name: TerroristNetworkModel_sim load_module: TerroristNetworkModel -max_time: 150 +max_time: 500 num_trials: 1 network_params: generator: random_geometric_graph radius: 0.2 # generator: geographical_threshold_graph # theta: 20 - n: 50 + n: 150 network_agents: - agent_type: TerroristNetworkModel weight: 0.8 @@ -57,4 +57,4 @@ visualization_params: color: red - attr_id: 2 color: '#c16a6a' - background_image: 'map.png' + background_image: 'map_4800x2860.jpg' diff --git a/templates/img/background/map_4800x2860.jpg b/templates/img/background/map_4800x2860.jpg new file mode 100644 index 0000000..b41a0ee Binary files /dev/null and b/templates/img/background/map_4800x2860.jpg differ diff --git a/templates/js/socket.js b/templates/js/socket.js index 2a92013..0661598 100755 --- a/templates/js/socket.js +++ b/templates/js/socket.js @@ -235,16 +235,15 @@ var set_timeline = function(graph) { // Draw graph for the first time self.GraphVisualization.update_graph($('.config-item #properties').val(), maxUnix, function() { update_statistics_table(); - $('svg #root > image').attr('height', d3.select('#root').node().getBBox().height) setTimeout(function() { + self.GraphVisualization.fit(); if ( $('svg #root > image').length !== 0 ) { $('svg #root > image').attr('height', d3.select('#root').node().getBBox().height * 1.2); var dx = d3.select('#graph-wrapper').node().getBBox().width - d3.select('svg #root > image').node().getBBox().width; var dy = d3.select('#graph-wrapper').node().getBBox().height - d3.select('svg #root > image').node().getBBox().height; $('svg #root > image').attr('transform', 'translate(' + (dx / 2) + ',' + (dy / 2) + ')'); } - self.GraphVisualization.fit(); - }, 100); + }, 500); }); // 'Speed' slider