Quality at the Tail of Machine Learning Inference
Zhengxin Yang, Wanling Gao, Chunjie Luo, Lei Wang, Fei Tang, Xu Wen, Jianfeng Zhan
TL;DR
The paper identifies a counterintuitive phenomenon: deep learning inference quality can fluctuate with inference time, especially under tight tail-latency constraints, leading to potentially catastrophic outcomes in safety-critical tasks. It formalizes tail quality as the inference quality under a tail-time threshold and proposes a two-part evaluation framework that jointly models inference-time distributions and the resulting tail-quality metric. The framework estimates per-instance time distributions via a KDE-based Monte Carlo approach and uses a convergence measure based on Jensen-Shannon divergence to predict tail-quality statistics, achieving rJSD values below 0.05 and substantial reductions in required inferences compared to MLPerf. Experimental instantiations across four systems, two frameworks, three models, and three datasets demonstrate accurate time-to-quality mappings and the ability to predict worst-case tail quality with lower computational effort, enabling proactive, risk-aware benchmarking for real-time AI deployments.
Abstract
Machine learning inference should be subject to stringent inference time constraints while ensuring high inference quality, especially in safety-critical (e.g., autonomous driving) and mission-critical (e.g., emotion recognition) contexts. Neglecting either aspect can lead to severe consequences, such as loss of life and property damage. Many studies lack a comprehensive consideration of these metrics, leading to incomplete or misleading evaluations. The study unveils a counterintuitive revelation: deep learning inference quality exhibits fluctuations due to inference time. To depict this phenomenon, the authors coin a new term, "tail quality," providing a more comprehensive evaluation, and overcoming conventional metric limitations. Moreover, the research proposes an initial evaluation framework to analyze factors affecting quality fluctuations, facilitating the prediction of the potential distribution of inference quality. The effectiveness of the evaluation framework is validated through experiments conducted on deep learning models for three different tasks across four systems.
