Python module for multiple variable global optimization

I've been working on a detailed comparison of many python global optimizers (I assume you are interested in derivative-free optimization where there are plenty of local minima).

  • hyperopt
  • optuna
  • pysot
  • scipy.optimize
  • pymoo
  • many more (see list of some I left out)

To summarize, I'd recommend scipy.optimize and if you're in dimension less than say ten, the SHGO algorithm therein is really solid. You might want to read up on it if you have a passing interest in homology. It is better than some previous ones, such as basin-hopping, because it cleverly tries to avoid redundant local searches.

The full list and comparisons are in the report


Scipy's optimize module has a dual_annealing function that might fit your needs. Also, you should check out the PyEvolve module for doing a genetic algorithm.


I'm not an expert, but have you looked at:

  • Scipy's optimize: http://docs.scipy.org/doc/scipy/reference/optimize.html#global
  • NLOpt: http://ab-initio.mit.edu/wiki/index.php/NLopt_Introduction
  • OpenOpt: http://openopt.org/Foreword

One of the most common is scipy.optimize.

For genetic algorithms, there's pygene.

Also, the aima-python project has implementations of algorithms described in Russell and Norvig's "Artificial Intelligence: A Modern Approach".