Commit e28b9366 authored by Georgios Dagkakis's avatar Georgios Dagkakis

names to be shown in the batches utilization chart

parent 54cbaf34
......@@ -86,7 +86,7 @@ class BatchesStationUtilization(plugin.OutputPreparationPlugin):
if objResults['off_shift_ratio']:
off_shift_data.append((i, objResults['off_shift_ratio'][0]))
ticks.append((i, obj.get('name', obj['id'])))
ticks.append((i, obj.get('name', self.getNameFromId(data, obj['id']))))
i += 1
return data
......@@ -32,6 +32,10 @@ class Plugin(object):
successors.append(edge['destination'])
return successors
# returns name of a node given its id
def getNameFromId(self, data, node_id):
return data['graph']['node'][node_id]['name']
class ExecutionPlugin(Plugin):
"""Plugin to handle the execution of multiple simulation runs.
"""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment