secondmind-labs / trieste

A Bayesian optimization toolbox built on TensorFlow
Apache License 2.0
212 stars 42 forks source link

Handle unconstrained priors in randomize_hyperparameters #796

Closed uri-granta closed 8 months ago

uri-granta commented 8 months ago

Related issue(s)/PRs: #793

Summary

Fix randomize_hyperparameters to handle unconstrained priors.

Also change the logic for handling Sigmoid constraints: we now prioritise sampling from the prior if there is one, and sample from the constrained domain only if there isn't.

Fully backwards compatible: no

New Sigmoid behaviour is more logical and flexible, and old behaviour can be easily obtained by removing any prior.

PR checklist

hstojic commented 8 months ago

@uri-granta did you check @j-wilson PR where he also addressed the same issue: https://github.com/secondmind-labs/trieste/pull/794?

uri-granta commented 8 months ago

@uri-granta did you check @j-wilson PR where he also addressed the same issue: #794?

AFAIU that's doing more than just fixing the bug in randomize_hyperparameters. Will look at that as soon as this is merged.