R Branin¶
This notebook is an example of a single objective R model optimization using a branin synthetic function.
See the folder r_branin for the R script and the configuration file.
1# This notebook uses hidden cells to import and display things so
2# that it can be ran regullary to make sure the documentation
3# is up to date and not broken (as opposed to a markdown file
4# that would have an exmaple written once and get out of date
5# as the code base changes)
6
7# These hidden cells are only responsible for rerunning
8# the documentation to ensure it is correct.
9# the actual relavent part of the documentation
10# are the non hidden parts
Configuration File¶
config.yaml
objective:
metrics:
# List all of your metrics
- metric: branin
metric_type: synthetic_metric
minimize: true
# List all parameters
parameters:
x0:
type: range
bounds: [-5, 10]
value_type: float
x1:
type: range
bounds: [0, 15]
value_type: float
# number of trials and other general run settings
n_trials: 50
scheduler:
# Optional, this stops the optimization early if we converge to the specified condition
global_stopping_strategy:
type: improvement
min_trials: 10
window_size: 10
# (This is the default) 10% improvement as a fraction of the
# interquartile range (IQR) of the objective values seen so far.
improvement_bar: 0.1
# Which script to run and what to write files out as
script_options:
run_model: Rscript run_model.R
Run Model Wrapper Script¶
run_model.R
library(jsonlite)
trial_dir <- commandArgs(trailingOnly=TRUE)[1]
data <- read_json(path=file.path(trial_dir, "parameters.json"))
write(toJSON(list(branin=data), auto_unbox=TRUE), file.path(trial_dir, "output.json"))
Running our script¶
To run our script we just need to path the config file to BOA’s CLI
python -m boa --config-file path/to/config.yaml
or
python -m boa -c path/to/config.yaml
[WARNING 07-18 23:47:49] ax.service.utils.with_db_settings_base: Ax currently requires a sqlalchemy version below 2.0. This will be addressed in a future release. Disabling SQL storage in Ax for now, if you would like to use SQL storage please install Ax with mysql extras via `pip install ax-platform[mysql]`.
[INFO 07-18 23:47:50] ax.service.utils.instantiation: Created search space: SearchSpace(parameters=[RangeParameter(name='x0', parameter_type=FLOAT, range=[-5.0, 10.0]), RangeParameter(name='x1', parameter_type=FLOAT, range=[0.0, 15.0])], parameter_constraints=[]).
[INFO 07-18 23:47:50] ax.modelbridge.dispatch_utils: Using Models.BOTORCH_MODULAR since there are more ordered parameters than there are categories for the unordered categorical parameters.
[INFO 07-18 23:47:50] ax.modelbridge.dispatch_utils: Calculating the number of remaining initialization trials based on num_initialization_trials=None max_initialization_trials=None num_tunable_parameters=2 num_trials=None use_batch_trials=False
[INFO 07-18 23:47:50] ax.modelbridge.dispatch_utils: calculated num_initialization_trials=5
[INFO 07-18 23:47:50] ax.modelbridge.dispatch_utils: num_completed_initialization_trials=0 num_remaining_initialization_trials=5
[INFO 07-18 23:47:50] ax.modelbridge.dispatch_utils: `verbose`, `disable_progbar`, and `jit_compile` are not yet supported when using `choose_generation_strategy` with ModularBoTorchModel, dropping these arguments.
[INFO 07-18 23:47:50] ax.modelbridge.dispatch_utils: Using Bayesian Optimization generation strategy: GenerationStrategy(name='Sobol+BoTorch', steps=[Sobol for 5 trials, BoTorch for subsequent trials]). Iterations after 5 will take longer to generate due to model-fitting.
[INFO 07-18 23:47:50] Scheduler: `Scheduler` requires experiment to have immutable search space and optimization config. Setting property immutable_search_space_and_opt_config to `True` on experiment.
[INFO 2024-07-18 23:47:50,840 MainProcess MainThread {controller.py:165}] boa:
##############################################
BOA Experiment Run
Output Experiment Dir: [/path/to/your/dir/]/boa_runs_20240718T234750
Scheduler File Path: [/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json
Optimization CSV File Path: [/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv
Start Time: 20240718T234750
Version: 0.10.3
##############################################
[INFO 07-18 23:47:50] Scheduler: Running trials [0]...
[INFO 2024-07-18 23:47:50,852 MainProcess ThreadPoolExecutor-0_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:47:50,853 MainProcess ThreadPoolExecutor-0_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 1.5788793563842773, 'x1': 8.985225856304169, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000000')}
[INFO 2024-07-18 23:47:50,853 MainProcess ThreadPoolExecutor-0_0 {script_wrapper.py:330}] boa: Rscript run_model.R
[INFO 07-18 23:47:51] Scheduler: Running trials [1]...
[INFO 2024-07-18 23:47:51,867 MainProcess ThreadPoolExecutor-1_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:47:51,868 MainProcess ThreadPoolExecutor-1_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 8.814644105732441, 'x1': 4.073206870816648, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000001')}
[INFO 2024-07-18 23:47:51,869 MainProcess ThreadPoolExecutor-1_0 {script_wrapper.py:330}] boa: Rscript run_model.R
[INFO 07-18 23:47:52] Scheduler: Running trials [2]...
[INFO 2024-07-18 23:47:52,883 MainProcess ThreadPoolExecutor-2_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:47:52,884 MainProcess ThreadPoolExecutor-2_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 3.4726123232394457, 'x1': 12.09993809927255, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000002')}
[INFO 2024-07-18 23:47:52,886 MainProcess ThreadPoolExecutor-2_0 {script_wrapper.py:330}] boa: Rscript run_model.R
[INFO 07-18 23:47:53] Scheduler: Running trials [3]...
[INFO 2024-07-18 23:47:53,900 MainProcess ThreadPoolExecutor-3_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:47:53,901 MainProcess ThreadPoolExecutor-3_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 3.205355843529105, 'x1': 9.315822101198137, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000003')}
[INFO 2024-07-18 23:47:53,903 MainProcess ThreadPoolExecutor-3_0 {script_wrapper.py:330}] boa: Rscript run_model.R
[INFO 07-18 23:47:54] Scheduler: Running trials [4]...
[INFO 2024-07-18 23:47:54,918 MainProcess ThreadPoolExecutor-4_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:47:54,919 MainProcess ThreadPoolExecutor-4_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': -3.796725608408451, 'x1': 8.979918966069818, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000004')}
[INFO 2024-07-18 23:47:54,920 MainProcess ThreadPoolExecutor-4_0 {script_wrapper.py:330}] boa: Rscript run_model.R
[INFO 07-18 23:47:55] Scheduler: Generated all trials that can be generated currently. Model requires more data to generate more trials.
[INFO 07-18 23:47:55] Scheduler: Retrieved COMPLETED trials: 0 - 4.
[INFO 07-18 23:47:55] Scheduler: Fetching data for trials: 0 - 4.
[WARNING 07-18 23:47:55] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:47:55,989 MainProcess MainThread {storage.py:303}] boa: Saved optimization parametrization and objective to `[/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv`.
[INFO 2024-07-18 23:47:56,004 MainProcess MainThread {storage.py:63}] boa: Saved JSON-serialized state of optimization to `[/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json`.
Boa version: 0.10.3
[INFO 2024-07-18 23:47:56,016 MainProcess MainThread {scheduler.py:86}] boa: Trials so far: 5
Currently running trials: []
Will Produce next trials from generation step: Sobol
Best trial so far: {1: {'branin': 6.394027291381608}}
[INFO 07-18 23:47:57] Scheduler: Running trials [5]...
[INFO 2024-07-18 23:47:57,154 MainProcess ThreadPoolExecutor-5_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:47:57,155 MainProcess ThreadPoolExecutor-5_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 1.2871741839061874, 'x1': 3.6655684178228043, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000005')}
[INFO 2024-07-18 23:47:57,156 MainProcess ThreadPoolExecutor-5_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:47:58] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:47:58] Scheduler: Running trials [6]...
[INFO 2024-07-18 23:47:58,861 MainProcess ThreadPoolExecutor-6_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:47:58,862 MainProcess ThreadPoolExecutor-6_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 10.0, 'x1': 0.2447609333590041, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000006')}
[INFO 2024-07-18 23:47:58,864 MainProcess ThreadPoolExecutor-6_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:47:59] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:00] Scheduler: Running trials [7]...
[INFO 2024-07-18 23:48:00,722 MainProcess ThreadPoolExecutor-7_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:00,724 MainProcess ThreadPoolExecutor-7_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': -5.0, 'x1': 0.0, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000007')}
[INFO 2024-07-18 23:48:00,725 MainProcess ThreadPoolExecutor-7_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:01] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:01] Scheduler: Generated all trials that can be generated currently. Max parallelism currently reached.
[INFO 07-18 23:48:01] Scheduler: Retrieved COMPLETED trials: 5 - 7.
[INFO 07-18 23:48:01] Scheduler: Fetching data for trials: 5 - 7.
[WARNING 07-18 23:48:01] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:48:01,789 MainProcess MainThread {storage.py:303}] boa: Saved optimization parametrization and objective to `[/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv`.
[INFO 2024-07-18 23:48:01,808 MainProcess MainThread {storage.py:63}] boa: Saved JSON-serialized state of optimization to `[/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json`.
Boa version: 0.10.3
[INFO 2024-07-18 23:48:01,821 MainProcess MainThread {scheduler.py:86}] boa: Trials so far: 8
Currently running trials: []
Will Produce next trials from generation step: BoTorch
Best trial so far: {1: {'branin': 6.394027291381608}}
[INFO 07-18 23:48:02] Scheduler: Running trials [8]...
[INFO 2024-07-18 23:48:02,373 MainProcess ThreadPoolExecutor-8_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:02,375 MainProcess ThreadPoolExecutor-8_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 4.996834809459299, 'x1': 3.7144119575337724, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000008')}
[INFO 2024-07-18 23:48:02,376 MainProcess ThreadPoolExecutor-8_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:03] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:03] Scheduler: Running trials [9]...
[INFO 2024-07-18 23:48:03,999 MainProcess ThreadPoolExecutor-9_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:04,001 MainProcess ThreadPoolExecutor-9_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 1.7520677444543722, 'x1': 5.736758680843402, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000009')}
[INFO 2024-07-18 23:48:04,003 MainProcess ThreadPoolExecutor-9_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:04] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:04] Scheduler: Running trials [10]...
[INFO 2024-07-18 23:48:05,002 MainProcess ThreadPoolExecutor-10_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:05,005 MainProcess ThreadPoolExecutor-10_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 5.863527329417119, 'x1': 1.2355526603968956, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000010')}
[INFO 2024-07-18 23:48:05,007 MainProcess ThreadPoolExecutor-10_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:05] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:05] Scheduler: Generated all trials that can be generated currently. Max parallelism currently reached.
[INFO 07-18 23:48:05] Scheduler: Retrieved COMPLETED trials: 8 - 9.
[INFO 07-18 23:48:05] Scheduler: Fetching data for trials: 8 - 9.
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[WARNING 07-18 23:48:05] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:48:05,097 MainProcess MainThread {storage.py:303}] boa: Saved optimization parametrization and objective to `[/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv`.
[INFO 2024-07-18 23:48:05,138 MainProcess MainThread {storage.py:63}] boa: Saved JSON-serialized state of optimization to `[/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json`.
Boa version: 0.10.3
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 2024-07-18 23:48:05,166 MainProcess MainThread {scheduler.py:86}] boa: Trials so far: 11
Currently running trials: 10
Will Produce next trials from generation step: BoTorch
Best trial so far: {1: {'branin': 6.394027291381608}}
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:05] Scheduler: Running trials [11]...
[INFO 2024-07-18 23:48:05,970 MainProcess ThreadPoolExecutor-11_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:05,972 MainProcess ThreadPoolExecutor-11_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 10.0, 'x1': 2.7542922690116933, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000011')}
[INFO 2024-07-18 23:48:05,974 MainProcess ThreadPoolExecutor-11_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:06] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:07] Scheduler: Running trials [12]...
[INFO 2024-07-18 23:48:07,907 MainProcess ThreadPoolExecutor-12_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:07,909 MainProcess ThreadPoolExecutor-12_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 10.0, 'x1': 5.8954311491718485, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000012')}
[INFO 2024-07-18 23:48:07,912 MainProcess ThreadPoolExecutor-12_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:08] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:08] Scheduler: Generated all trials that can be generated currently. Max parallelism currently reached.
[INFO 07-18 23:48:08] Scheduler: Retrieved COMPLETED trials: 10 - 12.
[INFO 07-18 23:48:08] Scheduler: Fetching data for trials: 10 - 12.
[WARNING 07-18 23:48:08] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:48:08,981 MainProcess MainThread {storage.py:303}] boa: Saved optimization parametrization and objective to `[/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv`.
[INFO 2024-07-18 23:48:09,009 MainProcess MainThread {storage.py:63}] boa: Saved JSON-serialized state of optimization to `[/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json`.
Boa version: 0.10.3
[INFO 2024-07-18 23:48:09,025 MainProcess MainThread {scheduler.py:86}] boa: Trials so far: 13
Currently running trials: []
Will Produce next trials from generation step: BoTorch
Best trial so far: {11: {'branin': 2.0049707701997885}}
[INFO 07-18 23:48:09] Scheduler: Running trials [13]...
[INFO 2024-07-18 23:48:09,723 MainProcess ThreadPoolExecutor-13_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:09,725 MainProcess ThreadPoolExecutor-13_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 10.0, 'x1': 3.5418230468008502, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000013')}
[INFO 2024-07-18 23:48:09,727 MainProcess ThreadPoolExecutor-13_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:10] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:11] Scheduler: Running trials [14]...
[INFO 2024-07-18 23:48:11,358 MainProcess ThreadPoolExecutor-14_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:11,360 MainProcess ThreadPoolExecutor-14_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': -5.0, 'x1': 15.0, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000014')}
[INFO 2024-07-18 23:48:11,362 MainProcess ThreadPoolExecutor-14_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:12] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:13] Scheduler: Running trials [15]...
[INFO 2024-07-18 23:48:13,400 MainProcess ThreadPoolExecutor-15_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:13,403 MainProcess ThreadPoolExecutor-15_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': -1.106898939747162, 'x1': 5.7479302052049075, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000015')}
[INFO 2024-07-18 23:48:13,405 MainProcess ThreadPoolExecutor-15_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:14] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:14] Scheduler: Generated all trials that can be generated currently. Max parallelism currently reached.
[INFO 07-18 23:48:14] Scheduler: Retrieved COMPLETED trials: 13 - 15.
[INFO 07-18 23:48:14] Scheduler: Fetching data for trials: 13 - 15.
[WARNING 07-18 23:48:14] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:48:14,478 MainProcess MainThread {storage.py:303}] boa: Saved optimization parametrization and objective to `[/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv`.
[INFO 2024-07-18 23:48:14,511 MainProcess MainThread {storage.py:63}] boa: Saved JSON-serialized state of optimization to `[/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json`.
Boa version: 0.10.3
[INFO 2024-07-18 23:48:14,528 MainProcess MainThread {scheduler.py:86}] boa: Trials so far: 16
Currently running trials: []
Will Produce next trials from generation step: BoTorch
Best trial so far: {11: {'branin': 2.0049707701997885}}
[INFO 07-18 23:48:15] Scheduler: Running trials [16]...
[INFO 2024-07-18 23:48:15,269 MainProcess ThreadPoolExecutor-16_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:15,271 MainProcess ThreadPoolExecutor-16_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 9.678556360181616, 'x1': 2.870746979312391, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000016')}
[INFO 2024-07-18 23:48:15,274 MainProcess ThreadPoolExecutor-16_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:15] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:16] Scheduler: Running trials [17]...
[INFO 2024-07-18 23:48:16,255 MainProcess ThreadPoolExecutor-17_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:16,258 MainProcess ThreadPoolExecutor-17_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 10.0, 'x1': 3.029416156399694, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000017')}
[INFO 2024-07-18 23:48:16,261 MainProcess ThreadPoolExecutor-17_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:17] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:18] Scheduler: Running trials [18]...
[INFO 2024-07-18 23:48:18,359 MainProcess ThreadPoolExecutor-18_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:18,361 MainProcess ThreadPoolExecutor-18_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 10.0, 'x1': 15.0, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000018')}
[INFO 2024-07-18 23:48:18,364 MainProcess ThreadPoolExecutor-18_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:19] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:19] Scheduler: Generated all trials that can be generated currently. Max parallelism currently reached.
[INFO 07-18 23:48:19] Scheduler: Retrieved COMPLETED trials: 16 - 18.
[INFO 07-18 23:48:19] Scheduler: Fetching data for trials: 16 - 18.
[WARNING 07-18 23:48:19] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:48:19,443 MainProcess MainThread {storage.py:303}] boa: Saved optimization parametrization and objective to `[/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv`.
[INFO 2024-07-18 23:48:19,483 MainProcess MainThread {storage.py:63}] boa: Saved JSON-serialized state of optimization to `[/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json`.
Boa version: 0.10.3
[INFO 2024-07-18 23:48:19,501 MainProcess MainThread {scheduler.py:86}] boa: Trials so far: 19
Currently running trials: []
Will Produce next trials from generation step: BoTorch
Best trial so far: {16: {'branin': 0.7355648669537729}}
[INFO 07-18 23:48:20] Scheduler: Running trials [19]...
[INFO 2024-07-18 23:48:20,388 MainProcess ThreadPoolExecutor-19_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:20,390 MainProcess ThreadPoolExecutor-19_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 9.198386091771129, 'x1': 2.204342035904566, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000019')}
[INFO 2024-07-18 23:48:20,393 MainProcess ThreadPoolExecutor-19_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:21] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:22] Scheduler: Running trials [20]...
[INFO 2024-07-18 23:48:22,102 MainProcess ThreadPoolExecutor-20_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:22,105 MainProcess ThreadPoolExecutor-20_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': -2.659599194042461, 'x1': 15.0, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000020')}
[INFO 2024-07-18 23:48:22,108 MainProcess ThreadPoolExecutor-20_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:22] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:23] Scheduler: Running trials [21]...
[INFO 2024-07-18 23:48:23,803 MainProcess ThreadPoolExecutor-21_0 {script_wrapper.py:322}] boa: Rscript run_model.R
[INFO 2024-07-18 23:48:23,806 MainProcess ThreadPoolExecutor-21_0 {script_wrapper.py:328}] boa: {'config_path': PosixPath('[/path/to/your/dir/]/config.yaml'), 'config_dir': PosixPath('[/path/to/your/dir/]'), 'config_dir_name': 'r_branin', 'config_file_name': 'config.yaml', 'x0': 8.761611833561464, 'x1': 1.5142163595154428, 'trial_dir': PosixPath('[/path/to/your/dir/]/boa_runs_20240718T234750/000021')}
[INFO 2024-07-18 23:48:23,809 MainProcess ThreadPoolExecutor-21_0 {script_wrapper.py:330}] boa: Rscript run_model.R
/home/docs/checkouts/readthedocs.org/user_builds/boa-paper/conda/latest/lib/python3.10/site-packages/ax/core/data.py:284: FutureWarning: The behavior of DataFrame concatenation with empty or all-NA entries is deprecated. In a future version, this will no longer exclude empty or all-NA columns when determining the result dtypes. To retain the old behavior, exclude the relevant entries before the concat operation.
return cls(df=pd.concat(dfs, axis=0, sort=True))
[INFO 07-18 23:48:24] ax.modelbridge.torch: The observations are identical to the last set of observations used to fit the model. Skipping model fitting.
[INFO 07-18 23:48:24] Scheduler: Generated all trials that can be generated currently. Max parallelism currently reached.
[INFO 07-18 23:48:24] Scheduler: Retrieved COMPLETED trials: 19 - 21.
[INFO 07-18 23:48:24] Scheduler: Fetching data for trials: 19 - 21.
[WARNING 07-18 23:48:24] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:48:24,888 MainProcess MainThread {storage.py:303}] boa: Saved optimization parametrization and objective to `[/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv`.
[INFO 2024-07-18 23:48:24,932 MainProcess MainThread {storage.py:63}] boa: Saved JSON-serialized state of optimization to `[/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json`.
Boa version: 0.10.3
[INFO 2024-07-18 23:48:24,951 MainProcess MainThread {scheduler.py:86}] boa: Trials so far: 22
Currently running trials: []
Will Produce next trials from generation step: BoTorch
Best trial so far: {19: {'branin': 0.6503370966339101}}
[WARNING 07-18 23:48:24] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:48:24,983 MainProcess MainThread {storage.py:303}] boa: Saved optimization parametrization and objective to `[/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv`.
[INFO 2024-07-18 23:48:25,026 MainProcess MainThread {storage.py:63}] boa: Saved JSON-serialized state of optimization to `[/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json`.
Boa version: 0.10.3
[INFO 2024-07-18 23:48:25,045 MainProcess MainThread {scheduler.py:86}] boa: Trials so far: 22
Currently running trials: []
Will Produce next trials from generation step: BoTorch
Best trial so far: {19: {'branin': 0.6503370966339101}}
[WARNING 07-18 23:48:25] ax.service.utils.report_utils: Column reason missing for all trials. Not appending column.
[INFO 2024-07-18 23:48:25,076 MainProcess MainThread {controller.py:188}] boa:
##############################################
Trials Completed!
BOA Experiment Run
Output Experiment Dir: [/path/to/your/dir/]/boa_runs_20240718T234750
Scheduler File Path: [/path/to/your/dir/]/boa_runs_20240718T234750/scheduler.json
Optimization CSV File Path: [/path/to/your/dir/]/boa_runs_20240718T234750/optimization.csv
Start Time: 20240718T234750
Version: 0.10.3
End Time: 20240718T234825
Total Run Time: 34.20745348930359
trial_index arm_name trial_status ... branin x0 x1
0 0 0_0 COMPLETED ... 36.713683 1.578879 8.985226
1 1 1_0 COMPLETED ... 6.394027 8.814644 4.073207
2 2 2_0 COMPLETED ... 102.301577 3.472612 12.099938
3 3 3_0 COMPLETED ... 50.686021 3.205356 9.315822
4 4 4_0 COMPLETED ... 26.640544 -3.796726 8.979919
5 5 5_0 COMPLETED ... 12.936570 1.287174 3.665568
6 6 6_0 COMPLETED ... 9.550569 10.000000 0.244761
7 7 7_0 COMPLETED ... 308.129096 -5.000000 0.000000
8 8 8_0 COMPLETED ... 18.655562 4.996835 3.714412
9 9 9_0 COMPLETED ... 12.800311 1.752068 5.736759
10 10 10_0 COMPLETED ... 18.784742 5.863527 1.235553
11 11 11_0 COMPLETED ... 2.004971 10.000000 2.754292
12 12 12_0 COMPLETED ... 10.309369 10.000000 5.895431
13 13 13_0 COMPLETED ... 2.233493 10.000000 3.541823
14 14 14_0 COMPLETED ... 17.508300 -5.000000 15.000000
15 15 15_0 COMPLETED ... 19.014204 -1.106899 5.747930
16 16 16_0 COMPLETED ... 0.735565 9.678556 2.870747
17 17 17_0 COMPLETED ... 1.943840 10.000000 3.029416
18 18 18_0 COMPLETED ... 145.872191 10.000000 15.000000
19 19 19_0 COMPLETED ... 0.650337 9.198386 2.204342
20 20 20_0 COMPLETED ... 16.339996 -2.659599 15.000000
21 21 21_0 COMPLETED ... 2.643111 8.761612 1.514216
[22 rows x 7 columns]
##############################################