botorch icon indicating copy to clipboard operation
botorch copied to clipboard

Performance & runtime improvements to info-theoretic acquisition functions (2/N) - AcqOpt initializer

Open hvarfner opened this issue 9 months ago • 8 comments

A series of improvements directed towards improving the performance of PES & JES, as well as their MultiObj counterparts.

This PR adds an initializer for the acquisition function optimization, which drastically speeds up the number of required forward passes from ~150-250 --> ~25 by providing suggestions close to the sampled optima obtained during acquisition function construction.

@esantorella Moreover, better acquisition function values are found (PR 1's BO loop, but both acq opts are run in parallel): found_acquisition_value

Moreover, it is a lot faster: opt_time

This does not always improve performance, however (PR1 is more local due to sample_around_best dominating candidate generation, which is generally good): regret

Lastly, a nice comp to LogNEI with the introduced mods: jes_logei

Moreover, they are now much closer in terms of runtime: total_runtime

And here's the allocation between posterior sampling time and acq optimization time. runtime

So apart from Michalewicz, it does pretty good now!

Related PRs

Previous one

hvarfner avatar Feb 20 '25 06:02 hvarfner

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 99.99%. Comparing base (78c04e2) to head (f1d4ec0).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2751   +/-   ##
=======================================
  Coverage   99.99%   99.99%           
=======================================
  Files         203      203           
  Lines       18685    18726   +41     
=======================================
+ Hits        18684    18725   +41     
  Misses          1        1           

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Feb 20 '25 17:02 codecov[bot]

@esantorella has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar Feb 25 '25 16:02 facebook-github-bot

@esantorella has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar Feb 25 '25 23:02 facebook-github-bot

Thanks for this! I'm looking forward to seeing the plots.

esantorella avatar Feb 25 '25 23:02 esantorella

@esantorella has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar Feb 26 '25 18:02 facebook-github-bot

I have not quite figured out why the test coverage is not there, since I thought I addressed it today. I will also figure out the conflicts ASAP!

hvarfner avatar Feb 26 '25 21:02 hvarfner

@esantorella has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar Feb 26 '25 21:02 facebook-github-bot

@esantorella has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar Feb 28 '25 23:02 facebook-github-bot