Releases: ICB-DCM/pyscat
Releases · ICB-DCM/pyscat
Release list
PyScat v0.1.0
What's Changed
Breaking changes
- Changed
SacessOptimizerresults, disable autosave by @dweindl in #51 and #56- Intermediate results are only saved to file if explicitly requested.
- The
tmpdirargument has been replaced byautosave_dir. - The
SacessOptimizer.minimizeresult no longer contains all local optimization results. They can be recovered from the autosave files if required and if enabled.
- The
SacessOptimizer.minimizeresult contains one singleOptimizerResultrepresenting the best point found across all workers. Its.historycontains the monotonic history of the globally best point. - Don't store an
OptimizerResultfor every iteration by @dweindl in #47
The same information is available from the history stored in the result - Refactor/move
.plot.monotonic_history->.utils.merge_monotonic_historiesby @dweindl in #50 and #55
Features
- Apply resource limits to local optimizer if supported by @dweindl in #38
- Lift numpy requirement to >=2.0 by @dweindl in #37
- Optional inclusion of local solutions in
ESSOptimizer.minimizeresult by @dweindl in #44 - Allow passing custom history instance to
ESSOptimizer.minimizeby @dweindl in #46 - Set
.historyonESSOptimizer OptimizerResultby @dweindl in #49
Fixes
- Fix n_eval-criterion for worker adaptation by @dweindl in #42
- Fix lagging best known solution in ESSOptimizer after cooperation step by @dweindl in #53
- Fix
monotonic_historyfor empty histories by @dweindl in #30 - Refuse Problem with
x_guessesby @dweindl in #34 - Better adherence to the walltime limit by
SacessOptimizer, in particular in the cases of low limits by @dweindl in #35 - Don't create
outcmaesdirectory inSacessCmaFactoryby @dweindl in #48 - Include worker index in
WorkerResult, sortSacessOptimizer.worker_resultsby @dweindl in #54 - Prevent infinite loop in
ESSOptimizerin case of permanent objective failures by @dweindl in #57
Full Changelog: v0.0.1.post1...v0.1.0
PyScat v0.0.1.post1
Immutable
release. Only release title and notes can be modified.
PyScat started from the scatter search implementation included in pyPESTO 0.5.7.
Most relevant changes since pyPESTO 0.5.7
- The deprecated
startpoint_methodhas been removed fromSacessOptimizer.minimizeandESSOptimizer.minimize.Problem.startpoint_methodis now used instead. - Fixed a bug in counting of function evaluations that led to double counting of some function evaluations in eSS and saCeSS optimizers, potentially resulting in premature termination if a function evaluation budget was set.
- Fixed a bug in the ranking of candidates for local optimization startpoints in eSS and saCeSS optimizers.
- Updated/extended documentation and examples.
- Initialization of
SacessOptimizeris now problem-dependent, i.e., aProbleminstance has to be provided at initialization instead of atminimizetime. This simplifies changing local optimizers;SacessOptimizer.set_local_optimizerwas added. - If the provided objective function does not provide gradient information, no local optimizer is used by default. This may change in future (minor) releases.
- Added experimental functionality to record all function evaluations during optimization, or the k-best ones, or those below a certain threshold based on the best objective function value found so far. This is intended to construct parameter ensembles for uncertainty quantification. See example in the documentation.
Migrating from SacessOptimizer in pyPESTO 0.5.7 to PyScat 0.0.1
Old pyPESTO 0.5.7 code:
from pypesto import Problem
from pypesto.optimize import SacessOptimizer
from pypesto.optimize.ess import get_default_ess_options
problem = Problem(...) # define your problem here
ess_init_args = get_default_ess_options(
num_workers=12,
dim=problem.dim,
local_optimizer=False,
)
optimizer = SacessOptimizer(
ess_init_args=ess_init_args,
max_walltime_s=5,
sacess_loglevel=logging.WARNING
)
result = optimizer.minimize(problem)New PyScat 0.0.1 code:
from pypesto import Problem
from pyscat import SacessOptimizer
problem = Problem(...) # define your problem here
optimizer = SacessOptimizer(
problem=problem,
num_workers=12,
max_walltime_s=5,
sacess_loglevel=logging.WARNING
)
optimizer.set_local_optimizer(None)
result = optimizer.minimize()Full Changelog: https://github.com/ICB-DCM/pyscat/commits/v0.0.1.post1
PyScat v0.0.1
PyScat started from the scatter search implementation included in pyPESTO 0.5.7.
Most relevant changes since pyPESTO 0.5.7
- The deprecated
startpoint_methodhas been removed fromSacessOptimizer.minimizeandESSOptimizer.minimize.Problem.startpoint_methodis now used instead. - Fixed a bug in counting of function evaluations that led to double counting of some function evaluations in eSS and saCeSS optimizers, potentially resulting in premature termination if a function evaluation budget was set.
- Fixed a bug in the ranking of candidates for local optimization startpoints in eSS and saCeSS optimizers.
- Updated/extended documentation and examples.
- Initialization of
SacessOptimizeris now problem-dependent, i.e., aProbleminstance has to be provided at initialization instead of atminimizetime. This simplifies changing local optimizers;SacessOptimizer.set_local_optimizerwas added. - If the provided objective function does not provide gradient information, no local optimizer is used by default. This may change in future (minor) releases.
- Added experimental functionality to record all function evaluations during optimization, or the k-best ones, or those below a certain threshold based on the best objective function value found so far. This is intended to construct parameter ensembles for uncertainty quantification. See example in the documentation.
Migrating from SacessOptimizer in pyPESTO 0.5.7 to PyScat 0.0.1
Old pyPESTO 0.5.7 code:
from pypesto.optimize import SacessOptimizer
from pypesto.optimize.ess import get_default_ess_options
problem = Problem(...) # define your problem here
ess_init_args = get_default_ess_options(
num_workers=12,
dim=problem.dim,
local_optimizer=False,
)
optimizer = SacessOptimizer(
ess_init_args=ess_init_args,
max_walltime_s=5,
sacess_loglevel=logging.WARNING
)
result = optimizer.minimize(problem)New PyScat 0.0.1 code:
from pyscat import SacessOptimizer
problem = Problem(...) # define your problem here
optimizer = SacessOptimizer(
problem=problem,
num_workers=12,
max_walltime_s=5,
sacess_loglevel=logging.WARNING
)
optimizer.set_local_optimizer(None)
result = optimizer.minimize()
Full Changelog: https://github.com/ICB-DCM/pyscat/commits/v0.0.1