vix.ing · top · new · best · stats · spec

Data Leakage in Notebooks: Static Detection and Better Processes

2022/09/07 by Chenyang Yang, Rachel A Brower-Sinning, Yang, Chenyang +5 · 3 citations
Computer Science · #Adversarial Robustness in Machine Learning #FOS: Computer and information sciences #Machine Learning and Data Classification #Software Engineering (cs.SE) #Software Engineering Research

paper · pdf · doi:10.48550/arxiv.2209.03345

openalex publication_date 2022/09/07 · openalex created_date 2025/10/10 · openalex updated_date 2026/07/28

Abstract

Data science pipelines to train and evaluate models with machine learning may contain bugs just like any other code. Leakage between training and test data can lead to overestimating the model's accuracy during offline evaluations, possibly leading to deployment of low-quality models in production. Such leakage can happen easily by mistake or by following poor practices, but may be tedious and challenging to detect manually. We develop a static analysis approach to detect common forms of data leakage in data science code. Our evaluation shows that our analysis accurately detects data leakage and that such leakage is pervasive among over 100,000 analyzed public notebooks. We discuss how our static analysis approach can help both practitioners and educators, and how leakage prevention can be designed into the development process.

Cited by

Related