microsoft / nni

An open source AutoML toolkit for automate machine learning lifecycle, including feature engineering, neural architecture search, model compression and hyper-parameter tuning.
https://nni.readthedocs.io
MIT License
14.02k stars 1.81k forks source link

support specifying joint constraints on hyperparameters #1356

Open QuanluZhang opened 5 years ago

QuanluZhang commented 5 years ago

What would you like to be added: In the current version, nni only allows specifying each hyperparameter's feasible region independently. But in some scenarios user may want to specify joint constraint across multiple hyperparameters, for example, the sum of hyperparameter a, b, c should be equal to 10.

Without this feature, how does current nni work:not easy

Brief description of your proposal if any: provide an interface for users to specify such constraints, and tuners validate the constraints on the generated trial configurations (e.g., hyperparameters) before sending them to training service.

ultmaster commented 5 years ago

The easiest way out is to write a tuner inheriting an existing tuner that filters the parameters generated by the parent tuner. See https://github.com/microsoft/nni/blob/master/examples/trials/efficientnet/tuner.py

scarlett2018 commented 4 years ago

Assign to @ultmaster to drive the design discussion.