[Paper Review] Overly Optimistic Prediction Results on Imbalanced Data: Flaws and Benefits of Applying Over-sampling.
This paper identifies a critical methodological flaw in machine learning studies using imbalanced electrohysterography data: applying over-sampling before splitting data into training and testing sets leads to overly optimistic performance estimates. By demonstrating data leakage via artificial datasets and real-world replication, the authors show that over-sampling prior to partitioning inflates model performance, undermining generalization, and advocate for proper data splitting order to ensure valid evaluation.
Information extracted from electrohysterography recordings could potentially prove to be an interesting additional source of information to estimate the risk on preterm birth. Recently, a large number of studies have reported near-perfect results to distinguish between recordings of patients that will deliver term or preterm using a public resource, called the Term/Preterm Electrohysterogram database. However, we argue that these results are overly optimistic due to a methodological flaw being made. In this work, we focus on one specific type of methodological flaw: applying over-sampling before partitioning the data into mutually exclusive training and testing sets. We show how this causes the results to be biased using two artificial datasets and reproduce results of studies in which this flaw was identified. Moreover, we evaluate the actual impact of over-sampling on predictive performance, when applied prior to data partitioning, using the same methodologies of related studies, to provide a realistic view of these methodologies' generalization capabilities. We make our research reproducible by providing all the code under an open license.
Motivation & Objective
- To investigate the impact of applying over-sampling before data partitioning on model performance evaluation in imbalanced datasets.
- To demonstrate that this practice leads to overly optimistic and biased prediction results in studies using the Term/Preterm Electrohysterogram database.
- To provide a realistic assessment of over-sampling's actual benefit on predictive performance when applied correctly.
- To promote methodological rigor by advocating for proper data splitting order before applying over-sampling.
- To ensure reproducibility by releasing all code under an open license.
Proposed method
- The authors construct two artificial datasets with controlled class imbalance to simulate real-world data distribution issues.
- They apply over-sampling techniques (e.g., SMOTE or random oversampling) before splitting data into training and testing sets to induce data leakage.
- They reproduce results from published studies that used this flawed approach to validate the bias in performance metrics.
- They re-evaluate the same methodologies with correct data splitting order—partitioning first, then applying over-sampling only to the training set.
- They use standard evaluation metrics (e.g., AUC, accuracy) to compare performance across flawed and correct workflows.
- All experiments are implemented with open-source code to ensure reproducibility and transparency.
Experimental results
Research questions
- RQ1Does applying over-sampling before data partitioning lead to biased and overly optimistic performance estimates in imbalanced datasets?
- RQ2To what extent does this flawed methodology inflate reported predictive performance in studies using the Term/Preterm Electrohysterogram database?
- RQ3How does the actual performance of over-sampling compare when applied after proper data splitting, versus before?
- RQ4Can the same methodologies used in prior studies be reproduced with corrected data handling to reveal more realistic generalization capabilities?
- RQ5What is the impact of data leakage on model evaluation when over-sampling is applied prematurely?
Key findings
- Applying over-sampling before splitting data into training and testing sets causes data leakage, resulting in overly optimistic performance estimates.
- The flawed methodology leads to inflated AUC and accuracy values that do not reflect true model generalization on unseen data.
- When over-sampling is applied only to the training set after proper partitioning, performance metrics drop significantly, indicating the prior results were misleading.
- The study successfully reproduces previously reported near-perfect results by replicating the flawed methodology, confirming the source of over-optimism.
- Correctly applied over-sampling improves model robustness but does not yield near-perfect performance, revealing the true generalization capability of the models.
- The authors demonstrate that the observed high performance in prior studies is largely an artifact of improper data handling rather than model superiority.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.