An implementation of two evolutionary algorithms:
simple
-- uses best mean from previous generation (single sample) with a constant, diagonal covariance,cma
-- wrapper aroundcma.CMAEvolutionStrategy
from pycma.
Four 2D optimization problems taken from DEAP Benchmarks are solved -- sphere
, schwefel
, h1
& rastrigin
.
$ python main.py h1 cma
$ python main.py rastrigin simple
Plot 3D surfaces for all problems -- saves into ./figs/*.png
:
$ python plotting.py
Python 3.6.8 or above:
$ pip install -r requirements.txt