Skip to main content
QUICK REVIEW

[Paper Review] Why is Differential Evolution Better than Grid Search for Tuning Defect Predictors?

Wei Fu, Vivek Nair|arXiv (Cornell University)|Sep 8, 2016
Software Engineering ResearchComputer Science36 references33 citations
TL;DR

This paper compares differential evolution (DE) and grid search for tuning defect predictors in software engineering, finding that DE achieves comparable or better performance scores while being over 210 times faster than grid search across 17 datasets. The authors attribute this to the low intrinsic dimensionality of defect prediction data, which makes stochastic search methods like DE more effective than exhaustive grid search.

ABSTRACT

Context: One of the black arts of data mining is learning the magic parameters which control the learners. In software analytics, at least for defect prediction, several methods, like grid search and differential evolution (DE), have been proposed to learn these parameters, which has been proved to be able to improve the performance scores of learners. Objective: We want to evaluate which method can find better parameters in terms of performance score and runtime cost. Methods: This paper compares grid search to differential evolution, which is an evolutionary algorithm that makes extensive use of stochastic jumps around the search space. Results: We find that the seemingly complete approach of grid search does no better, and sometimes worse, than the stochastic search. When repeated 20 times to check for conclusion validity, DE was over 210 times faster than grid search to tune Random Forests on 17 testing data sets with F-Measure Conclusions: These results are puzzling: why does a quick partial search be just as effective as a much slower, and much more, extensive search? To answer that question, we turned to the theoretical optimization literature. Bergstra and Bengio conjecture that grid search is not more effective than more randomized searchers if the underlying search space is inherently low dimensional. This is significant since recent results show that defect prediction exhibits very low intrinsic dimensionality-- an observation that explains why a fast method like DE may work as well as a seemingly more thorough grid search. This suggests, as a future research direction, that it might be possible to peek at data sets before doing any optimization in order to match the optimization algorithm to the problem at hand.

Motivation & Objective

  • To evaluate whether differential evolution (DE) or grid search yields better hyperparameter tuning for defect predictors in terms of performance and runtime.
  • To investigate why DE, a stochastic method, often outperforms the exhaustive but slow grid search in tuning machine learning models for defect prediction.
  • To explore the role of intrinsic dimensionality in explaining the superior efficiency of DE over grid search in this context.
  • To provide empirical evidence for selecting optimization algorithms based on data-specific characteristics like dimensionality.

Proposed method

  • The study uses 17 publicly available defect prediction datasets from the SEACRAFT repository, each with 14 static code metrics as features.
  • It applies three tuning methods—differential evolution (DE), grid search, and random search—on two learners: CART and Random Forests.
  • Performance is evaluated using AUC, AUC_{20}, precision, and F-Measure, with 20 independent runs to ensure stability.
  • Runtime costs are measured by recording start and end times for each tuning process across all datasets.
  • Statistical significance is assessed using the Scott-Knott non-parametric test to compare DE and grid search results across repeated trials.
  • Theoretical explanations are grounded in Bergstra and Bengio’s argument that random and stochastic search outperform grid search in low-dimensional spaces, supported by Papakroni and Provence’s empirical findings on low intrinsic dimensionality in defect prediction data.

Experimental results

Research questions

  • RQ1RQ1: Does hyperparameter tuning improve the performance of defect predictors?
  • RQ2RQ2: Is grid search statistically better than differential evolution (DE) in terms of performance scores (AUC, AUC_{20}, precision, F-Measure)?
  • RQ3RQ3: Is DE more efficient than grid search in terms of runtime cost?
  • RQ4RQ4: Why does DE perform as well or better than grid search despite being less exhaustive?
  • RQ5RQ5: Can intrinsic dimensionality explain the observed performance differences between tuning methods?

Key findings

  • Differential evolution (DE) achieved better or equal performance scores compared to grid search on 17 defect prediction datasets, with no significant degradation in AUC, AUC_{20}, precision, or F-Measure.
  • Grid search was statistically better than DE in only 6 out of 17 datasets when using CART with precision as the metric, indicating no consistent advantage.
  • DE was over 210 times faster than grid search on average when tuning Random Forests across the 17 datasets, significantly reducing runtime cost.
  • The results suggest that the low intrinsic dimensionality of defect prediction data—confirmed by prior work—explains why stochastic methods like DE outperform exhaustive grid search.
  • Repeated runs (20 times) showed consistent results, supporting the validity of DE’s performance and efficiency across multiple trials.
  • The study concludes that tuning is essential for high-performing defect predictors and that DE is a superior choice due to its speed and effectiveness, especially in low-dimensional data spaces.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.