[tune] Usability errors PBT (#5972)

* update with upstream master

* check for function args in hyperparam_mutations pbt

* fix style for pbt

* remove_checkpoint

* Update pbt.py

* Update pbt.py

* fix

Co-authored-by: Richard Liaw <rliaw@berkeley.edu>
This commit is contained in:
inventormc
2019-12-26 14:27:07 -08:00
committed by Richard Liaw
parent b40869d0e4
commit 0dd8a60679
+5
View File
@@ -183,6 +183,11 @@ class PopulationBasedTraining(FIFOScheduler):
resample_probability=0.25,
custom_explore_fn=None,
log_config=True):
for value in hyperparam_mutations.values():
if not (isinstance(value, list) or callable(value)):
raise TypeError("`hyperparam_mutation` values must be either "
"a List or callable.")
if not hyperparam_mutations and not custom_explore_fn:
raise TuneError(
"You must specify at least one of `hyperparam_mutations` or "