Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(262)

Unified Diff: tools/perf/benchmarks/peacekeeper.py

Issue 27486002: Cleanup of page_measurement_results object (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: keep on trying Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/perf/benchmarks/dom_perf.py ('k') | tools/perf/measurements/page_cycler_unittest.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/perf/benchmarks/peacekeeper.py
diff --git a/tools/perf/benchmarks/peacekeeper.py b/tools/perf/benchmarks/peacekeeper.py
index 88a3338c96ecfd4ce807344461452a918fa616b5..2e71e567b6a0ceeebe5cf76dd7f25851f7ac8f2e 100644
--- a/tools/perf/benchmarks/peacekeeper.py
+++ b/tools/perf/benchmarks/peacekeeper.py
@@ -20,7 +20,7 @@ from metrics import statistics
from telemetry import test
from telemetry.page import page_measurement
from telemetry.page import page_set
-
+from telemetry.value import merge_values
class PeaceKeeperMeasurement(page_measurement.PageMeasurement):
@@ -60,10 +60,11 @@ class PeaceKeeperMeasurement(page_measurement.PageMeasurement):
def DidRunTest(self, browser, results):
# Calculate geometric mean as the total for the combined tests.
- scores = []
- for result in results.page_results:
- scores.append(result['Score'].output_value)
- total = statistics.GeometricMean(scores)
+ combined = merge_values.MergeLikeValuesFromDifferentPages(
+ results.all_page_specific_values,
+ group_by_name_suffix=True)
+ combined_score = [x for x in combined if x.name == 'Score'][0]
+ total = statistics.GeometricMean(combined_score.values)
results.AddSummary('Score', 'score', total, 'Total')
@@ -254,4 +255,3 @@ class PeaceKeeperHTML5Capabilities(PeaceKeeperBenchmark):
'workerContrast01',
'workerContrast02'
]
-
« no previous file with comments | « tools/perf/benchmarks/dom_perf.py ('k') | tools/perf/measurements/page_cycler_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698