NOTICE: OptunaHub is under development and all features are experimental. API may change in the future.
Python Library to use packages published in OptunaHub. If you would like to register your package in OptunaHub, please contribute by creating a pull request to the optunahub-registry repository.
Install optunahub
package.
pip install optunahub
import optuna
import optunahub
def objective(trial: optuna.Trial) -> float:
x = trial.suggest_float("x", 0, 1)
return x
mod = optunahub.load_module("samplers/simulated_annealing")
study = optuna.create_study(sampler=mod.SimulatedAnnealingSampler())
study.optimize(objective, n_trials=20)
print(study.best_trial.value, study.best_trial.params)