For Multi-objective optimization (MOO) in the
AxClient, objectives are specified through the
ObjectiveProperties dataclass. An
ObjectiveProperties requires a boolean
minimize, and also accepts an optional floating point
threshold. If a
threshold is not specified, Ax will infer it through the use of heuristics. If the user knows the region of interest (because they have specs or prior knowledge), then specifying the thresholds is preferable to inferring it. But if the user would need to guess, inferring is preferable.
To learn more about how to choose a threshold, see Set Objective Thresholds to focus candidate generation in a region of interest. See the Service API Tutorial for more infomation on running experiments with the Service API.
from ax.service.ax_client import AxClient from ax.service.utils.instantiation import ObjectiveProperties import torch # Plotting imports and initialization from ax.utils.notebook.plotting import render, init_notebook_plotting from ax.plot.pareto_utils import compute_posterior_pareto_frontier from ax.plot.pareto_frontier import plot_pareto_frontier init_notebook_plotting() # Load our sample 2-objective problem from botorch.test_functions.multi_objective import BraninCurrin branin_currin = BraninCurrin(negate=True).to( dtype=torch.double, device= torch.device("cuda" if torch.cuda.is_available() else "cpu"), )
[INFO 12-29 21:56:58] ax.utils.notebook.plotting: Injecting Plotly library into cell. Do not overwrite or delete cell.