skpbench: fix parser script for bots
- emits the timings as numbers instead of strings. - moves 'bench_type' and 'source_type' into the key. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4823 Change-Id: Ibf98891e21c5d4c8a794c207e60d0df78d8a063c Reviewed-on: https://skia-review.googlesource.com/4823 Reviewed-by: Kevin Lubick <kjlubick@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
This commit is contained in:
parent
57ae6cfe01
commit
27f05a2172
@ -65,9 +65,9 @@ class JSONDict(dict):
|
|||||||
def main():
|
def main():
|
||||||
data = JSONDict(
|
data = JSONDict(
|
||||||
FLAGS.properties + \
|
FLAGS.properties + \
|
||||||
['key', JSONDict(FLAGS.key),
|
['key', JSONDict(FLAGS.key + \
|
||||||
'bench_type', 'playback',
|
['bench_type', 'playback', \
|
||||||
'source_type', 'skp'])
|
'source_type', 'skp'])])
|
||||||
|
|
||||||
for src in FLAGS.sources:
|
for src in FLAGS.sources:
|
||||||
with open(src, mode='r') as infile:
|
with open(src, mode='r') as infile:
|
||||||
@ -80,7 +80,7 @@ def main():
|
|||||||
for result in ('accum', 'median'):
|
for result in ('accum', 'median'):
|
||||||
data['results'][match.bench][match.config] \
|
data['results'][match.bench][match.config] \
|
||||||
['%s_%s_%s' % (result, match.clock, match.metric)] = \
|
['%s_%s_%s' % (result, match.clock, match.metric)] = \
|
||||||
match.get_string(result)
|
getattr(match, result)
|
||||||
|
|
||||||
if FLAGS.outfile != '-':
|
if FLAGS.outfile != '-':
|
||||||
with open(FLAGS.outfile, 'w+') as outfile:
|
with open(FLAGS.outfile, 'w+') as outfile:
|
||||||
|
Loading…
Reference in New Issue
Block a user