Skip to main content

A library that implements several derivation-free optimization algorithms (such as genetic optimization).

Project description

pyBlindOpt

A library that implements several derivation-free optimization algorithms (such as genetic optimization). Currently, it implements six different algorithms:

  1. Hill climbing is a mathematical optimization technique that belongs to the family of local search. It is an iterative algorithm that starts with an arbitrary solution to a problem and then attempts to find a better solution by making an incremental change to the solution.
  2. Simulated annealing is a probabilistic technique for approximating the global optimum of a given function. Specifically, it is a metaheuristic to approximate global optimization in a large search space for an optimization problem.
  3. Genetic algorithm is a metaheuristic inspired by the process of natural selection that belongs to the larger class of evolutionary algorithms (EA). Genetic algorithms are commonly used to generate high-quality solutions to optimization and search problems by relying on biologically inspired operators such as mutation, crossover, and selection.
  4. Differential evolution is a method that optimizes a problem by iteratively trying to improve a candidate solution with regard to a given measure of quality. Such methods are commonly known as metaheuristics as they make few or no assumptions about the problem being optimized and can search very large spaces of candidate solutions.
  5. Particle swarm optimization is a computational method that optimizes a problem by iteratively trying to improve a candidate solution with regard to a given measure of quality. It solves a problem by having a population of candidate solutions, here dubbed particles, and moving these particles around in the search space according to simple mathematical formula over the particle's position and velocity. Each particle's movement is influenced by its local best-known position but is also guided toward the best-known positions in the search space, which are updated as better positions are found by other particles.
  6. Grey Wolf Optimization (GWO) is a population-based meta-heuristics algorithm that simulates the leadership hierarchy and hunting mechanism of grey wolves in nature.

All the algorithms take advantage of the joblib library to speed up the objective function and cache the results. The code was optimized to a certain degree but was made for teaching purposes. Please consider other libraries if you are looking for a stable implementation, such as pymoo. Regardless, any reported issues will be fixed as possible.

Installation

The library can be used by adding this line to the requirement.txt file:

git+https://github.com/mariolpantunes/pyBlindOpt@main#egg=pyBlindOpt

Or add the following line to the requirements.txt file:

pyBlindOpt>=0.1.3

Documentation

This library was documented using the google style docstring, it can be accessed here. Run the following commands to produce the documentation for this library.

pdoc --math -d google -o docs pyBlindOpt

Authors

License

This project is licensed under the MIT License - see the LICENSE file for details

Status

Python CI

MIT License

Copyright (c) 2021 Mário Antunes

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

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

pyBlindOpt-0.1.3.tar.gz (13.9 kB view details)

Uploaded Source

Built Distribution

pyBlindOpt-0.1.3-py3-none-any.whl (19.3 kB view details)

Uploaded Python 3

File details

Details for the file pyBlindOpt-0.1.3.tar.gz.

File metadata

  • Download URL: pyBlindOpt-0.1.3.tar.gz
  • Upload date:
  • Size: 13.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for pyBlindOpt-0.1.3.tar.gz
Algorithm Hash digest
SHA256 c4d0b9c0a5ad2d4ad34308e33b0f36e50e3aca01652bd83d48dca839c2b485dc
MD5 a05f9304765a35ea86357e6a2e5c39e8
BLAKE2b-256 d6e125f061b23ab4ad90c54a76de26fcd7ea910899dc19857d8bf049da3475ec

See more details on using hashes here.

File details

Details for the file pyBlindOpt-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: pyBlindOpt-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 19.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for pyBlindOpt-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 7bd757522d055244f8d73acb7d8fba769e1cabe2d19f82704faab2f86ec5bf5a
MD5 056490dd055f089e310dbfb190cd73f5
BLAKE2b-256 0e0eba61104207e197151be250bac89ba85bf59b9dabf3c6034e38cdef491b4f

See more details on using hashes here.

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