Adjust thresholds in perf test

This commit is contained in:
Alexey Milovidov 2020-05-11 00:31:01 +03:00
parent 6854d0f55c
commit 9654532940
3 changed files with 1 additions and 55 deletions

View File

@ -1,50 +0,0 @@
#!/usr/bin/env python
import sys
import json
def prepare_comparison(test_results):
queries = []
query_to_version_to_results = {}
version_to_time = {}
for test in test_results:
version = test['server_version']
version_to_time[version] = test['time']
for run in test['runs']:
query = run['query']
version_to_results = query_to_version_to_results.setdefault(query, {})
if len(version_to_results) == 0:
queries.append(query)
version_to_results.setdefault(version, []).append(run['min_time'])
results = []
for version in sorted(list(version_to_time.keys())):
result = [query_to_version_to_results[q].get(version, []) for q in queries]
results.append({
'system': 'ClickHouse',
'version': version,
'data_size': 100000000,
'time': version_to_time[version],
'comments': '',
'result': result,
})
queries = [{'query': q, 'comment': ''} for q in queries]
return queries, results
if __name__ == '__main__':
json_files = sys.argv[1:]
queries, results = prepare_comparison(sum([json.load(open(f)) for f in json_files], []))
print 'var queries ='
print json.dumps(queries, indent=4, separators=(',', ': ')), ';'
print 'var results ='
print json.dumps(results, indent=4, separators=(',', ': ')), ';'

View File

@ -1,6 +1,4 @@
<test>
<query>SELECT sum(NOT ignore(*)) FROM (SELECT * FROM generateRandom('ui64 UInt64, i64 Int64, ui32 UInt32, i32 Int32, ui16 UInt16, i16 Int16, ui8 UInt8, i8 Int8') LIMIT 10000000);</query>
<query>SELECT sum(NOT ignore(*)) FROM (SELECT * FROM generateRandom('ui64 UInt64, i64 Int64, ui32 UInt32, i32 Int32, ui16 UInt16, i16 Int16, ui8 UInt8, i8 Int8', 0, 10, 10) LIMIT 10000000);</query>
<query>SELECT sum(NOT ignore(*)) FROM (SELECT * FROM generateRandom('i Enum8(\'hello\' = 1, \'world\' = 5)', 0, 10, 10) LIMIT 10000000);</query>

View File

@ -1,6 +1,4 @@
<test>
<test max_ignored_relative_change="0.2">
<!-- lon [-180; 180], lat [-90; 90] -->
<query>SELECT count() FROM numbers(1000000) WHERE NOT ignore(greatCircleDistance((rand(1) % 360) * 1. - 180, (number % 150) * 1.2 - 90, (number % 360) + toFloat64(rand(2)) / 4294967296 - 180, (rand(3) % 180) * 1. - 90))</query>
<!-- 55.755830, 37.617780 is center of Moscow -->