-
Notifications
You must be signed in to change notification settings - Fork 313
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
Support fixed features in Service API #2015
Conversation
@Cesar-Cardoso has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #2015 +/- ##
==========================================
- Coverage 94.52% 94.51% -0.01%
==========================================
Files 460 460
Lines 44301 44303 +2
==========================================
+ Hits 41874 41875 +1
- Misses 2427 2428 +1 ☔ View full report in Codecov by Sentry. |
Hi all, has there been any update on this? We're currently having to use a custom subclass of Feel free to let me know if there's anything I should change in how I implemented the feature. |
Seconded on @AngelFP's comment! I've been itching to implement a fixed feature option within https://honegumi.readthedocs.io/ to better serve the researchers in my circle (earlier today I had a conversation about fixed features with a colleague today), but it's going to be much more straightforward to do so with this PR merged. Anything that requires help? Does this perhaps require a unit test to be written? EDIT: If I'm not mistaken, it's already covered by a unit test, correct? @Cesar-Cardoso and co., it looks like all checks are passing, except for "Facebook Internal - Linter". Does this check need to be fixed? Non- meta employees can't view details on this. I also wanted to point out that there are many issues scattered around related to this:
|
As an aside, now actually having reviewed the changed files, @AngelFP's implementation looks really straightforward. The key lines are: def _gen_new_generator_run(
self, n: int = 1, fixed_features: Optional[ObservationFeatures] = None
) -> GeneratorRun:
...
if fixed_features:
fixed_feats.update_features(fixed_features)
...
|
if fixed_features: | ||
fixed_feats.update_features(fixed_features) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Cesar-Cardoso This is really the only thing that's changing. The rest is plumbing to be able to pass fixed_features
down to _gen_new_generator_run(...)
.
Hi folks! Apologies for the slow response from my part. Support for fixed features is being added now in #2372. Only difference being the use of |
Hi @Cesar-Cardoso , great to see this done! Thanks for looking into it. |
I'll try to put a MWE up soon, but a starting point might be Ax/ax/service/tests/test_ax_client.py Lines 2838 to 2863 in 18d0842
|
Addresses #746 (also in the wishlist #566).
As the title implies, this PR adds the possibility of specifying some
ObservationFeatures
asfixed_features
inAxClient.get_next_trial
andAxClient.get_next_trials
. From my understanding, this is currently only possible with the developer API.This is an option we would like to expose in optimas, where we use the Service API for most of the BO generators.