Skip to content

Commit eaef976

Browse files
committed
Make test_persistent_gp_multitask_ax.py use gen_on_manager
1 parent 9a4b571 commit eaef976

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

libensemble/tests/regression_tests/test_persistent_gp_multitask_ax.py

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,22 @@
22
Example of multi-fidelity optimization using a persistent GP gen_func (calling
33
Ax).
44
5+
Test is set to use the gen_on_manager option (persistent generator runs on
6+
a thread). Therefore nworkers is the number of simulation workers.
7+
58
Execute via one of the following commands (e.g. 5 workers):
6-
mpiexec -np 5 python test_persistent_gp_multitask_ax.py
7-
python test_persistent_gp_multitask_ax.py --nworkers 4 --comms local
8-
python test_persistent_gp_multitask_ax.py --nworkers 4 --comms tcp
9+
mpiexec -np 4 python test_persistent_gp_multitask_ax.py
10+
python test_persistent_gp_multitask_ax.py --nworkers 3 --comms local
11+
python test_persistent_gp_multitask_ax.py --nworkers 3 --comms tcp
912
1013
When running with the above commands, the number of concurrent evaluations of
11-
the objective function will be 3, as one of the three workers will be the
12-
persistent generator.
14+
the objective function will be 3.
1315
14-
Requires numpy<2.
1516
"""
1617

1718
# Do not change these lines - they are parsed by run-tests.sh
1819
# TESTSUITE_COMMS: local mpi
19-
# TESTSUITE_NPROCS: 5
20+
# TESTSUITE_NPROCS: 4
2021
# TESTSUITE_EXTRA: true
2122
# TESTSUITE_OS_SKIP: OSX
2223
# TESTSUITE_EXCLUDE: true
@@ -63,6 +64,7 @@ def run_simulation(H, persis_info, sim_specs, libE_info):
6364
# Main block is necessary only when using local comms with spawn start method (default on macOS and Windows).
6465
if __name__ == "__main__":
6566
nworkers, is_manager, libE_specs, _ = parse_args()
67+
libE_specs["gen_on_manager"] = True
6668

6769
mt_params = {
6870
"name_hifi": "expensive_model",

0 commit comments

Comments
 (0)