NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Neural Networks for Predicting Algorithm Runtime Distributions

Katharina Eggensperger, Marius Lindauer, Frank Hutter

Abstract

Many state-of-the-art algorithms for solving hard combinatorial problems in artificial intelligence (AI) include elements of stochasticity that lead to high variations in runtime, even for a fixed problem instance. Knowledge about the resulting runtime distributions (RTDs) of algorithms on given problem instances can be exploited in various meta-algorithmic procedures, such as algorithm selection, portfolios, and randomized restarts. Previous work has shown that machine learning can be used to individually predict mean, median and variance of RTDs. To establish a new state-of-the-art in predicting RTDs, we demonstrate that the parameters of an RTD should be learned jointly and that neural networks can do this well by directly optimizing the likelihood of an RTD given runtime observations. In an empirical study involving five algorithms for SAT solving and AI planning, we show that neural networks predict the true RTDs of unseen instances better than previous methods, and can even do so when only few runtime observations are available per training instance.

Introduction

State-of-the-art solvers for hard combinatorial problems, such as SAT solving or AI planning, often rely on stochastic components. This randomness causes the runtime on a single problem instance to vary significantly across different executions. Understanding this variation—captured by the Runtime Distribution (RTD)—is crucial for meta-algorithmic tasks like algorithm selection or determining optimal restart strategies.

However, obtaining the RTD for a new, unseen instance by running the algorithm multiple times is computationally prohibitive. This paper introduces DistNet, a neural network approach designed to predict the entire RTD of randomized algorithms based solely on instance features. By jointly learning all parameters of a distribution through direct likelihood optimization, DistNet significantly outperforms traditional methods that predict parameters independently.

Methodology: The DistNet Approach

DistNet is a fully-connected feedforward neural network architecture tailored for joint parameter prediction. The core innovation lies in how the network is trained and what it outputs.

Overview of the DistNet training and prediction pipeline.

The pipeline consists of two main phases:

  1. Training: The model takes training instances and their corresponding runtime observations. It computes instance features f(π) and uses them to fit a model m̂ that maps features to distribution parameters θ.
  2. Prediction: For a new instance π_{n+1}, the model computes its features and uses the learned model m̂ to predict the parameters θ of the RTD.

Unlike previous approaches that might use separate models for different statistics (e.g., one for mean, one for variance), DistNet features one output neuron for each parameter of the chosen distribution family. It is trained to minimize the Negative Log-Likelihood (NLLH), directly maximizing the probability that the observed runtimes were generated by the predicted distribution.

Modeling Runtime Distributions

A critical step in the methodology is selecting the appropriate parametric family D to model runtimes. The authors evaluated several candidates: Normal (N), Lognormal (LOG), Exponential (EXP), and Inverse Normal (INV).

Comparison of different probability density functions for runtime distributions.

For hard combinatorial problems, runtimes rarely follow a Normal distribution. The study found that Lognormal and Inverse Normal distributions provided the best fit for nearly all tested algorithms. These families are particularly effective at capturing "heavy tails"—the occasional, extremely long runs that are characteristic of stochastic solvers.

Experimental Evaluation

The researchers evaluated DistNet across seven datasets involving five prominent algorithms:

  • SAT Solving: Clasp, Saps, Spear, and YalSAT on various problem domains (factorization, graph coloring, etc.).
  • AI Planning: The LPG solver on the "zenotravel" domain.

Key Results

  • Superior Accuracy: DistNet consistently achieved lower NLLH than Random Forest baselines, indicating a better fit to the true underlying distributions.
  • Robustness: DistNet remained stable in challenging scenarios, such as the Spear-SWGCP dataset, where traditional models struggled with instances having very short runtimes.
  • Data Efficiency: Remarkably, DistNet does not require a large number of runs per training instance. It can learn effective distributions with as few as 16 observations per instance. In the YalSAT-QCP dataset, DistNet trained on 16 samples outperformed a Random Forest trained on 100 samples, offering a significant reduction in data collection costs.

Conclusion and Future Directions

DistNet demonstrates that joint parameter learning via neural networks is a powerful tool for predicting algorithm performance. By optimizing for likelihood rather than isolated statistics, it captures the complex shapes of runtime distributions more accurately than previous state-of-the-art methods.

Future work will address current limitations, such as handling "censored" data from timed-out runs and exploring non-parametric models or mixture distributions to accommodate instances where the best-fitting distribution family might vary.

Summary updated

BibTeX
@inproceedings{eggensperger2018neural,
  author = {Katharina Eggensperger and Marius Lindauer and Frank Hutter},
  title = {{Neural Networks for Predicting Algorithm Runtime Distributions}},
  booktitle = {International Joint Conference on Artificial Intelligence},
  year = {2018},
  url = {https://openreview.net/forum?id=rkZkvmz_WB},
}
Figure