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

Make Acquisition.optimize work with discrete optimizer regardless of whether num_restarts is in optimizer_options #3197

Closed
wants to merge 4 commits into from

Conversation

esantorella
Copy link
Contributor

Summary:
Context:

In Acquisition.optimize, we remove raw_samples from optimizer_options when the discrete optimizer was used (D63035021), but we don't do the same for num_restarts even though it is also not supported by the discrete optimizer.

This PR:

  • Removes num_restarts from optimizer_options when the discrete optimizer is ued
  • Takes out a TODO to ensure it is never passed in the first place-- not feasible since we won't know if the optimizer is discrete before hitting that point

Differential Revision: D67419600

@facebook-github-bot facebook-github-bot added the CLA Signed Do not delete this pull request or issue due to inactivity. label Dec 18, 2024
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D67419600

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.86%. Comparing base (6099333) to head (4d93ad5).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3197   +/-   ##
=======================================
  Coverage   95.86%   95.86%           
=======================================
  Files         510      510           
  Lines       51499    51521   +22     
=======================================
+ Hits        49368    49390   +22     
  Misses       2131     2131           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Summary:

**Context**: Currently, benchmark metric tests conflate whether the metadata consumed by `fetch_trial_data` has multiple time steps with whether the output data should be `MapData`, and don't explicitly address the separate cases of whether or not there is a `BackendSimulator` attached to the metadata. They are also not organized well. These issues will become more pressing when we start to allow `BenchmarkMetric` to consume data with multiple time steps and/or use a backend simulator

**This diff**:
* Organizes those unit tests better
* Adds some more checks

Reviewed By: Balandat

Differential Revision: D67281379
…er time (facebook#3184)

Summary:

**Context**: There are situations where a metric is not a MapMetric, but its value changes depending on time.

**This diff**:
Introduces `BenchmarkTimeVaryingMetric`, which is not a MapMetric, can consume data with multiple time steps, is available while running, and requires a backend simulator.

Reviewed By: Balandat

Differential Revision: D67224949
Summary:

This diff
* Changes some Pandas indexing to avoid a "setting with copy" warning
* Corrects the docstring of `BenchmarkTrialMetadata`
* Renames `ModelLauncherProblem` to `ModelLauncherTestFunction`, since it is a test function and not a problem

Reviewed By: Balandat

Differential Revision: D67419032
…f whether `num_restarts` is in `optimizer_options` (facebook#3197)

Summary:

Context:

In `Acquisition.optimize`, we remove `raw_samples` from `optimizer_options` when the discrete optimizer was used (D63035021), but we don't do the same for `num_restarts` even though it is also not supported by the discrete optimizer.

This PR:
* Removes `num_restarts` from `optimizer_options` when the discrete optimizer is ued
* Takes out a TODO to ensure it is never passed in the first place-- not feasible since we won't know if the optimizer is discrete before hitting that point

Reviewed By: saitcakmak

Differential Revision: D67419600
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D67419600

@facebook-github-bot
Copy link
Contributor

This pull request has been merged in f83d9a6.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Do not delete this pull request or issue due to inactivity. fb-exported Merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants