raven icon indicating copy to clipboard operation
raven copied to clipboard

[UNDER-DISCUSSION] Bayesian Optimization

Open PaulTalbot-INL opened this issue 3 years ago • 3 comments


Under Discussion Topic

Summary of the topic to be discussed with the development team In literature when talking about efficient global optimization of black-box problems, bayesian optimization comes up frequently.

Describe the solution you'd like to be implemented We could implement bayesian optimization in RAVEN in a fairly straightforward way based on the RavenSampled optimization base class.

As I understand it, in Bayesian optimization we approximate the response as a Gaussian process, which has a trivial expression for its optimal point and uncertainty of that optimal point. We then use information theory to sample additional points in the output space, which resolves the ROM and reduces the uncertainty around the optimal point. At a particular confidence of the optimal location, convergence can be declared.


For Change Control Board: Issue Review

This review should occur before any development is performed as a response to this issue.

  • [ ] 1. Is it tagged with the under_discussion type?
  • [ ] 2. If implemented, it will add a new requirement?
  • [ ] 3. Is a rationale provided? (Such as explaining why the improvement is needed )

For Change Control Board: Issue Closure

This review should occur when the issue is imminently going to be closed.

  • [ ] 1. The discussion determined the addition of a new task issue?

PaulTalbot-INL avatar Jul 27 '22 18:07 PaulTalbot-INL

scikit-optimize will do Bayesian optimization, see this example:

https://scikit-optimize.github.io/stable/auto_examples/bayesian-optimization.html

Here is a simplistic tutorial on how to implement Bayesian optimization from scratch:

https://machinelearningmastery.com/what-is-bayesian-optimization/

dgarrett622 avatar Aug 30 '22 21:08 dgarrett622

It's possible we could directly use optimization such as scipy and scikitlearn offer and still use the sampling, code interfaces, and job distribution in RAVEN; I think Andrea looked at this early in optimization development and decided against it. Maybe we should revisit that?

PaulTalbot-INL avatar Aug 30 '22 21:08 PaulTalbot-INL

Just to clarify my "old position", the reason why it was not very "easy" and it was "decided against it" is that scipy, Pyomo, and also scikit-optimize require to act as "Driver" of the optimization problem, exposing and explicitly embedding the objective function in their optimization search. In RAVEN, the Sampler and Optimizers are "services" as part of the workflow and are designed to be used as part of a workflow (where the different functions of the search are modularized in the different modules (E.g. job handler, model interface, etc.).

The work that I have done (and finalized by Ramon) for Pyomo grey opt and Surrogate Models go in the direction of facilitating the usage of such tools. That can be generalized for other models too (e.g. Codes) but, without challenging tricks, you would loose the ability to execute codes in parallel (for the model), interact with clusters, etc.

aalfonsi avatar Sep 15 '22 15:09 aalfonsi

BayesianOpt has been added into raven, this issue can be closed.

wangcj05 avatar Feb 19 '24 17:02 wangcj05