Skip to content

Commit 40321a2

Browse files
committed
black
1 parent d9556eb commit 40321a2

3 files changed

Lines changed: 6 additions & 10 deletions

File tree

libensemble/gen_funcs/persistent_ax_multitask.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,7 @@ def get_MTGP(
102102
"""
103103

104104
if isinstance(experiment, MultiTypeExperiment):
105-
trial_index_to_type = {
106-
t.index: t.trial_type for t in experiment.trials.values()
107-
}
105+
trial_index_to_type = {t.index: t.trial_type for t in experiment.trials.values()}
108106
transforms = MT_MTGP_trans
109107
transform_configs = {
110108
"TrialAsTask": {"trial_level_map": {"trial_type": trial_index_to_type}},
@@ -275,9 +273,7 @@ def persistent_gp_mt_ax_gen_f(H, persis_info, gen_specs, libE_info):
275273
if not os.path.exists("model_history"):
276274
os.mkdir("model_history")
277275
# Register metric and runner in order to be able to save to json.
278-
_, encoder_registry, decoder_registry = register_metrics(
279-
{AxMetric: None}
280-
)
276+
_, encoder_registry, decoder_registry = register_metrics({AxMetric: None})
281277
_, encoder_registry, decoder_registry = register_runner(
282278
AxRunner,
283279
encoder_registry=encoder_registry,

libensemble/tests/regression_tests/test_persistent_aposmm_ibcdfo_pounders.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,9 +105,9 @@ def synthetic_beamline_mapping(H, _, sim_specs):
105105
"persis_in": ["f", "fvec"] + [n[0] for n in gen_out],
106106
"out": gen_out,
107107
"user": {
108-
"initial_sample_size": 1, # The initial sampled point will be the starting point
109-
"stop_after_k_runs": 1, # Only one local optimization run will be performed
110-
"max_active_runs": 1, # Only one local optimization run will be performed,
108+
"initial_sample_size": 1, # The initial sampled point will be the starting point
109+
"stop_after_k_runs": 1, # Only one local optimization run will be performed
110+
"max_active_runs": 1, # Only one local optimization run will be performed,
111111
"sample_points": np.atleast_2d(0.1 * (np.arange(n) + 1)),
112112
"localopt_method": "ibcdfo_pounders",
113113
"run_max_eval": 100 * (n + 1),

libensemble/tests/regression_tests/test_persistent_gp_multitask_ax.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ def run_simulation(H, persis_info, sim_specs, libE_info):
5050
z = 8
5151
elif task == "cheap_model":
5252
z = 1
53-
print('in sim', task)
53+
print("in sim", task)
5454

5555
libE_output = np.zeros(1, dtype=sim_specs["out"])
5656
calc_status = WORKER_DONE

0 commit comments

Comments
 (0)