faropt.templates package¶
Submodules¶
faropt.templates.blackbox module¶
-
class
faropt.templates.blackbox.
AsyncOpt
(stackname='faropt')¶ Bases:
object
AsyncOpt class for typical black-box optimizattion problems where the function evaluation is slow. Take for example an engine simulation - each simulation may take an hour, and you don’t want to make the optimizer wait for an update. This class implements a serverless ask- and tell-optimizer interface to ask an optimizer for the next point to evaluate the function at, based on expected improvement (Bayesian opt), and users can tell the optimizer the results of an optimization to update the response surface
-
ask_model
(modelname='')¶ asks the model for a new point to evaluate at, based on expected improvement
- Parameters
modelname (string, opional) – UUID of the model
-
create_model
(bounds, modeltag='')¶ Updates the model by pickling and uploading (overwriting) the opt model to a special async bucket generated by the stack
- Parameters
bounds (list of tuples, like [(-1.0,1.0),(-5,5),(-10.5,10.5)..]) – UUID of the model
modeltag (string, optional) – Friendly name of the optimizer
-
list_models
()¶ Prints a list of all models created so faar with UUID and modeltags
-
tell_model
(xval, fval, modelname='')¶ tells the model what the fuction value was for a new point (xval). The model’s response surface is then updated based on this information
- Parameters
xval (list) – Point that was evaluated, like [0,0], that is within the bounds set in create_model
fval (float) – function value measured at xval
modelname (string, opional) – UUID of the model
-
update_model
(modelname, opt)¶ Updates the model by pickling and uploading (overwriting) the opt model to a special async bucket generated by the stack
- Parameters
modelname (string) – UUID of the model
opt (scikit-opt) – object containing params of the optimizer
-
faropt.templates.opsplan module¶
-
class
faropt.templates.opsplan.
OpsPlanOpt
(stackname='faropt')¶ Bases:
object
faropt.templates.routing module¶
-
class
faropt.templates.routing.
RoutingOpt
(stackname='faropt')¶ Bases:
object