Sliding-window test counts overstate classification confidence
When 10,000 Windows Are Not 10,000 Tests: Auditing Statistical Confidence in Sliding-Window Time-Series Classification
Machine Learning
Summary
When evaluating how well a computer program recognizes patterns over time, people often test many overlapping pieces of the data. The authors show that counting each overlapping piece as a separate test exaggerates how confident we can be in the results. They introduce a careful way to check which parts of the tests really provide new information and how to better trust the performance claims. Their methods work even when test pieces overlap a lot or come from the same people or sessions.
What this means in practice
- •For machine learning engineers: Assess classifier performance on time-series data more accurately by accounting for dependence between overlapping test windows.
- •For mobile health app developers: Improve reliability claims of activity recognition models by auditing the effective amount of independent test evidence from wearable sensor data.
Authors
Xinze Shi, Litian Zhang, Binrui Shi
Abstract
Sliding-window classifiers are often evaluated on thousands of overlapping test windows, even though neighboring predictions share observations and remain nested within recordings and subjects. Subject-disjoint evaluation prevents one form of leakage but does not make those test windows independent. We present a practical audit that maps three claims - performance on observed recordings, future recordings from observed subjects, and unseen subjects - to explicit aggregation rules and established dependence-robust inference. At 75% overlap, controlled simulations give 16.9% Type-I error for IID observed-record inference and 7.2% for session-centered Bartlett-HAC: a substantial improvement with residual miscalibration. Audits of frozen WISDM and HARTH predictions show that nearly fourfold growth in test rows yields only 1.75-1.94-fold variance-equivalent information growth. At that overlap, fixed-record paired Accuracy-difference intervals are 1.22-1.66 times the IID widths; this inflation is not universal at zero overlap. On HARTH, paired Accuracy-difference intervals include zero across three overlap settings, whereas Macro-F1 favors MiniROCKET. Independent recomputation, common-session checks, class-level results, and separately seeded calibration make the audit's scope and limitations inspectable. The resulting workflow distinguishes additional predictions from additional independent evidence.