This is a patch release with optimizations and bug fixes.
uv
to speed up the installation process.This is a patch release with optimizations and bug fixes.
Study.add_many()
: The time required to register many data points at once is significantly reduced by caching.bokeh
package updated. This adds a context menu for interactions with figures. avg
property parameter of the surrogate, which is not normalized or warped.ActiveLearning
Driver: In some cases the trained neural network was influenced by an update of the minimum and maximum of the training data, which is used to normalize the training data. This could lead to prediction errors. Now the minimum and maximum used for the normalization is frozen after training.This is a minor update release. It introduces features that enable the training of neural network surrogates to be more robust. Furthermore, the state of a surrogate (e.g. the trained weights of a network) is now saved between runs of a study.
{save_dir}/{study_id}.jcmb
.train_mean_grad=False
now enables each ensemble member to be trained to match the exact gradient. However, this will lead to much longer computation times for large ensembles.study.add_many()
function, has now been increased to 1024 MB. Previously, the limit was 100 MB.ActiveLearning
Driver: The state of the driver hyperparameters was not saved correctly after the user initiated hyperparameter optimisation using the study.driver.optimize_hyperparameters()
function.study.get_observation_data()
did not work correctly for vectorial observations.This is a patch release that fixes some issues of the installer. The fix introduced in v2.0.2 to use certificate authority files from the default system store lead to problems for some environments.
This is a patch release that fixes some issues of the ActiveLearning
driver and the installer.
ActiveLearning
driver: Fit
variable introduces prior uncertainties of fit parameters for better numerical stability of the fit result.ActiveLearning
driver: LinearCombination
variable was not working for a combination of single-input posteriors.ActiveLearning
driver: Variables that are not used in any objectives could have wrong number of Monte-Carlo samples.ActiveLearning
driver: study.driver.get_minima()
was not working for 1D minimization problems.This is a patch release that fixes some issues of the ScipyMinimizer
and the BayesianReconstruction
driver.
ScipyMinimizer
driver with method Nelder-Mead
: The continuation of a previous study determined a new simplex at the latest sample. Now the simplex is reconstructed from the previous study run leading to a better continuation.BayesianReconstruction
driver: The sampling strategy was not taking prior information fully into account. This has been fixed.This is a patch release that fixes some issues with hyperparameter optimization, state retrieval and installation in environment with proxy servers.
study.get_state(path)
with a partial path (e.g. path='suggestion'
) failed.This patch release improves the compatibility of the installer and the installation for different environments.
.condarc
file.
Now it forces to use conda-forge
channel to install python packages.requests
package for downloading micromamba.This is the first release of the standalone JCMoptimizer. It is a major upgrade of the optimizer previously shipped with JCMsuite based one a new implementation. Scripts using the old JCMsuite optimizer have to be adapted.
ActiveLearning
. The driver defines a general active learning process
that can be configured for many different purposes such as optimization,
multi-objective optimization, integration or learning of the behavior of one or
more expensive black box functions.BayesianReconstruction
. This is an extension of the
BayesianLeastSquares
driver used to fit model parameters. The new driver allows
to maximize the full posterior probability including an error model and a prior
distribution for all parameters.Neural Network Ensemble
that uses an ensemble of neural
networks to predict posterior distributions.To create a client instance, use the interface of the new optimizer. For example, in Python use
from jcmoptimizer import Server, Client, Study, Observation
server = Server()
client = Client(server.host)
The arguments for creating a new Study
instance have changed. For example, the
domain
argument is now called design_space
in order to distinguish it from
parameters belonging to the environment
:
# Definition of the search domain
design_space = [
{'name': 'x1', 'type': 'continuous', 'domain': (-1.5,1.5)},
{'name': 'x2', 'type': 'continuous', 'domain': (-1.5,1.5)},
]
# Definition of fixed environment parameter
environment = [
{'name': 'radius', 'type': 'fixed', 'domain': 1.5},
]
# Definition of a constraint on the search domain
constraints = [
{'name': 'circle', 'expression': 'sqrt(x1^2 + x2^2) <= radius'}
]
# Creation of the study object with study_id 'vanilla_bayesian_optimization'
study = client.create_study(
design_space=design_space,
environment=environment,
constraints=constraints,
driver="BayesianOptimization",
name="Standard Bayesian optimization",
study_id="vanilla_bayesian_optimization"
)
The objective
function is replaced by an evaluator
function in order to clarify that the output does not need to be the objective value itself but also physical outputs that can be mapped to the final objective.
# Evaluation of the black-box function for specified design parameters
def evaluate(study: Study, x1: float, x2: float, radius: float) -> Observation:
time.sleep(2) # make objective expensive
observation = study.new_observation()
observation.add(10*2
+ (x1**2-10*np.cos(2*np.pi*x1))
+ (x2**2-10*np.cos(2*np.pi*x2))
)
return observation
# Run the minimization
study.set_evaluator(evaluate)
study.run()
The method study.set_parameters()
is replaced by the method study.configure()
.
Many methods of the Study
instance are replaced by other methods with different arguments and output. For example
study.info()
: The new method study.get_state()
outputs the state of the Study as a nested dictionary.study.driver_info()
: The new method study.driver.get_state()
outputs the state of the study driver as a nested dictionary.study.get_data_table()
: The new method study.get_observation_data()
outputs all data of observations added to the study.study.get_minima()
: The method is now part of the driver
interface, study.driver.get_mimima()
.study.get_statistics()
: The method is now part of the driver
interface, study.driver.get_statistics()
.study.optimize_hyperparameters()
: The method is now part of the driver
interface, study.driver.optimize_hyperparameter()
.study.predict()
: The method is now part of the driver
interface, study.driver.predict()
.study.run_mcmc()
: The method is now part of the driver
interface, study.driver.run_mcmc()
.Please consult the documentation for the description of the arguments and outputs of the new methods.