This is the release note of v1.2.0.
Highlights
Trial Queue
Study.enqueue_trial
allows the user to specify fixed parameter values to be tried next instead of values from the suggestion algorithms. An example is available in the reference. See #520.
Note that this feature introduced an RDB schema change. If you have stored studies created by Optuna v1.1.0 or less in RDBs, please execute $ optuna storage upgrade --storage $URL
after updating Optuna.
Experimental Grid Search
Grid search has been introduced as an experimental feature through GridSampler
. See #665.
Breaking Changes
Trial.report
to not update the trial value. (#854)
New Features
- Add trial queue. (#520)
- Add a sampler class based on grid search. (#665)
- Display progress bar in optimization process. (#844)
Trial.report
to not update the trial value. (#854)- Add
experimental
warning. (#884) experimental
decorator to accept optionalname
and apply to progress bar. (#918)- Add a
n_startup_trials
option toSkoptSampler
. (#951)
Enhancements
- Fix
OptunaSearchCV
by adding the method that was implemented inscikit-learn>=0.22.1
. (#881, thanks @himkt!) - User-friendly error message for fixed categorical parameter not found in choices. (#900)
- Trial level suggest for same variable with different parameters give warning. (#908, thanks @PhilipMay!)
- More verbose warning message in
Trial._check_distribution
. (#934, thanks @PhilipMay!)
Bug Fixes
- Fix
LightGBMTuner
to handle metrics with evaluation positions. (#912) - Fix a TPE implementation on
DiscreteUniformDistribution
. (#917)- If you use
Trial.suggest_discrete_uniform
with the default sampler (i.e.,TPESampler
), optimization performance may degrade due to the issue (#916). Please update Optuna to this version or later.
- If you use
- Use
weakref.finalize
instead of__del__
forRDBStorage
. (#941)
Documentation
- Add examples for
doctest
tooptuna/trial.py
. (#882, thanks @nuka137!) - Add an example of
enqueue_trial
. (#927) - Fix typo for
cma.EvotionStrategy
. (#929) - Explain installing local Optuna explicitly. (#932, thanks @keisuke-umezawa!)
- Documentation of algorithm behind Optuna. (#940, thanks @arpitkh101!)
- Run a doctest of pycma sampler. (#944)
- Fix doctest in logging. (#953, thanks @keisuke-umezawa!)
- Fix doctest in
parallel_coordinate
. (#955, thanks @keisuke-umezawa!) - Add examples for
doctest
tooptuna/exceptions.py
. (#958, thanks @nuka137!) - Remove description and example of
optuna.structs.TrialPruned
(followup of #958). (#959) - Add examples for
doctest
tooptuna/prunes/*.py
. (#964, thanks @nuka137!) - Fix doctest in visualization. (#973, thanks @keisuke-umezawa!)
Examples
- Add an example of
xgboost.cv
usingXGBoostPruningCallback
. (#907, thanks @yutayamazaki!) - TensorFlow estimator example with only v2 APIs. (#924, thanks @nuka137!)
- TensorFlow estimator integration example with only v2 APIs. (#935, thanks @nuka137!)
- Simplify PyTorch Ignite example by removing an evaluator. (#971)
Tests
- Add
__init__.py
totests/samplers_tests/tpe_tests
. (#945, thanks @keisuke-umezawa!) - Cast to
numpy.ndarray
as Python lists are no longer accepted inxgboost==1.0
. (#947)
Code Fixes
- Simplified
_check_distribution
. (#937, thanks @PhilipMay!)