python-adaptive/adaptive

:chart_with_upwards_trend: Adaptive: parallel active learning of mathematical functions

What it solves

Adaptive reduces the computational cost of evaluating mathematical functions by avoiding dense grid sampling. Instead of calculating every point in a parameter space, it intelligently selects the most informative points to sample next, which is especially useful for expensive computations where each evaluation takes 50ms or more.

How it works

The library uses "learners" to sample functions at the most interesting locations within a defined parameter space. As more points are evaluated, the learner refines its understanding of the function to optimize subsequent sampling locations. It supports parallel execution across multiple cores or machines via backends like concurrent.futures, mpi4py, loky, ipyparallel, and distributed.

Who it’s for

It is designed for researchers and developers performing numerical analysis or function optimization who need to map multidimensional functions efficiently without wasting resources on unimportant regions of the parameter space.

Highlights

  • Intelligent Adaptive Sampling: Focuses evaluations on areas of interest to save time and resources.
  • Parallel Execution: Scales evaluations across computing clusters for faster results.
  • Live Visualization: Provides real-time plotting and info widgets for Jupyter notebooks.
  • Multidimensional Support: Handles functions with scalar or vector outputs across one or multiple dimensions.
  • Flexible Export: Learned data can be exported as NumPy arrays or Pandas DataFrames.
  • Customizable: Supports various loss functions and provides multiple learner types (1D, 2D, ND, Average, Integrator, and Balancing learners).

Related

  • Project
  • Project
  • Project
  • Project
  • Project