Skip to content

Commit

Permalink
fix(automl/tuners): fix inheritance chain
Browse files Browse the repository at this point in the history
  • Loading branch information
ruancomelli committed Jul 6, 2022
1 parent b039559 commit 2975d91
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion boiling_learning/automl/tuners.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def set_state(self, state: Dict[str, Any]) -> None:
self.stop_search = state['stop_search']


class EarlyStoppingHyperbandOracle(ak.tuners.hyperband.HyperbandOracle):
class EarlyStoppingHyperbandOracle(kt.oracles.HyperbandOracle):
def __init__(self, *args: Any, **kwargs: Any) -> None:
super().__init__(*args, **kwargs)
self.stop_search = False
Expand Down Expand Up @@ -227,6 +227,7 @@ def __init__(
goal: Any,
objective: str = 'val_loss',
max_epochs: int = 100,
max_trials: int = 1000,
factor: int = 3,
seed: Optional[int] = None,
hyperparameters: Optional[kt.HyperParameters] = None,
Expand All @@ -244,6 +245,7 @@ def __init__(
tune_new_entries=tune_new_entries,
allow_new_entries=allow_new_entries,
)
oracle.max_trials = max_trials
super().__init__(oracle=oracle, **kwargs)

def on_epoch_end(
Expand Down

0 comments on commit 2975d91

Please sign in to comment.