@@ -42,6 +42,7 @@ class PerformanceTestResult(object):
42
42
It supports log formats emitted by the test driver.
43
43
"""
44
44
45
+ # TODO: Delete after December 2023
45
46
@classmethod
46
47
def fromOldFormat (cls , header , line ):
47
48
"""Original format with statistics for normal distribution (MEAN, SD):
@@ -101,6 +102,7 @@ def fromOldFormat(cls, header, line):
101
102
102
103
return PerformanceTestResult (json_data )
103
104
105
+ # TODO: Delete after December 2023
104
106
@classmethod
105
107
def fromQuantileFormat (cls , header , line ):
106
108
"""Quantiles format with variable number of columns depending on the
@@ -229,9 +231,14 @@ def json(self):
229
231
# drop any lingering pre-computed statistics
230
232
# (It's better for downstream consumers to just
231
233
# compute whatever statistics they need from scratch.)
234
+
235
+ # After December 2023, uncomment the next line:
236
+ # assert len(self.samples) == self.num_samples
232
237
if len (self .samples ) == self .num_samples :
233
238
data ["samples" ] = self .samples
234
239
data .pop ("num_samples" , None )
240
+ # TODO: Delete min/max/mean/sd/q1/median/q3/quantiles
241
+ # after December 2023
235
242
data .pop ("min" , None )
236
243
data .pop ("max" , None )
237
244
data .pop ("mean" , None )
@@ -450,17 +457,21 @@ def __init__(self, old, new):
450
457
ratio = (new .min_value + 0.001 ) / (old .min_value + 0.001 )
451
458
self .delta = (ratio - 1 ) * 100
452
459
453
-
454
460
# If we have full samples for both old and new...
455
- if (len (old .samples ) == old .num_samples
456
- and len (new .samples ) == new .num_samples ):
461
+ if (
462
+ len (old .samples ) == old .num_samples
463
+ and len (new .samples ) == new .num_samples
464
+ ):
457
465
# TODO: Use a T-Test or U-Test to determine whether
458
466
# one set of samples should be considered reliably better than
459
467
# the other.
460
468
None
461
469
462
470
# If we do not have full samples, we'll use the
463
471
# legacy calculation for compatibility.
472
+ # TODO: After Dec 2023, we should always be using full samples
473
+ # everywhere and can delete the following entirely.
474
+ #
464
475
# Indication of dubious changes: when result's MIN falls inside the
465
476
# (MIN, MAX) interval of result they are being compared with.
466
477
self .is_dubious = (
0 commit comments