Commit 814fa34e authored by Georgios Dagkakis's avatar Georgios Dagkakis

correction in plugin, if there is no unitsThroughPut by the exit then get batchThroughput

parent d7daa461
...@@ -29,7 +29,11 @@ class BatchesTabularExit(plugin.OutputPreparationPlugin): ...@@ -29,7 +29,11 @@ class BatchesTabularExit(plugin.OutputPreparationPlugin):
batchesThroughput=record['results']['throughput'][0] batchesThroughput=record['results']['throughput'][0]
data['result']['result_list'][0]['exit_output'].append(['Number of batches produced','Batches', data['result']['result_list'][0]['exit_output'].append(['Number of batches produced','Batches',
batchesThroughput]) batchesThroughput])
unitsThroughput=record['results']['unitsThroughput'][0] unitsThroughput=record['results'].get('unitsThroughput',None)
if unitsThroughput:
unitsThroughput=unitsThroughput[0]
if not unitsThroughput:
unitsThroughput=batchesThroughput
data['result']['result_list'][0]['exit_output'].append(['Number of units produced','Units', data['result']['result_list'][0]['exit_output'].append(['Number of units produced','Units',
unitsThroughput]) unitsThroughput])
lineThroughput=batchesThroughput/float(maxSimTime) lineThroughput=batchesThroughput/float(maxSimTime)
...@@ -62,6 +66,9 @@ class BatchesTabularExit(plugin.OutputPreparationPlugin): ...@@ -62,6 +66,9 @@ class BatchesTabularExit(plugin.OutputPreparationPlugin):
"%.2f" % batchesThroughputCI['lb'], "%.2f" % batchesThroughputCI['lb'],
"%.2f" % batchesThroughputCI['ub']] "%.2f" % batchesThroughputCI['ub']]
) )
unitsThroughputList=record['results'].get('unitsThroughput',None)
if not unitsThroughputList:
unitsThroughputList=batchesThroughputList
unitsThroughputList=record['results']['unitsThroughput'] unitsThroughputList=record['results']['unitsThroughput']
unitsThroughputCI=self.getConfidenceInterval(unitsThroughputList,confidenceLevel) unitsThroughputCI=self.getConfidenceInterval(unitsThroughputList,confidenceLevel)
data['result']['result_list'][0]['exit_output'].append(['Number of units produced','Units', data['result']['result_list'][0]['exit_output'].append(['Number of units produced','Units',
......
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