dfbench 0.2.2__tar.gz → 0.3.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (184) hide show
  1. {dfbench-0.2.2 → dfbench-0.3.1}/PKG-INFO +6 -9
  2. {dfbench-0.2.2 → dfbench-0.3.1}/README.md +4 -5
  3. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Algorithms.md +1 -1
  4. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Implementing-a-New-Algorithm.md +6 -2
  5. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Installation.md +4 -4
  6. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Objective-API-Reference.md +1 -1
  7. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Testing.md +3 -2
  8. {dfbench-0.2.2 → dfbench-0.3.1}/pyproject.toml +2 -4
  9. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/__init__.py +1 -1
  10. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/_dfo_common.py +5 -5
  11. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/_scipy_common.py +4 -4
  12. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/omads_mads.py +2 -3
  13. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/pdfo/lincoa.py +5 -17
  14. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/cmaes_sep_cma.py +3 -4
  15. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/evosax_es.py +6 -8
  16. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/evox_es.py +5 -13
  17. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/evox_pso.py +2 -8
  18. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/jax_es.py +6 -8
  19. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/nevergrad/ngopt.py +2 -6
  20. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/nevergrad/oneplusone.py +2 -6
  21. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/nevergrad/tbpsa.py +2 -6
  22. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/pycma_cmaes.py +12 -16
  23. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/generative/vae_sampling.py +1 -2
  24. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/global_search/basin_hopping.py +2 -3
  25. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/_common.py +6 -17
  26. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/ax_baxus.py +2 -3
  27. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/ax_saasbo.py +20 -21
  28. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/_botorch_common.py +3 -3
  29. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/botorch_bo.py +7 -8
  30. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/botorch_gebo.py +4 -5
  31. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/botorch_linebo.py +2 -3
  32. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/botorch_qkg.py +2 -3
  33. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/botorch_qnei.py +2 -3
  34. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/botorch_rembo.py +2 -3
  35. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/botorch_turbo.py +4 -5
  36. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/hebo_bo.py +16 -9
  37. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/restir.py +1 -2
  38. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/smac_bo.py +3 -4
  39. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/turbo_lbfgs.py +3 -4
  40. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/algorithm.py +2 -1
  41. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/display.py +1 -1
  42. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/objective.py +5 -5
  43. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/problems/base_problem.py +6 -0
  44. dfbench-0.3.1/tests/slow/test_problem_bounds_gradients.py +106 -0
  45. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_bo_batch.py +5 -5
  46. dfbench-0.3.1/tests/test_hebo_packaging.py +53 -0
  47. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_objective_invariants.py +7 -7
  48. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_objective_penalty_fn.py +0 -1
  49. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_objective_randomness.py +1 -1
  50. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_scipy_wrapper.py +1 -17
  51. {dfbench-0.2.2 → dfbench-0.3.1}/.gitignore +0 -0
  52. {dfbench-0.2.2 → dfbench-0.3.1}/LICENSE +0 -0
  53. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Algorithm-Status.md +0 -0
  54. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Architecture-Overview.md +0 -0
  55. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Benchmarking.md +0 -0
  56. {dfbench-0.2.2 → dfbench-0.3.1}/docs/FAQ.md +0 -0
  57. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Home.md +0 -0
  58. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Metrics-Reference.md +0 -0
  59. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Problems.md +0 -0
  60. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Storage-and-Checkpointing.md +0 -0
  61. {dfbench-0.2.2 → dfbench-0.3.1}/docs/Utilities-and-Helpers.md +0 -0
  62. {dfbench-0.2.2 → dfbench-0.3.1}/docs/_Sidebar.md +0 -0
  63. {dfbench-0.2.2 → dfbench-0.3.1}/docs/algorithm-status/main.typ +0 -0
  64. {dfbench-0.2.2 → dfbench-0.3.1}/docs/algorithm-status/template.typ +0 -0
  65. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/__init__.py +0 -0
  66. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/__init__.py +0 -0
  67. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/nelder_mead.py +0 -0
  68. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/pdfo/__init__.py +0 -0
  69. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/pdfo/newuoa.py +0 -0
  70. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/pdfo/uobyqa.py +0 -0
  71. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/powell.py +0 -0
  72. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/derivative_free/pybobyqa.py +0 -0
  73. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/__init__.py +0 -0
  74. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/nevergrad/__init__.py +0 -0
  75. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/evolutionary/nevergrad/_common.py +0 -0
  76. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/global_search/__init__.py +0 -0
  77. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/global_search/dual_annealing.py +0 -0
  78. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/global_search/random_search.py +0 -0
  79. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/__init__.py +0 -0
  80. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/adam_gd.py +0 -0
  81. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/custom_jax.py +0 -0
  82. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/lbfgs_gd.py +0 -0
  83. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/na_adam_gd.py +0 -0
  84. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/__init__.py +0 -0
  85. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/_common.py +0 -0
  86. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adabelief.py +0 -0
  87. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adadelta.py +0 -0
  88. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adafactor.py +0 -0
  89. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adagrad.py +0 -0
  90. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adam.py +0 -0
  91. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adamax.py +0 -0
  92. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adamaxw.py +0 -0
  93. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adamw.py +0 -0
  94. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/adan.py +0 -0
  95. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/amsgrad.py +0 -0
  96. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/lamb.py +0 -0
  97. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/lion.py +0 -0
  98. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/lookahead.py +0 -0
  99. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/nadam.py +0 -0
  100. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/nadamw.py +0 -0
  101. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/noisy_sgd.py +0 -0
  102. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/novograd.py +0 -0
  103. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/oadam.py +0 -0
  104. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/ogd.py +0 -0
  105. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/polyak_sgd.py +0 -0
  106. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/radam.py +0 -0
  107. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/rmsprop.py +0 -0
  108. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/rprop.py +0 -0
  109. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/sam.py +0 -0
  110. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/schedule_free_adam.py +0 -0
  111. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/sgd.py +0 -0
  112. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/sign.py +0 -0
  113. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/sm3.py +0 -0
  114. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/sophia.py +0 -0
  115. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax/yogi.py +0 -0
  116. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/optax_lbfgs.py +0 -0
  117. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/sa_gd.py +0 -0
  118. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/__init__.py +0 -0
  119. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/bfgs.py +0 -0
  120. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/cobyla.py +0 -0
  121. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/cobyqa.py +0 -0
  122. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/dogleg.py +0 -0
  123. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/lbfgsb.py +0 -0
  124. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/newton_cg.py +0 -0
  125. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/nonlinear_cg.py +0 -0
  126. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/slsqp.py +0 -0
  127. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/sr1.py +0 -0
  128. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/tnc.py +0 -0
  129. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/trust_constr.py +0 -0
  130. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/trust_krylov.py +0 -0
  131. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/gradient_based/scipy/trust_ncg.py +0 -0
  132. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/__init__.py +0 -0
  133. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/surrogate_based/botorch/__init__.py +0 -0
  134. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/utils/__init__.py +0 -0
  135. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/utils/gp.py +0 -0
  136. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/utils/initial_design.py +0 -0
  137. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/utils/misc.py +0 -0
  138. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/algorithms/utils/weighted_acq.py +0 -0
  139. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/benchmark/__init__.py +0 -0
  140. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/benchmark/benchmark.py +0 -0
  141. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/benchmark/metrics.py +0 -0
  142. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/_init_env.py +0 -0
  143. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/config.py +0 -0
  144. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/problem.py +0 -0
  145. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/storage/__init__.py +0 -0
  146. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/storage/backends.py +0 -0
  147. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/storage/exporter.py +0 -0
  148. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/storage/manager.py +0 -0
  149. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/storage/resolver.py +0 -0
  150. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/storage/saveconfig.py +0 -0
  151. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/storage/serializers.py +0 -0
  152. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/storage/state.py +0 -0
  153. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/core/utils.py +0 -0
  154. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/problems/__init__.py +0 -0
  155. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/problems/uifo/__init__.py +0 -0
  156. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/problems/uifo/uifo_problem.py +0 -0
  157. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/problems/voyager/__init__.py +0 -0
  158. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/problems/voyager/constrained_voyager_problem.py +0 -0
  159. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/problems/voyager/voyager_problem.py +0 -0
  160. {dfbench-0.2.2 → dfbench-0.3.1}/src/dfbench/problems/voyager/voyager_tuning_problem.py +0 -0
  161. {dfbench-0.2.2 → dfbench-0.3.1}/tests/__init__.py +0 -0
  162. {dfbench-0.2.2 → dfbench-0.3.1}/tests/conftest.py +0 -0
  163. {dfbench-0.2.2 → dfbench-0.3.1}/tests/slow/__init__.py +0 -0
  164. {dfbench-0.2.2 → dfbench-0.3.1}/tests/slow/test_algorithms_integration.py +0 -0
  165. {dfbench-0.2.2 → dfbench-0.3.1}/tests/slow/test_benchmark_full.py +0 -0
  166. {dfbench-0.2.2 → dfbench-0.3.1}/tests/slow/test_problems_full.py +0 -0
  167. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_algorithm_protocol.py +0 -0
  168. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_algorithms_uniform.py +0 -0
  169. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_algorithms_unit.py +0 -0
  170. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_api_imports.py +0 -0
  171. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_benchmark_smoke.py +0 -0
  172. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_cma_family.py +0 -0
  173. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_config.py +0 -0
  174. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_custom_jax_batch.py +0 -0
  175. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_dfo_algorithms.py +0 -0
  176. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_display.py +0 -0
  177. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_init_env.py +0 -0
  178. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_metrics.py +0 -0
  179. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_objective_space_mode.py +0 -0
  180. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_problem_bounds_overrides.py +0 -0
  181. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_problem_protocol.py +0 -0
  182. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_problem_spec.py +0 -0
  183. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_storage.py +0 -0
  184. {dfbench-0.2.2 → dfbench-0.3.1}/tests/test_utils.py +0 -0
@@ -1,7 +1,7 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dfbench
3
- Version: 0.2.2
4
- Summary: Differometor Benchmark - Optimization algorithms and problem definitions
3
+ Version: 0.3.1
4
+ Summary: dfbench: A Black-Box Optimization Framework for JAX-Differentiable Gravitational Wave Detector Discovery
5
5
  Project-URL: Homepage, https://github.com/artificial-scientist-lab/Differometor-Benchmark
6
6
  Project-URL: Repository, https://github.com/artificial-scientist-lab/Differometor-Benchmark
7
7
  Project-URL: Documentation, https://github.com/artificial-scientist-lab/Differometor-Benchmark/tree/main/docs
@@ -34,7 +34,6 @@ Requires-Dist: cmaes>=0.10.0; extra == 'all'
34
34
  Requires-Dist: evosax>=0.1.6; extra == 'all'
35
35
  Requires-Dist: evox>=1.3.0; extra == 'all'
36
36
  Requires-Dist: gpytorch>=1.14; extra == 'all'
37
- Requires-Dist: hebo>=0.3.2; extra == 'all'
38
37
  Requires-Dist: nevergrad>=1.0.12; extra == 'all'
39
38
  Requires-Dist: omads>=2408.0; extra == 'all'
40
39
  Requires-Dist: optax>=0.2.6; extra == 'all'
@@ -55,7 +54,6 @@ Provides-Extra: bo
55
54
  Requires-Dist: ax-platform>=1.2.4; extra == 'bo'
56
55
  Requires-Dist: botorch>=0.16.1; extra == 'bo'
57
56
  Requires-Dist: gpytorch>=1.14; extra == 'bo'
58
- Requires-Dist: hebo>=0.3.2; extra == 'bo'
59
57
  Requires-Dist: torch>=2.9.1; extra == 'bo'
60
58
  Provides-Extra: cuda12
61
59
  Requires-Dist: jax[cuda12]==0.9.0.1; extra == 'cuda12'
@@ -90,9 +88,6 @@ Provides-Extra: torch
90
88
  Requires-Dist: torch>=2.9.1; extra == 'torch'
91
89
  Description-Content-Type: text/markdown
92
90
 
93
- > [!IMPORTANT]
94
- > **BETA RELEASE:** This repository is currently in beta. The official competition will start on **July ~7**.
95
-
96
91
  # Differometor Benchmark
97
92
 
98
93
  [![image](https://img.shields.io/pypi/v/dfbench.svg)](https://pypi.python.org/pypi/dfbench)
@@ -200,11 +195,13 @@ pip install "dfbench[optax,scipy]" # Common local optimizers
200
195
  pip install "dfbench[evolution]" # CMA, EvoX, Nevergrad, Evosax
201
196
  pip install "dfbench[bo]" # BoTorch/Ax surrogate optimizers
202
197
  pip install "dfbench[dfo,smac]" # Derivative-free and SMAC optimizers
203
- pip install "dfbench[all]" # All optimizer backends
198
+ pip install "dfbench[all]" # All packaged optimizer backends
204
199
  pip install "dfbench[cuda13]" # CUDA 13 JAX support
205
200
  pip install "dfbench[analysis]" # Notebook/profiling tools
206
201
  ```
207
202
 
203
+ The HEBO adapter is available in the API, but no dfbench extra installs HEBO because its dependency stack conflicts with dfbench's NumPy 2.x stack. Use it only with a separately managed compatible HEBO installation.
204
+
208
205
  ### From Source With `uv` (recommended for development)
209
206
 
210
207
  [uv](https://uv.dev/) handles virtual environments and dependency resolution automatically.
@@ -220,7 +217,7 @@ uv sync --group cuda13 --group analysis # Everything
220
217
 
221
218
  ```bash
222
219
  pip install -e . # CPU-only editable install
223
- pip install -e ".[all,cuda13,analysis]" # All backends, CUDA 13, and analysis extras
220
+ pip install -e ".[all,cuda13,analysis]" # Packaged backends, CUDA 13, and analysis extras
224
221
  ```
225
222
 
226
223
  See [Installation](https://github.com/artificial-scientist-lab/Differometor-Benchmark/wiki/Installation) for GPU setup details and HPC notes.
@@ -1,6 +1,3 @@
1
- > [!IMPORTANT]
2
- > **BETA RELEASE:** This repository is currently in beta. The official competition will start on **July ~7**.
3
-
4
1
  # Differometor Benchmark
5
2
 
6
3
  [![image](https://img.shields.io/pypi/v/dfbench.svg)](https://pypi.python.org/pypi/dfbench)
@@ -108,11 +105,13 @@ pip install "dfbench[optax,scipy]" # Common local optimizers
108
105
  pip install "dfbench[evolution]" # CMA, EvoX, Nevergrad, Evosax
109
106
  pip install "dfbench[bo]" # BoTorch/Ax surrogate optimizers
110
107
  pip install "dfbench[dfo,smac]" # Derivative-free and SMAC optimizers
111
- pip install "dfbench[all]" # All optimizer backends
108
+ pip install "dfbench[all]" # All packaged optimizer backends
112
109
  pip install "dfbench[cuda13]" # CUDA 13 JAX support
113
110
  pip install "dfbench[analysis]" # Notebook/profiling tools
114
111
  ```
115
112
 
113
+ The HEBO adapter is available in the API, but no dfbench extra installs HEBO because its dependency stack conflicts with dfbench's NumPy 2.x stack. Use it only with a separately managed compatible HEBO installation.
114
+
116
115
  ### From Source With `uv` (recommended for development)
117
116
 
118
117
  [uv](https://uv.dev/) handles virtual environments and dependency resolution automatically.
@@ -128,7 +127,7 @@ uv sync --group cuda13 --group analysis # Everything
128
127
 
129
128
  ```bash
130
129
  pip install -e . # CPU-only editable install
131
- pip install -e ".[all,cuda13,analysis]" # All backends, CUDA 13, and analysis extras
130
+ pip install -e ".[all,cuda13,analysis]" # Packaged backends, CUDA 13, and analysis extras
132
131
  ```
133
132
 
134
133
  See [Installation](https://github.com/artificial-scientist-lab/Differometor-Benchmark/wiki/Installation) for GPU setup details and HPC notes.
@@ -942,7 +942,7 @@ optimizer.optimize(
942
942
 
943
943
  ### HEBO (Heteroscedastic Evolutionary BO)
944
944
 
945
- Winner of the NeurIPS 2020 BBO challenge. Uses a heteroscedastic GP, input warping, and multi-objective acquisition. Requires the `dfbench[bo]` extra.
945
+ Winner of the NeurIPS 2020 BBO challenge. Uses a heteroscedastic GP, input warping, and multi-objective acquisition. HEBO is not installed by a dfbench extra because its dependency stack conflicts with dfbench's NumPy 2.x stack; using this adapter requires a separately managed compatible installation.
946
946
 
947
947
  Reference: Cowen-Rivers et al., *An Empirical Study of Assumptions in Bayesian Optimisation*, 2020.
948
948
 
@@ -98,7 +98,6 @@ class MyAlgorithm(OptimizationAlgorithm):
98
98
  """
99
99
  # ─── 1. Setup references ───
100
100
  obj = objective
101
- problem = obj.problem
102
101
 
103
102
  # Sets unbounded mode, algorithm_str, seeds np/JAX, returns resolved seed + JAX key
104
103
  random_seed, key = self.prepare(
@@ -179,7 +178,6 @@ The base class `OptimizationAlgorithm.optimize()` contains a commented blueprint
179
178
 
180
179
  ```python
181
180
  obj = objective
182
- problem = obj.problem
183
181
  random_seed, key = self.prepare(
184
182
  obj,
185
183
  unbounded=False,
@@ -187,6 +185,12 @@ random_seed, key = self.prepare(
187
185
  )
188
186
  ```
189
187
 
188
+ The problem instance wrapped by the `Objective` is private. Use the public
189
+ Objective API directly: `obj.bounds` for the `(2, n_params)` bounds,
190
+ `obj.n_params` for the dimension, `obj.problem_name` for the display name,
191
+ `obj.value_function(unbounded=False)` for the raw bounded objective, and
192
+ `obj.penalty_fn` / `obj.power_thresholds` for the penalty contract.
193
+
190
194
  `prepare()` is called as `prepare(obj, unbounded, random_seed, algorithm_str=None, **kwargs)`. It sets `obj.unbounded`, `obj.algorithm_str`, seeds `np.random` and JAX, and returns `(random_seed, key)`. If `random_seed=None` is passed, a seed is generated via system entropy. You can also configure the Objective manually instead of calling `prepare()`.
191
195
 
192
196
  **Choose `unbounded`:**
@@ -21,15 +21,15 @@ The base install keeps heavyweight optimizer backends optional. Add extras for t
21
21
  ```bash
22
22
  pip install "dfbench[optax,scipy]" # common local optimizers
23
23
  pip install "dfbench[evolution]" # CMA, EvoX, Nevergrad, Evosax
24
- pip install "dfbench[bo]" # BoTorch/Ax/HEBO surrogate optimizers
24
+ pip install "dfbench[bo]" # BoTorch/Ax surrogate optimizers
25
25
  pip install "dfbench[dfo,smac]" # derivative-free and SMAC optimizers
26
- pip install "dfbench[all]" # all optimizer backends
26
+ pip install "dfbench[all]" # all packaged optimizer backends
27
27
  pip install "dfbench[cuda13]" # CUDA 13 JAX support
28
28
  pip install "dfbench[cuda12]" # CUDA 12 JAX support
29
29
  pip install "dfbench[analysis]" # notebooks, profiling, plotting helpers
30
30
  ```
31
31
 
32
- `HEBO` is part of the `bo` and `all` extras. The optional backends are imported lazily: `import dfbench` succeeds even when an extra is not installed, and importing an algorithm whose backend is missing raises an `ImportError` pointing to the extra to install (e.g. `uv add 'dfbench[bo]'`).
32
+ `HEBO` is intentionally not exposed through a project extra because its dependency stack is incompatible with dfbench's NumPy 2.x stack. The guarded wrapper remains available for users who provide and test a compatible HEBO installation themselves. Other optional backends are imported lazily: `import dfbench` succeeds when their extras are not installed.
33
33
 
34
34
  ## Development Install with `uv`
35
35
 
@@ -78,7 +78,7 @@ pip install -e .
78
78
  # With CUDA GPU support
79
79
  pip install -e ".[cuda12]"
80
80
 
81
- # With all optimizer backends and analysis tools
81
+ # With all packaged optimizer backends and analysis tools (HEBO excluded)
82
82
  pip install -e ".[all,analysis]"
83
83
  ```
84
84
 
@@ -447,7 +447,7 @@ bounded ≈ lb + (ub - lb) * forward(random_params_unbounded(...))
447
447
  |----------|------|-------------|
448
448
  | `bounds` | `Array[2, n_params]` | Lower and upper parameter bounds (or $\pm\infty$ when unbounded). |
449
449
  | `n_params` | `int` | Number of optimizable parameters. |
450
- | `problem` | `ContinuousProblem` | The wrapped problem instance. |
450
+ | `problem_name` | `str` | Display name of the wrapped problem. |
451
451
  | `penalty_fn` | `Callable \| None` | The wrapped problem's penalty function, or `None` if the problem does not expose one. Update it via `set_penalty_fn(fn)`. |
452
452
  | `power_thresholds` | `dict[str, float] \| None` | Per-group power thresholds (`hard`, `soft`, `detector`) for problems that opt into the penalty contract, or `None`. Constants; do not change across evaluations. |
453
453
 
@@ -229,8 +229,9 @@ The non-pass results all have a single root cause each:
229
229
  * **3** are in `tests/test_bo_batch.py`, gated on optional
230
230
  dependencies that are not installed in the default environment:
231
231
  `ax-platform` (for `AxSAASBO`), `HEBO`, and `SMAC3`. Installing
232
- the corresponding `dfbench` extras (`dfbench[bo]` for AxSAASBO/HEBO,
233
- `dfbench[smac]` for SMAC) re-enables the tests.
232
+ `dfbench[bo]` re-enables AxSAASBO and `dfbench[smac]` re-enables SMAC.
233
+ The HEBO test requires a separately managed compatible installation;
234
+ HEBO is intentionally not supplied by a dfbench extra.
234
235
 
235
236
  There are no unexpected failures; every skip and xfail carries an
236
237
  explanatory reason in the registry / `pytest.mark.skipif`.
@@ -4,8 +4,8 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "dfbench"
7
- version = "0.2.2"
8
- description = "Differometor Benchmark - Optimization algorithms and problem definitions"
7
+ version = "0.3.1"
8
+ description = "dfbench: A Black-Box Optimization Framework for JAX-Differentiable Gravitational Wave Detector Discovery"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.11,<3.14"
11
11
  license = "MIT"
@@ -80,7 +80,6 @@ bo = [
80
80
  "ax-platform>=1.2.4",
81
81
  "botorch>=0.16.1",
82
82
  "gpytorch>=1.14",
83
- "hebo>=0.3.2",
84
83
  "torch>=2.9.1",
85
84
  ]
86
85
  optax = ["optax>=0.2.6"]
@@ -96,7 +95,6 @@ all = [
96
95
  "evox>=1.3.0",
97
96
  "evosax>=0.1.6",
98
97
  "gpytorch>=1.14",
99
- "hebo>=0.3.2",
100
98
  "nevergrad>=1.0.12",
101
99
  "OMADS>=2408.0",
102
100
  "optax>=0.2.6",
@@ -91,7 +91,7 @@ try:
91
91
  except ImportError:
92
92
  pass
93
93
 
94
- # BO extra: botorch, ax, gpytorch, torch, HEBO
94
+ # BO extra: botorch, ax, gpytorch, torch. HEBO is an unbundled backend.
95
95
  try:
96
96
  from dfbench.algorithms.surrogate_based.botorch.botorch_bo import BotorchBO
97
97
  from dfbench.algorithms.surrogate_based.botorch.botorch_turbo import BotorchTuRBO
@@ -81,7 +81,7 @@ def random_bounded_start(
81
81
  (x0, new_key): x0 is a 1-D ``np.ndarray`` of shape ``(n_params,)``.
82
82
  """
83
83
  key, subkey = random.split(key)
84
- lower, upper = obj.problem.bounds
84
+ lower, upper = obj.bounds
85
85
  x0_jax = random.uniform(subkey, shape=(obj.n_params,), minval=lower, maxval=upper)
86
86
  return np.asarray(x0_jax, dtype=np.float64), key
87
87
 
@@ -92,15 +92,15 @@ def clip_to_bounds(x: np.ndarray, obj: Objective) -> np.ndarray:
92
92
  Returns:
93
93
  Clipped copy of *x*.
94
94
  """
95
- lower = np.asarray(obj.problem.bounds[0], dtype=np.float64)
96
- upper = np.asarray(obj.problem.bounds[1], dtype=np.float64)
95
+ lower = np.asarray(obj.bounds[0], dtype=np.float64)
96
+ upper = np.asarray(obj.bounds[1], dtype=np.float64)
97
97
  return np.clip(x, lower, upper)
98
98
 
99
99
 
100
100
  def solver_bounds_np(obj: Objective) -> tuple[np.ndarray, np.ndarray]:
101
101
  """Return ``(lower, upper)`` as plain NumPy float64 arrays."""
102
- lower = np.asarray(obj.problem.bounds[0], dtype=np.float64)
103
- upper = np.asarray(obj.problem.bounds[1], dtype=np.float64)
102
+ lower = np.asarray(obj.bounds[0], dtype=np.float64)
103
+ upper = np.asarray(obj.bounds[1], dtype=np.float64)
104
104
  return lower, upper
105
105
 
106
106
 
@@ -36,15 +36,15 @@ _NAN_PENALTY = 1e30
36
36
 
37
37
  def scipy_bounds(obj: Objective) -> Bounds:
38
38
  """Convert problem bounds to :class:`scipy.optimize.Bounds`."""
39
- lb = np.asarray(obj.problem.bounds[0], dtype=np.float64)
40
- ub = np.asarray(obj.problem.bounds[1], dtype=np.float64)
39
+ lb = np.asarray(obj.bounds[0], dtype=np.float64)
40
+ ub = np.asarray(obj.bounds[1], dtype=np.float64)
41
41
  return Bounds(lb, ub)
42
42
 
43
43
 
44
44
  def scipy_bounds_list(obj: Objective) -> list[tuple[float, float]]:
45
45
  """Return bounds as ``[(lb0, ub0), ...]`` (format used by *dual_annealing*)."""
46
- lb = np.asarray(obj.problem.bounds[0], dtype=np.float64)
47
- ub = np.asarray(obj.problem.bounds[1], dtype=np.float64)
46
+ lb = np.asarray(obj.bounds[0], dtype=np.float64)
47
+ ub = np.asarray(obj.bounds[1], dtype=np.float64)
48
48
  return list(zip(lb.tolist(), ub.tolist()))
49
49
 
50
50
 
@@ -102,11 +102,10 @@ def _run_omads(
102
102
  """
103
103
  _check_omads_available()
104
104
 
105
- problem = obj.problem
106
- bounds = problem.bounds # (2, n_params)
105
+ bounds = obj.bounds # (2, n_params)
107
106
  lower = np.array(bounds[0], dtype=np.float64)
108
107
  upper = np.array(bounds[1], dtype=np.float64)
109
- n_params = problem.n_params
108
+ n_params = obj.n_params
110
109
 
111
110
  # Starting point: use best_params if available, else random bounded point
112
111
  if obj.best_params is not None:
@@ -1,14 +1,8 @@
1
1
  """LINCOA: LINearly Constrained Optimization Algorithm (via PDFO).
2
2
 
3
3
  LINCOA is a derivative-free trust-region method by M. J. D. Powell that
4
- handles *bound constraints* and *linear inequality constraints* natively.
5
-
6
- When the problem exposes only box bounds (the common case in this benchmark),
7
- LINCOA automatically uses them. If the problem also exposes linear
8
- constraints via ``problem.linear_constraints`` (returning a dict with keys
9
- ``A_ub``, ``b_ub`` for ``A_ub @ x <= b_ub``), those are forwarded to the
10
- solver as well. Problems without any constraints are also supported -
11
- LINCOA will behave like a bounded NEWUOA.
4
+ handles *bound constraints* natively. Problems without any constraints are
5
+ also supported - LINCOA will behave like a bounded NEWUOA.
12
6
 
13
7
  Defaults are conservative and benchmark-oriented: bounded physical space,
14
8
  one restart, ``rhobeg`` derived from the bound range.
@@ -76,7 +70,7 @@ class PDFOLINCOA(OptimizationAlgorithm):
76
70
  raise ImportError(
77
71
  "PDFO is required for LINCOA. Install with: uv add 'dfbench[dfo]'"
78
72
  ) from exc
79
- from scipy.optimize import LinearConstraint, Bounds # noqa: E402
73
+ from scipy.optimize import Bounds # noqa: E402
80
74
 
81
75
  obj = objective
82
76
  random_seed, key = self.prepare(obj, unbounded=False, random_seed=random_seed)
@@ -92,15 +86,9 @@ class PDFOLINCOA(OptimizationAlgorithm):
92
86
  fun = dfo_objective_wrapper(obj)
93
87
  bounds = Bounds(lb=lower, ub=upper)
94
88
 
95
- # Build constraint list: always include bounds; add linear if available.
89
+ # This batch only supports box bounds; problems with linear
90
+ # constraint metadata are not handled here.
96
91
  constraints: list = []
97
- problem = obj.problem
98
- if hasattr(problem, "linear_constraints"):
99
- lc = problem.linear_constraints # type: ignore[attr-defined]
100
- if lc is not None:
101
- A_ub = np.asarray(lc["A_ub"], dtype=np.float64)
102
- b_ub = np.asarray(lc["b_ub"], dtype=np.float64)
103
- constraints.append(LinearConstraint(A_ub, ub=b_ub))
104
92
 
105
93
  # JIT warmup
106
94
  obj.warmup_value()
@@ -106,14 +106,13 @@ class CMAESSepCMA(OptimizationAlgorithm):
106
106
  disables stagnation stopping.
107
107
  """
108
108
  obj = objective
109
- problem = obj.problem
110
109
 
111
110
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
112
111
 
113
- lb_np = np.asarray(problem.bounds[0])
114
- ub_np = np.asarray(problem.bounds[1])
112
+ lb_np = np.asarray(obj.bounds[0])
113
+ ub_np = np.asarray(obj.bounds[1])
115
114
  width = ub_np - lb_np
116
- n = problem.n_params
115
+ n = obj.n_params
117
116
 
118
117
  # The cmaes package has no per-coordinate sigma. On problems where
119
118
  # bound widths span orders of magnitude (e.g. Voyager), running the
@@ -198,15 +198,14 @@ class EvosaxMAES(OptimizationAlgorithm):
198
198
  max_iterations: Maximum CMA generations. ``None`` = unlimited.
199
199
  """
200
200
  obj = objective
201
- problem = obj.problem
202
201
 
203
202
  random_seed, rng = self.prepare(obj, unbounded=False, random_seed=random_seed)
204
203
 
205
- lb_np = np.asarray(problem.bounds[0])
206
- ub_np = np.asarray(problem.bounds[1])
204
+ lb_np = np.asarray(obj.bounds[0])
205
+ ub_np = np.asarray(obj.bounds[1])
207
206
  lb_jnp = jnp.asarray(lb_np)
208
207
  ub_jnp = jnp.asarray(ub_np)
209
- n = problem.n_params
208
+ n = obj.n_params
210
209
 
211
210
  sigma = float(sigma0 if sigma0 is not None else np.mean(0.3 * (ub_np - lb_np)))
212
211
 
@@ -307,15 +306,14 @@ class EvosaxLMMAES(OptimizationAlgorithm):
307
306
  max_iterations: Maximum generations. ``None`` = unlimited.
308
307
  """
309
308
  obj = objective
310
- problem = obj.problem
311
309
 
312
310
  random_seed, rng = self.prepare(obj, unbounded=False, random_seed=random_seed)
313
311
 
314
- lb_np = np.asarray(problem.bounds[0])
315
- ub_np = np.asarray(problem.bounds[1])
312
+ lb_np = np.asarray(obj.bounds[0])
313
+ ub_np = np.asarray(obj.bounds[1])
316
314
  lb_jnp = jnp.asarray(lb_np)
317
315
  ub_jnp = jnp.asarray(ub_np)
318
- n = problem.n_params
316
+ n = obj.n_params
319
317
 
320
318
  sigma = float(sigma0 if sigma0 is not None else np.mean(0.3 * (ub_np - lb_np)))
321
319
 
@@ -68,7 +68,7 @@ class EvoxES(OptimizationAlgorithm):
68
68
  _variant (str): ES variant name (e.g., "CMAES", "OpenES").
69
69
 
70
70
  Note:
71
- This algorithm uses `problem.objective_function` with the problem's bounds.
71
+ This algorithm uses the objective function with the problem's bounds.
72
72
  The population searches directly in the bounded parameter space.
73
73
 
74
74
  Example:
@@ -146,17 +146,11 @@ class EvoxES(OptimizationAlgorithm):
146
146
  **es_kwargs: Variant-specific keyword arguments passed to the EvoX algorithm.
147
147
  """
148
148
  obj = objective
149
- problem = obj.problem
150
149
 
151
150
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
152
151
  torch.manual_seed(random_seed)
153
152
 
154
- # Get bounds from problem
155
- if not hasattr(problem, "bounds"):
156
- raise ValueError(
157
- f"Problem {type(problem).__name__} must have a 'bounds' attribute."
158
- )
159
- problem_bounds = problem.bounds
153
+ problem_bounds = obj.bounds
160
154
  lb_np = np.asarray(problem_bounds[0])
161
155
  ub_np = np.asarray(problem_bounds[1])
162
156
 
@@ -210,7 +204,7 @@ class EvoxES(OptimizationAlgorithm):
210
204
 
211
205
  def get_center_init():
212
206
  return torch.from_numpy(
213
- np.random.uniform(lb_np, ub_np, size=problem.n_params)
207
+ np.random.uniform(lb_np, ub_np, size=obj.n_params)
214
208
  ).float()
215
209
 
216
210
  # Initialize based on variant-specific requirements
@@ -241,7 +235,7 @@ class EvoxES(OptimizationAlgorithm):
241
235
  if "init_mean" not in es_kwargs:
242
236
  es_kwargs["init_mean"] = get_center_init()
243
237
  if "init_covar" not in es_kwargs:
244
- es_kwargs["init_covar"] = torch.eye(problem.n_params).float() * (
238
+ es_kwargs["init_covar"] = torch.eye(obj.n_params).float() * (
245
239
  default_sigma**2
246
240
  )
247
241
  algorithm = AlgorithmClass(pop_size=pop_size, **es_kwargs)
@@ -250,9 +244,7 @@ class EvoxES(OptimizationAlgorithm):
250
244
  if "init_mean" not in es_kwargs:
251
245
  es_kwargs["init_mean"] = get_center_init()
252
246
  if "init_std" not in es_kwargs:
253
- es_kwargs["init_std"] = (
254
- torch.ones(problem.n_params).float() * default_sigma
255
- )
247
+ es_kwargs["init_std"] = torch.ones(obj.n_params).float() * default_sigma
256
248
  algorithm = AlgorithmClass(pop_size=pop_size, **es_kwargs)
257
249
 
258
250
  elif self._variant == "DES":
@@ -41,7 +41,7 @@ class EvoxPSO(OptimizationAlgorithm):
41
41
  _variant (str): PSO variant name (uppercase, e.g., "PSO", "CLPSO").
42
42
 
43
43
  Note:
44
- This algorithm uses `problem.objective_function` with the problem's bounds.
44
+ This algorithm uses the objective function with the problem's bounds.
45
45
  The swarm searches directly in the bounded parameter space.
46
46
 
47
47
  Example:
@@ -114,17 +114,11 @@ class EvoxPSO(OptimizationAlgorithm):
114
114
  **pso_kwargs: Variant-specific keyword arguments passed to the EvoX algorithm.
115
115
  """
116
116
  obj = objective
117
- problem = obj.problem
118
117
 
119
118
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
120
119
  torch.manual_seed(random_seed)
121
120
 
122
- # Get bounds from problem
123
- if not hasattr(problem, "bounds"):
124
- raise ValueError(
125
- f"Problem {type(problem).__name__} must have a 'bounds' attribute."
126
- )
127
- problem_bounds = problem.bounds
121
+ problem_bounds = obj.bounds
128
122
  lb = j2t(problem_bounds[0])
129
123
  ub = j2t(problem_bounds[1])
130
124
 
@@ -126,13 +126,12 @@ class JAXOnePlusOneES(OptimizationAlgorithm):
126
126
  means unlimited (budget governs stopping).
127
127
  """
128
128
  obj = objective
129
- problem = obj.problem
130
129
 
131
130
  random_seed, rng = self.prepare(obj, unbounded=False, random_seed=random_seed)
132
131
 
133
- lb = jnp.asarray(problem.bounds[0])
134
- ub = jnp.asarray(problem.bounds[1])
135
- n = problem.n_params
132
+ lb = jnp.asarray(obj.bounds[0])
133
+ ub = jnp.asarray(obj.bounds[1])
134
+ n = obj.n_params
136
135
 
137
136
  if init_params is None:
138
137
  rng, init_rng = jax.random.split(rng)
@@ -279,13 +278,12 @@ class JAXMuLambdaES(OptimizationAlgorithm):
279
278
  raise ValueError(f"(μ,λ)-ES requires mu < lam, got mu={mu}, lam={lam}.")
280
279
 
281
280
  obj = objective
282
- problem = obj.problem
283
281
 
284
282
  random_seed, rng = self.prepare(obj, unbounded=False, random_seed=random_seed)
285
283
 
286
- lb = jnp.asarray(problem.bounds[0])
287
- ub = jnp.asarray(problem.bounds[1])
288
- n = problem.n_params
284
+ lb = jnp.asarray(obj.bounds[0])
285
+ ub = jnp.asarray(obj.bounds[1])
286
+ n = obj.n_params
289
287
 
290
288
  if init_params is None:
291
289
  rng, init_rng = jax.random.split(rng)
@@ -64,17 +64,13 @@ class NevergradNGOpt(OptimizationAlgorithm):
64
64
  n_restarts: Number of independent restarts. Budget is split evenly.
65
65
  """
66
66
  obj = objective
67
- problem = obj.problem
68
67
 
69
68
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
70
69
 
71
- if not hasattr(problem, "bounds"):
72
- raise ValueError("NGOpt requires a bounded problem (problem.bounds).")
73
-
74
- bounds = problem.bounds
70
+ bounds = obj.bounds
75
71
  lb = np.asarray(bounds[0], dtype=np.float64)
76
72
  ub = np.asarray(bounds[1], dtype=np.float64)
77
- n_params = int(problem.n_params)
73
+ n_params = int(obj.n_params)
78
74
 
79
75
  budget_per_restart = max_iterations // n_restarts if max_iterations else None
80
76
 
@@ -64,17 +64,13 @@ class NevergradOnePlusOne(OptimizationAlgorithm):
64
64
  n_restarts: Number of independent restarts. Budget is split evenly.
65
65
  """
66
66
  obj = objective
67
- problem = obj.problem
68
67
 
69
68
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
70
69
 
71
- if not hasattr(problem, "bounds"):
72
- raise ValueError("OnePlusOne requires a bounded problem (problem.bounds).")
73
-
74
- bounds = problem.bounds
70
+ bounds = obj.bounds
75
71
  lb = np.asarray(bounds[0], dtype=np.float64)
76
72
  ub = np.asarray(bounds[1], dtype=np.float64)
77
- n_params = int(problem.n_params)
73
+ n_params = int(obj.n_params)
78
74
 
79
75
  # Budget per restart
80
76
  budget_per_restart = max_iterations // n_restarts if max_iterations else None
@@ -73,17 +73,13 @@ class NevergradTBPSA(OptimizationAlgorithm):
73
73
  counts against the Objective budget. Set >1 for noisy problems.
74
74
  """
75
75
  obj = objective
76
- problem = obj.problem
77
76
 
78
77
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
79
78
 
80
- if not hasattr(problem, "bounds"):
81
- raise ValueError("TBPSA requires a bounded problem (problem.bounds).")
82
-
83
- bounds = problem.bounds
79
+ bounds = obj.bounds
84
80
  lb = np.asarray(bounds[0], dtype=np.float64)
85
81
  ub = np.asarray(bounds[1], dtype=np.float64)
86
- n_params = int(problem.n_params)
82
+ n_params = int(obj.n_params)
87
83
 
88
84
  budget_per_restart = max_iterations // n_restarts if max_iterations else None
89
85
 
@@ -208,14 +208,13 @@ class PyCMACMAES(OptimizationAlgorithm):
208
208
  means unlimited (budget and convergence govern stopping).
209
209
  """
210
210
  obj = objective
211
- problem = obj.problem
212
211
 
213
212
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
214
213
 
215
- lb_np = np.asarray(problem.bounds[0])
216
- ub_np = np.asarray(problem.bounds[1])
214
+ lb_np = np.asarray(obj.bounds[0])
215
+ ub_np = np.asarray(obj.bounds[1])
217
216
  width = ub_np - lb_np
218
- n = problem.n_params
217
+ n = obj.n_params
219
218
 
220
219
  # Build the initial mean in unit-cube coordinates.
221
220
  if init_params is None:
@@ -304,14 +303,13 @@ class PyCMAActiveCMAES(OptimizationAlgorithm):
304
303
  max_iterations: Maximum CMA generations. ``None`` = unlimited.
305
304
  """
306
305
  obj = objective
307
- problem = obj.problem
308
306
 
309
307
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
310
308
 
311
- lb_np = np.asarray(problem.bounds[0])
312
- ub_np = np.asarray(problem.bounds[1])
309
+ lb_np = np.asarray(obj.bounds[0])
310
+ ub_np = np.asarray(obj.bounds[1])
313
311
  width = ub_np - lb_np
314
- n = problem.n_params
312
+ n = obj.n_params
315
313
 
316
314
  # Build the initial mean in unit-cube coordinates.
317
315
  if init_params is None:
@@ -406,14 +404,13 @@ class PyCMAIPOP(OptimizationAlgorithm):
406
404
  (independent of the overall budget). ``None`` = unlimited.
407
405
  """
408
406
  obj = objective
409
- problem = obj.problem
410
407
 
411
408
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
412
409
 
413
- lb_np = np.asarray(problem.bounds[0])
414
- ub_np = np.asarray(problem.bounds[1])
410
+ lb_np = np.asarray(obj.bounds[0])
411
+ ub_np = np.asarray(obj.bounds[1])
415
412
  width = ub_np - lb_np
416
- n = problem.n_params
413
+ n = obj.n_params
417
414
 
418
415
  base_pop = pop_size or _default_pop_size(n)
419
416
  # sigma is a dimensionless fraction of the unit cube.
@@ -521,14 +518,13 @@ class PyCMABIPOP(OptimizationAlgorithm):
521
518
  ``None`` = unlimited.
522
519
  """
523
520
  obj = objective
524
- problem = obj.problem
525
521
 
526
522
  random_seed, _ = self.prepare(obj, unbounded=False, random_seed=random_seed)
527
523
 
528
- lb_np = np.asarray(problem.bounds[0])
529
- ub_np = np.asarray(problem.bounds[1])
524
+ lb_np = np.asarray(obj.bounds[0])
525
+ ub_np = np.asarray(obj.bounds[1])
530
526
  width = ub_np - lb_np
531
- n = problem.n_params
527
+ n = obj.n_params
532
528
 
533
529
  base_pop = pop_size or _default_pop_size(n)
534
530
  # sigma is a dimensionless fraction of the unit cube.