TL;DR
This paper tackles the challenge of imbalanced data in big data machine learning by adapting and evaluating 14 oversampling algorithms on Apache Spark. They introduce a comprehensive taxonomy, a new Spark library, and provide crucial guidelines for designing future scalable oversampling methods, highlighting the importance of local instance-level information.
What Problem Does This Paper Address?
Machine learning models often struggle with imbalanced datasets, where one class significantly outnumbers others. This bias is exacerbated in the "big data" era, where massive datasets require distributed computing frameworks like Apache Spark. Existing oversampling techniques, designed for smaller datasets, don't readily translate to Spark's distributed architecture, leading to performance issues and scalability challenges. The authors aim to bridge this gap by providing a holistic approach to oversampling for imbalanced big data, including a taxonomy, practical implementations, and empirical analysis.
Methods
The core contribution is the adaptation and evaluation of 14 state-of-the-art oversampling algorithms for Apache Spark. This involved:
- Taxonomy: Developing a structured classification of oversampling algorithms based on their instance generation mechanisms and how they utilize class information.
- Spark Implementation: Creating a Scala library (
spark-class-balancing) that implements these algorithms within the Spark framework, using afit/transformpattern similar to Spark MLlib. Multi-class support was added using a one-vs-all approach. - Experimental Study: Conducting extensive experiments on 26 diverse binary and multi-class datasets to evaluate the performance, accuracy-time trade-offs, and scalability of the implemented algorithms across different classifiers (Random Forest, SVM, Naive Bayes).
- Guidelines: Deriving design principles for future oversampling algorithms in big data contexts, based on the insights gained from component analysis and experimental results.
Datasets
The authors used 26 datasets for their experiments, categorized as:
- Two-class datasets with binary features.
- Two-class datasets with continuous features.
- Multi-class datasets with continuous features.
These datasets were selected to provide a wide range of feature counts and class imbalance ratios. For computational feasibility, a sub-section of 100,000 examples was used from each dataset.
Key Insights and Ideas
- Local Information is King: For big data oversampling on Spark, local instance-level information (e.g., neighborhood characteristics) is significantly more useful than global or modality-based information. This is attributed to Spark's data partitioning, which can disrupt global spatial relationships.
- Not All Information is Equal: While informed oversampling is generally expected to outperform standard methods, the results show that not all information about instances is equally important. Some complex, globally-aware methods performed poorly.
- Hybrid Approaches Show Promise: While undersampling alone might be insufficient, combining it with oversampling (e.g., data cleaning by translating majority observations, as in CCR) can enhance performance.
- Simplicity Can Be Scalable: Algorithms with fewer parameters or those that can adapt automatically (self-tuning) are more feasible for hyperparameter tuning in big data scenarios, reducing computational burden.
- Random Oversampling's Resilience: Surprisingly, Random Oversampling, despite using no instance-level information, often performed competitively, especially with Random Forest, highlighting its scalability and robustness in certain contexts.
Key Results
- Performance: Guided oversampling methods like Borderline SMOTE, Safe-level SMOTE, ADASYN, and CCR consistently performed well, especially on binary datasets. For multi-class problems, Cluster SMOTE showed improvement, but local methods still led.
- Scalability: Algorithms with complex components like k-NN searches (especially those needing radius-based searches), dependent loops, and probabilistic sampling struggled with scalability on Spark. ANS, MWMOTE, and RBO were found to be significantly slower than SMOTE.
- Trade-offs: No single algorithm was universally the best. Random Oversampling offered good accuracy-time trade-offs for certain datasets and classifiers, but not others. Borderline SMOTE, Cluster SMOTE, Gaussian SMOTE, and NRAS showed good trade-offs in specific scenarios.
- Classifier Impact: Random Forest could utilize Random Oversampling more efficiently due to its ensemble nature. SVM and Naive Bayes benefited more significantly from guided oversampling.
Limitations and Future Work
- Efficiency Limitations: Some implementations, while faithful to original designs, have efficiency limitations in Spark.
- Scalability Issues: ANS, MWMOTE, and RBO were too slow for full experimental inclusion, indicating scalability challenges.
- Future Work:
- Updating the library to newer Spark versions and integrating with a custom
spark-knnfork.
- Updating the library to newer Spark versions and integrating with a custom
- Extending the library to include undersampling, hybrid methods, and ensemble techniques.
- Developing self-tuning oversampling algorithms to reduce hyperparameter tuning complexity.
- Further exploring hybrid oversampling strategies that leverage undersampling/data cleaning.
- Focusing on low-complexity local data analysis for scalable oversampling.
Summary updated