Solve black-box optimization problems using surrogate-based algorithms
Project description
Black-box Opt
Solve black-box optimization problems using surrogate-based algorithms.
Current functionality
The Black-box optimization package currently supports the following algorithms:
| Optimization algorithm | Description | Tags |
|---|---|---|
surrogate_optimization() |
Minimize a scalar function using a surrogate and an acquisition function based on (Björkman & Holmström; 2000) and (Müller; 2016). | mixed-integer |
multistart_msrs() |
Multistart Local Metric Stochastic Response Surface (LMSRS) (Regis & Shoemaker; 2007). Applies a derivative-free local search algorithm to obtain new samples. Restarts the surrogate model with new design points whenever the local search has converged. | multi-start, RBF |
dycors() |
Dynamic Coordinate Search (DYCORS) (Regis & Shoemaker; 2012). Acquisition cycles between global and local search. Uses the DDS search from (Tolson & Shoemaker; 2007) to generate pools of candidates. | mixed-integer, RBF |
cptv() |
Minimize a scalar function using rounds of coordinate perturbation (CP) and target value (TV) acquisition functions (Müller; 2016). Derivative-free local search is used to improve a prospective global minimum | mixed-integer, RBF |
socemo() |
Surrogate-based optimization of computationally expensive multiobjective problems (SOCEMO) (Müller; 2017a). | multi-objective, mixed-integer, RBF |
gosac() |
Global optimization with surrogate approximation of constraints (GOSAC) (Müller; 2017b). | mixed-integer, black-box-constraint, RBF |
bayesian_optimization() |
Bayesian optimization with dispersion-enhanced expected improvement acquisition (Müller; 2024). | GP, batch |
| Acquisition function | Description |
|---|---|
WeightedAcquisition |
Weighted acquisition function based on the predicted value and distance to the nearest sample (Regis & Shoemaker; 2012). Used in multistart_msrs(), dycors(), and in the CP step from cptv(). It uses average values for the multi-objective scenario (Müller; 2017a). |
TargetValueAcquisition |
Target value acquisition based from (Gutmann; 2001). Used in the TV step from cptv(). Cycles through target values as in (Björkman & Holmström; 2000). For batched acquisition, uses the strategy from (Müller; 2016) to avoid duplicates. |
MinimizeSurrogate |
Sample at the local minimum of the surrogate model (Müller; 2016). The original method, Multi-Level Single-Linkage (MLSL), is described in (Rinnooy Kan & Timmer; 1987). |
MaximizeEI |
Maximize the expected improvement acquisition function for Gaussian processes. Use the dispersion-enhanced strategy from (Müller; 2024) for batch sampling. |
ParetoFront |
Sample at the Pareto front of the multi-objective surrogate model to fill gaps in the surface (Müller; 2017a). |
MinimizeMOSurrogate |
Obtain pareto-optimal sample points for the multi-objective surrogate model (Müller; 2017a). |
GosacSample |
Minimize a function with surrogate constraints to obtain a single new sample point (Müller; 2017b). |
Installation
Use PyPI to install this package:
pip install blackboxoptim
See other installation methods below.
Binaries
The binaries for the latest version are available at https://github.com/NREL/blackboxoptim/releases/latest. They can be installed through standard installation, e.g.,
using pip (https://pip.pypa.io/en/stable/cli/pip_install/):
pip install git+https://github.com/NREL/blackboxoptim.git#egg=blackboxoptim
From source
This package contains a pyproject.toml with the list of requirements and dependencies (More about pyproject.toml at https://packaging.python.org/en/latest/specifications/pyproject-toml/). With the source downloaded to your local machine, use pip install [blackboxoptim/source/directory].
For developers
This project is configured to use the package manager pdm. With pdm installed, run pdm install at the root of this repository to install the dependencies. The file pyproject.toml has the list of dependencies and configurations for the project.
Documentation
This project uses Sphinx to generate the documentation. The latest documentation is available at https://nrel.github.io/blackboxoptim. To generate the documentation locally, run make html in the docs directory. The homepage of the documentation will then be found at docs/_build/html/index.html.
Testing
This project uses pytest to run the tests. To run the tests, run pytest at the root of this repository. Run pytest --help to see the available options.
Contributing
Please, read the contributing guidelines before contributing to this project.
License
This project is licensed under the GPL-3.0 License. See the LICENSE file for details.
NREL Software Record number: SWR-24-57
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file blackboxoptim-1.1.0.tar.gz.
File metadata
- Download URL: blackboxoptim-1.1.0.tar.gz
- Upload date:
- Size: 104.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5b0a67a083d85f1eb730ada0f2a914b9457a62b671c04c45cecaae22895261f8
|
|
| MD5 |
105fcf835d4f186345b4f2a9dc7a52b7
|
|
| BLAKE2b-256 |
e0af499db39dc226d6382e7ec718bf31b8faf5b2234e769603fae113f9391a9c
|
Provenance
The following attestation bundles were made for blackboxoptim-1.1.0.tar.gz:
Publisher:
python-publish.yml on NREL/blackboxoptim
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
blackboxoptim-1.1.0.tar.gz -
Subject digest:
5b0a67a083d85f1eb730ada0f2a914b9457a62b671c04c45cecaae22895261f8 - Sigstore transparency entry: 185123428
- Sigstore integration time:
-
Permalink:
NREL/blackboxoptim@58410c0578baec706dd0c860fa5abd05b22c287d -
Branch / Tag:
refs/tags/v1.1.0 - Owner: https://github.com/NREL
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@58410c0578baec706dd0c860fa5abd05b22c287d -
Trigger Event:
release
-
Statement type:
File details
Details for the file blackboxoptim-1.1.0-py3-none-any.whl.
File metadata
- Download URL: blackboxoptim-1.1.0-py3-none-any.whl
- Upload date:
- Size: 72.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2b60eba4b19b641f66812b52d128c10ecf913e4b2703c521bb1f67aa258de32d
|
|
| MD5 |
dd9040880e4d56db0d0fcfa86d6aee92
|
|
| BLAKE2b-256 |
140135ce4efa09a9511228eba9a5679a54f69f103e1c64e3c33da39a9bb84da2
|
Provenance
The following attestation bundles were made for blackboxoptim-1.1.0-py3-none-any.whl:
Publisher:
python-publish.yml on NREL/blackboxoptim
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
blackboxoptim-1.1.0-py3-none-any.whl -
Subject digest:
2b60eba4b19b641f66812b52d128c10ecf913e4b2703c521bb1f67aa258de32d - Sigstore transparency entry: 185123431
- Sigstore integration time:
-
Permalink:
NREL/blackboxoptim@58410c0578baec706dd0c860fa5abd05b22c287d -
Branch / Tag:
refs/tags/v1.1.0 - Owner: https://github.com/NREL
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@58410c0578baec706dd0c860fa5abd05b22c287d -
Trigger Event:
release
-
Statement type: