Skip to content

Add optimizers from nevergrad #591

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 45 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
3774d36
add nevregrd cma
gauravmanmode Apr 23, 2025
3e25025
Merge remote-tracking branch 'upstream/main' into add_optimizer_from_…
gauravmanmode Apr 23, 2025
c8901b2
Merge branch 'main' into add_optimizer_from_nevergrad
janosg Apr 28, 2025
a128367
Merge branch 'main' into add_optimizer_from_nevergrad
janosg Apr 28, 2025
7ca19c2
Merge branch 'main' into add_optimizer_from_nevergrad
gauravmanmode Apr 30, 2025
9c0eafd
Update environment.yml
gauravmanmode Apr 30, 2025
4f76bf2
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Apr 30, 2025
c8114b2
fixes
gauravmanmode May 1, 2025
389b1cc
remove executor
gauravmanmode May 4, 2025
7c73c8d
docs
gauravmanmode May 4, 2025
231e9b2
add docs
gauravmanmode May 5, 2025
f40ac8f
improve error msg
gauravmanmode May 8, 2025
94e3582
improve error msg
gauravmanmode May 8, 2025
1669438
refactor
gauravmanmode May 13, 2025
e71d90f
fix algorithms
gauravmanmode May 14, 2025
400c3c5
Merge branch 'main' into add_optimizer_from_nevergrad
gauravmanmode May 14, 2025
2abc1d1
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 14, 2025
e3ac50e
Update refs.bib
gauravmanmode May 14, 2025
c37610c
Merge branch 'optimagic-dev:main' into add_optimizer_from_nevergrad
gauravmanmode May 22, 2025
f16ceef
add docstrings , add more options in cmaes, improve types
gauravmanmode Jun 3, 2025
a36bde0
add docs
gauravmanmode Jun 3, 2025
5fe5f26
add docs
gauravmanmode Jun 3, 2025
209ab05
handle infinite bounds
gauravmanmode Jun 3, 2025
05f1959
minor fixes
gauravmanmode Jun 5, 2025
b5ea2da
make req changes and add de
gauravmanmode Jun 19, 2025
d596c8c
add optimizers and meta optimizers, add non_linear constraints
gauravmanmode Jun 23, 2025
019df76
fixes
gauravmanmode Jun 23, 2025
978afaa
add -inf as lower_bound in nonlinear constraints and fix test
gauravmanmode Jun 25, 2025
468a564
add docs and tests
gauravmanmode Jun 25, 2025
6382964
add remaining
gauravmanmode Jun 26, 2025
f390eb0
add remaining
gauravmanmode Jun 26, 2025
c2d29a7
add cma
gauravmanmode Jun 26, 2025
8485d66
add bayes_optim
gauravmanmode Jun 26, 2025
1974425
add citations
gauravmanmode Jun 26, 2025
66de721
fixing changes, add tests
gauravmanmode Jun 29, 2025
7b2e6d5
Merge branch 'main' into add_optimizer_from_nevergrad
gauravmanmode Jun 29, 2025
753281f
Merge branch 'main' into add_optimizer_from_nevergrad
gauravmanmode Jul 8, 2025
d297767
Merge branch 'main' into add_optimizer_from_nevergrad
gauravmanmode Jul 9, 2025
20719af
Merge branch 'main' into add_optimizer_from_nevergrad
gauravmanmode Jul 12, 2025
96cfe92
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 12, 2025
d1ca5d6
remove axp
gauravmanmode Jul 5, 2025
3820935
separate non_linear constarints case
gauravmanmode Jul 12, 2025
69fd18c
remove tests non_linear constarints case
gauravmanmode Jul 12, 2025
3bb3c28
supports_non_linear = False
gauravmanmode Jul 12, 2025
86e314e
remove spsa
gauravmanmode Jul 12, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .tools/envs/testenv-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,14 @@ dependencies:
- jinja2 # dev, tests
- annotated-types # dev, tests
- iminuit # dev, tests
- cma # dev, tests
- pip: # dev, tests, docs
- nevergrad # dev, tests
- DFO-LS>=1.5.3 # dev, tests
- Py-BOBYQA # dev, tests
- fides==0.7.4 # dev, tests
- nevergrad # dev, tests
- kaleido>=1.0 # dev, tests
- bayes_optim # dev, tests
- pandas-stubs # dev, tests
- types-cffi # dev, tests
- types-openpyxl # dev, tests
Expand Down
4 changes: 3 additions & 1 deletion .tools/envs/testenv-numpy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,14 @@ dependencies:
- jinja2 # dev, tests
- annotated-types # dev, tests
- iminuit # dev, tests
- cma # dev, tests
- pip: # dev, tests, docs
- nevergrad # dev, tests
- DFO-LS>=1.5.3 # dev, tests
- Py-BOBYQA # dev, tests
- fides==0.7.4 # dev, tests
- nevergrad # dev, tests
- kaleido>=1.0 # dev, tests
- bayes_optim # dev, tests
- types-cffi # dev, tests
- types-openpyxl # dev, tests
- types-jinja2 # dev, tests
Expand Down
4 changes: 3 additions & 1 deletion .tools/envs/testenv-others.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,14 @@ dependencies:
- jinja2 # dev, tests
- annotated-types # dev, tests
- iminuit # dev, tests
- cma # dev, tests
- pip: # dev, tests, docs
- nevergrad # dev, tests
- DFO-LS>=1.5.3 # dev, tests
- Py-BOBYQA # dev, tests
- fides==0.7.4 # dev, tests
- nevergrad # dev, tests
- kaleido>=1.0 # dev, tests
- bayes_optim # dev, tests
- pandas-stubs # dev, tests
- types-cffi # dev, tests
- types-openpyxl # dev, tests
Expand Down
4 changes: 3 additions & 1 deletion .tools/envs/testenv-pandas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,14 @@ dependencies:
- jinja2 # dev, tests
- annotated-types # dev, tests
- iminuit # dev, tests
- cma # dev, tests
- pip: # dev, tests, docs
- nevergrad # dev, tests
- DFO-LS>=1.5.3 # dev, tests
- Py-BOBYQA # dev, tests
- fides==0.7.4 # dev, tests
- nevergrad # dev, tests
- kaleido>=1.0 # dev, tests
- bayes_optim # dev, tests
- types-cffi # dev, tests
- types-openpyxl # dev, tests
- types-jinja2 # dev, tests
Expand Down
4 changes: 3 additions & 1 deletion .tools/envs/testenv-plotly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,13 @@ dependencies:
- jinja2 # dev, tests
- annotated-types # dev, tests
- iminuit # dev, tests
- cma # dev, tests
- pip: # dev, tests, docs
- nevergrad # dev, tests
- DFO-LS>=1.5.3 # dev, tests
- Py-BOBYQA # dev, tests
- fides==0.7.4 # dev, tests
- nevergrad # dev, tests
- bayes_optim # dev, tests
- pandas-stubs # dev, tests
- types-cffi # dev, tests
- types-openpyxl # dev, tests
Expand Down
626 changes: 584 additions & 42 deletions docs/source/algorithms.md

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/source/how_to/how_to_algorithm_selection.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"display_name": "optimagic-docs",
"language": "python",
"name": "python3"
},
Expand All @@ -359,7 +359,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.15"
"version": "3.10.16"
}
},
"nbformat": 4,
Expand Down
4 changes: 2 additions & 2 deletions docs/source/how_to/how_to_bounds.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"display_name": "optimagic-docs",
"language": "python",
"name": "python3"
},
Expand All @@ -254,7 +254,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.14"
"version": "3.10.16"
}
},
"nbformat": 4,
Expand Down
114 changes: 114 additions & 0 deletions docs/source/refs.bib
Original file line number Diff line number Diff line change
Expand Up @@ -906,6 +906,17 @@ @article{JAMES1975343
author = {F. James and M. Roos}
}


@misc{Hansen2023,
title={The CMA Evolution Strategy: A Tutorial},
author={Nikolaus Hansen},
year={2023},
eprint={1604.00772},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/1604.00772},
}

@InProceedings{Kennedy1995,
author={Kennedy, J. and Eberhart, R.},
booktitle={Proceedings of ICNN'95 - International Conference on Neural Networks},
Expand All @@ -927,4 +938,107 @@ @InProceedings{Zambrano2013
doi = {10.1109/CEC.2013.6557848},
}

@inbook{randomsearch2010,
author = {Zabinsky, Zelda},
year = {2010},
month = {06},
pages = {},
title = {Random Search Algorithms},
isbn = {9780470400531},
doi = {10.1002/9780470400531.eorms0704}
}

@INPROCEEDINGS{spsaimpl,
author={Rastogi, Pushpendre and Zhu, Jingyi and Spall, James C.},
booktitle={2016 Annual Conference on Information Science and Systems (CISS)},
title={Efficient implementation of enhanced adaptive simultaneous perturbation algorithms},
year={2016},
volume={},
number={},
pages={298-303},
keywords={Estimation;Algorithm design and analysis;Adaptive Estimation;Simultaneous Perturbation Stochastic Approximation (SPSA);Woodbury Matrix Identity},
doi={10.1109/CISS.2016.7460518}}

@inproceedings{tbpsaimpl,
author = {Hellwig, Michael and Beyer, Hans-Georg},
year = {2016},
month = {09},
pages = {},
title = {Evolution under Strong Noise: A Self-Adaptive Evolution Strategy Can Reach the Lower Performance Bound - the pcCMSA-ES},
volume = {9921},
isbn = {9783319458229},
doi = {10.1007/978-3-319-45823-6_3}
}

@ARTICLE{cgaimpl,
author={Harik, G.R. and Lobo, F.G. and Goldberg, D.E.},
journal={IEEE Transactions on Evolutionary Computation},
title={The compact genetic algorithm},
year={1999},
volume={3},
number={4},
pages={287-297},
keywords={Genetic algorithms;Algorithm design and analysis;Laboratories;Computer simulation;Genetic engineering;Probability distribution;Computational modeling;History;Convergence;Mathematical model},
doi={10.1109/4235.797971}}

@inproceedings{bayesoptimimpl,
author = {Raponi, Elena and Wang, Hao and Bujny, Mariusz and Boria, Simonetta and Doerr, Carola},
title = {High Dimensional Bayesian Optimization Assisted by Principal Component Analysis},
year = {2020},
isbn = {978-3-030-58111-4},
publisher = {Springer-Verlag},
address = {Berlin, Heidelberg},
url = {https://doi.org/10.1007/978-3-030-58112-1_12},
doi = {10.1007/978-3-030-58112-1_12},
abstract = {Bayesian Optimization (BO) is a surrogate-assisted global optimization technique that has been successfully applied in various fields, e.g., automated machine learning and design optimization. Built upon a so-called infill-criterion and Gaussian Process regression (GPR), the BO technique suffers from a substantial computational complexity and hampered convergence rate as the dimension of the search spaces increases. Scaling up BO for high-dimensional optimization problems remains a challenging task.In this paper, we propose to tackle the scalability of BO by hybridizing it with a Principal Component Analysis (PCA), resulting in a novel PCA-assisted BO (PCA-BO) algorithm. Specifically, the PCA procedure learns a linear transformation from all the evaluated points during the run and selects dimensions in the transformed space according to the variability of evaluated points. We then construct the GPR model, and the infill-criterion in the space spanned by the selected dimensions.We assess the performance of our PCA-BO in terms of the empirical convergence rate and CPU time on multi-modal problems from the COCO benchmark framework. The experimental results show that PCA-BO can effectively reduce the CPU time incurred on high-dimensional problems, and maintains the convergence rate on problems with an adequate global structure. PCA-BO therefore provides a satisfactory trade-off between the convergence rate and computational efficiency opening new ways to benefit from the strength of BO approaches in high dimensional numerical optimization.},
booktitle = {Parallel Problem Solving from Nature – PPSN XVI: 16th International Conference, PPSN 2020, Leiden, The Netherlands, September 5-9, 2020, Proceedings, Part I},
pages = {169–183},
numpages = {15},
keywords = {Dimensionality reduction, Principal Component Analysis, Black-box optimization, Bayesian optimization},
location = {Leiden, The Netherlands}
}

@book{Rechenberg1973,
author = {Rechenberg, Ingo},
title = {Evolutionsstrategie: Optimierung technischer Systeme nach Prinzipien der biologischen Evolution},
publisher = {Frommann-Holzboog Verlag},
year = {1973},
url = {https://gwern.net/doc/reinforcement-learning/exploration/1973-rechenberg.pdf},
address = {Stuttgart},
note = {[Evolution Strategy: Optimization of Technical Systems According to the Principles of Biological Evolution]}
}

@article{Schumer1968,
author={Schumer, M. and Steiglitz, K.},
journal={IEEE Transactions on Automatic Control},
title={Adaptive step size random search},
year={1968},
volume={13},
number={3},
pages={270-276},
keywords={Minimization methods;Gradient methods;Search methods;Adaptive control;Communication systems;Q measurement;Cost function;Newton method;Military computing},
doi={10.1109/TAC.1968.1098903}
}

@misc{edaimpl,
title={Theory of Estimation-of-Distribution Algorithms},
author={Martin S. Krejca and Carsten Witt},
year={2018},
eprint={1806.05392},
archivePrefix={arXiv},
primaryClass={cs.NE},
url={https://arxiv.org/abs/1806.05392},
}

@book{emnaimpl,
author = {Larranaga, Pedro and Lozano, Jose},
year = {2002},
month = {01},
pages = {},
title = {Estimation of Distribution Algorithms: A New Tool for Evolutionary Computation},
isbn = {9781461356042},
journal = {Genetic algorithms and evolutionary computation ; 2},
doi = {10.1007/978-1-4615-1539-5}
}

@Comment{jabref-meta: databaseType:bibtex;}
4 changes: 3 additions & 1 deletion environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,15 @@ dependencies:
- furo # dev, docs
- annotated-types # dev, tests
- iminuit # dev, tests
- cma # dev, tests
- pip: # dev, tests, docs
- nevergrad # dev, tests
- DFO-LS>=1.5.3 # dev, tests
- Py-BOBYQA # dev, tests
- fides==0.7.4 # dev, tests
- nevergrad # dev, tests
- kaleido>=1.0 # dev, tests
- pre-commit>=4 # dev
- bayes_optim # dev, tests
- -e . # dev
# type stubs
- pandas-stubs # dev, tests
Expand Down
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ dependencies = [
"sqlalchemy>=1.3",
"annotated-types",
"typing-extensions",
"iminuit",
]
dynamic = ["version"]
keywords = [
Expand Down
Loading
Loading