optuna_integration/optuna-search-cv-deprecated-distributions
| Pack | Severity | Fix | Versions |
|---|---|---|---|
| Optuna Integration | error | none, edit by hand | All versions |
OptunaSearchCV.fit() explicitly rejects deprecated Optuna distributions (UniformDistribution, LogUniformDistribution, DiscreteUniformDistribution, IntUniformDistribution, and IntLogUniformDistribution) with ValueError.
search = OptunaSearchCV(est, {"alpha": optuna.distributions.LogUniformDistribution(1e-3, 10.0)})search = OptunaSearchCV(est, {"alpha": optuna.distributions.FloatDistribution(1e-3, 10.0, log=True)})What the rule reports
Section titled “What the rule reports”Deprecated Optuna distribution constructors passed inside an OptunaSearchCV(...) call.
How to fix it
Section titled “How to fix it”Use optuna.distributions.FloatDistribution (with log=True or step= as needed) and optuna.distributions.IntDistribution.
Diagnostic message
Section titled “Diagnostic message”OptunaSearchCV rejects deprecated Optuna distributions ($D) with ValueError during fit. Replace them with FloatDistribution or IntDistribution.See all rules in the Optuna Integration pack.