aup.Proposer package¶
The proposer is the core component to optimize hyperparameters for model training.
Use aup.Proposer.AbstractProposer.get_proposer()
to initialize proposer.
All of them adopt the same interface as described below.
Proposers¶
aup.Proposer.AbstractProposer¶
aup.Proposer.AbstractProposer
provide interface for Hyperparameter Optimization Modules.
APIs¶
-
class
AbstractProposer
(config)[source]¶ Bases:
abc.ABC
Proposer to generate new values for hyperparameters
- Parameters
config (BasicConfig) – experiment configuration
-
get
(**kwargs)[source]¶ Wrapper for specific
get_param()
to updatecurrent_proposal
andcounter
.- Parameters
kwargs (dict) – any arguments to be passed to
get_param()
- Returns
parameter values
- Return type
dict
-
static
parse_param_config
(config)[source]¶ Parse the given experiment configuration of
parameter_config
If values are missing, fill in defaults.- Parameters
config (dict) – config[“param_config”]
- Returns
updated config
- Return type
dict
-
save
(path)[source]¶ Save Proposer state to path.
Some proposer can not generate new parameters after saving.
- Parameters
path (str) – path to save