Ejemplo n.º 1
0
def main():
    batch_util.init_logging()
    batch = batch_util.batch_run()
    batch_flags = batch.get("flags")
    max_trials = batch.get("max_trials") or DEFAULT_MAX_TRIALS
    random_seed = batch.get("random_seed")
    trials = hyperopt.Trials()
    try:
        hyperopt.fmin(
            fn=_objective_fn(batch),
            space=_space_for_flags(batch),
            algo=_tpe_suggest,
            max_evals=max_trials,
            show_progressbar=False,
            rstate=np.random.RandomState(random_seed),
            trials=trials,
        )
    except hyperopt.exceptions.AllTrialsFailed:
        pass
    else:
        _label_best(trials.best_trial)
Ejemplo n.º 2
0
def main():
    batch_util.init_logging()
    batch_run = batch_util.batch_run()
    skopt_util.handle_seq_trials(batch_run, _suggest_x)
Ejemplo n.º 3
0
def main():
    batch_util.init_logging()
    batch_run = batch_util.batch_run()
    trials = _batch_trials(batch_run)
    batch_util.handle_trials(batch_run, trials)