Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add CLI option for Error Grid interval #18

Open
sjvrijn opened this issue Aug 2, 2022 · 0 comments
Open

Add CLI option for Error Grid interval #18

sjvrijn opened this issue Aug 2, 2022 · 0 comments

Comments

@sjvrijn
Copy link
Owner

sjvrijn commented Aug 2, 2022

This should also be included in the results folder naming scheme.

Since the Error Grids are not used for fixed strategy experiments, it can/should be omitted in those cases.
Once included when saving, it should also be included in the results parsing.

A small bit of WIP to implement this:

--- a/scripts/experiments/2020-11-05-simple-mfbo.py
+++ b/scripts/experiments/2020-11-05-simple-mfbo.py
@@ -91,8 +91,12 @@ def main(args):
         print(func.name)
 
         for idx, cost_ratio, experiment in product(range(args.niters), args.cost_ratio, args.experiment):
+
+            if experiment != 'fixed':
+                experiment = f'{experiment}-egi{args.eg_interval}'
             kwargs['seed_offset'] = idx
             kwargs['cost_ratio'] = cost_ratio
+            kwargs['eg_interval'] = args.eg_interval
             kwargs['run_save_dir'] = save_dir / FOLDER_NAME_TEMPLATE.format(
                 func_name=func.name,
                 name=experiment,
@@ -134,6 +138,8 @@ if __name__ == '__main__':
                         help="Stop optimization when optimum reached based on function's `x_opt`")
     parser.add_argument('--cache-models', action='store_true',
                         help="Cache models when building an error grid. NOTE: requires 200+GB RAM")
+    parser.add_argument('--eg-interval', type=int, default=[1], nargs='*',
+                        help="Error Grid Sampling interval, ignored . Default: 1")
     arguments = parser.parse_args()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant