Skip to main content

Heuristic and meta-heuristic optimisation suite in Python

Project description

FreeLunch - Meta-heuristic optimisation suite for python

Build Status codecov

Basically a dump of useful / funny metaheurisitcs with a (hopefully) simpe interface

Feeling cute might add benchmarking later idk

There are literally so many implementations of all of these so... here's one more!

Features

Optimisers

Your favourite not in the list? Feel free to add it.

  • Differential evolution freelunch.DE
  • Simulated Annealing freelunch.SA

Benchmarking functions

Tier list: TBA

  • N-dimensional Ackley function
  • N-dimensional Periodic function
  • N-dimensional Happy Cat function
  • N-dimensional Exponential function

Usage

Install with pip (req. numpy).

pip install freelunch

Import and instance your favourite meta-hueristics!

import freelunch
opt = freelunch.DE(obj=my_objective_function, bounds=my_bounds)

Return best solution only.

quick_result = opt()

Return optimum after nruns

best_of_runs = opt(nruns = n) 

Return best m solutions in np.ndarray

best_m = opt(return_m = m)

Return json friendly dict with fun metadata!

full_output = opt(full_output = True)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

freelunch-0.0.1.tar.gz (5.3 kB view hashes)

Uploaded Source

Built Distribution

freelunch-0.0.1-py3-none-any.whl (6.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page