diff options
author | Tibor Frank <tifrank@cisco.com> | 2018-04-23 08:17:35 +0200 |
---|---|---|
committer | Tibor Frank <tifrank@cisco.com> | 2018-04-23 08:17:35 +0200 |
commit | 7cfdac0cf07e3a7d9a8b53b7621f8b7500fd1515 (patch) | |
tree | 3b799c9b3bdba5435509465dc8c1e5a0f9b8d407 | |
parent | 4f5872c1bb23873b3a93cb471aae8700d5ca029d (diff) |
PAL Trending: fix in remove_outliers
Change-Id: Iec4d1683b8bb97224971d803821aced3c37144bd
Signed-off-by: Tibor Frank <tifrank@cisco.com>
-rw-r--r-- | resources/tools/presentation/generator_tables.py | 4 | ||||
-rw-r--r-- | resources/tools/presentation/utils.py | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/resources/tools/presentation/generator_tables.py b/resources/tools/presentation/generator_tables.py index 9b9f09f4be..50a6623356 100644 --- a/resources/tools/presentation/generator_tables.py +++ b/resources/tools/presentation/generator_tables.py @@ -405,7 +405,7 @@ def table_performance_comparison(table, input_data): item = [tbl_dict[tst_name]["name"], ] if tbl_dict[tst_name]["ref-data"]: data_t = remove_outliers(tbl_dict[tst_name]["ref-data"], - outlier_constant=table["outlier-const"]) + outlier_const=table["outlier-const"]) # TODO: Specify window size. item.append(round(mean(data_t) / 1000000, 2)) item.append(round(stdev(data_t) / 1000000, 2)) @@ -413,7 +413,7 @@ def table_performance_comparison(table, input_data): item.extend([None, None]) if tbl_dict[tst_name]["cmp-data"]: data_t = remove_outliers(tbl_dict[tst_name]["cmp-data"], - outlier_constant=table["outlier-const"]) + outlier_const=table["outlier-const"]) # TODO: Specify window size. item.append(round(mean(data_t) / 1000000, 2)) item.append(round(stdev(data_t) / 1000000, 2)) diff --git a/resources/tools/presentation/utils.py b/resources/tools/presentation/utils.py index bc62268937..2fbf70cadc 100644 --- a/resources/tools/presentation/utils.py +++ b/resources/tools/presentation/utils.py @@ -67,6 +67,7 @@ def relative_change(nr1, nr2): return float(((nr2 - nr1) / nr1) * 100) + def remove_outliers(input_list, outlier_const=1.5, window=14): """Return list with outliers removed, using split_outliers. |