A simple optimization problem: Define objective function to be optimized. Let's minimize (x - 2)^2 Suggest hyperparameter values using trial object. Here, a float value of x is suggested from -10 to 10 Create a study object and invoke the optimize method over 100 trials import optuna def objective(trial): x = trial.suggest_float('x', -10, 10) return (x - 2) ** 2 study = optuna.create_study() study
![Optuna - A hyperparameter optimization framework](https://cdn-ak-scissors.b.st-hatena.com/image/square/1d0c93a62050a7c545c47f623282a09efa7cc8df/height=288;version=1;width=512/https%3A%2F%2Foptuna.org%2Fassets%2Fimg%2Foptuna-logo.png)