Store video_quality_loopback_test perf results in Chart JSON format.
Adds a flag to store the perf results in a JSON file using the Chart
JSON format [1].
[1] https://github.com/catapult-project/catapult/blob/master/dashboard/docs/data-format.md
TBR=phoglund@webrtc.org
Bug: chromium:755660
Change-Id: I6a896654a4a558df217ddefa4e8a52a487cdbebd
Reviewed-on: https://webrtc-review.googlesource.com/43180
Commit-Queue: Edward Lemur <ehmaldonado@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21809}
diff --git a/rtc_tools/compare_videos.py b/rtc_tools/compare_videos.py
index ce5bff3..40a2aab 100755
--- a/rtc_tools/compare_videos.py
+++ b/rtc_tools/compare_videos.py
@@ -62,6 +62,8 @@
help='Width of the YUV file\'s frames. Default: %default')
parser.add_option('--yuv_frame_height', type='int', default=480,
help='Height of the YUV file\'s frames. Default: %default')
+ parser.add_option('--chartjson_result_file', type='str', default=None,
+ help='Where to store perf results in chartjson format.')
options, _ = parser.parse_args()
if options.stats_file:
@@ -161,6 +163,8 @@
'--width=%d' % options.yuv_frame_width,
'--height=%d' % options.yuv_frame_height,
]
+ if options.chartjson_result_file:
+ cmd.append('--chartjson_result_file=%s' % options.chartjson_result_file)
frame_analyzer = subprocess.Popen(cmd, stdin=_DevNull(),
stdout=sys.stdout, stderr=sys.stderr)
frame_analyzer.wait()