Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrading Optuna from v2.x.x to v3.0.0 #1851

Closed
himkt opened this issue Apr 21, 2022 · 1 comment · Fixed by #1942
Closed

Upgrading Optuna from v2.x.x to v3.0.0 #1851

himkt opened this issue Apr 21, 2022 · 1 comment · Fixed by #1942

Comments

@himkt
Copy link
Contributor

himkt commented Apr 21, 2022

/kind feature

(Sorry but it is not a feature request)

Related: optuna/optuna#2941

Thank you for integrating Optuna for the hyperparameter optimization feature. We, Optuna dev-team, are working on the next major version of the library Optuna v3. In Optuna v3, we will deprecate distributions used in:

def _get_optuna_search_space(self):
search_space = {}
for param in self.search_space.params:
if param.type == INTEGER:
search_space[param.name] = optuna.distributions.IntUniformDistribution(int(param.min), int(param.max))
elif param.type == DOUBLE:
search_space[param.name] = optuna.distributions.UniformDistribution(float(param.min), float(param.max))
elif param.type == CATEGORICAL or param.type == DISCRETE:
search_space[param.name] = optuna.distributions.CategoricalDistribution(param.list)
return search_space

We will introduce FloatDistribution and IntDistribution. So distributions in OptunaService will have to be updated:

  • UniformDistribution(low, high) => FloatDistribution(low, high)
  • IntUniformDistribution(low, high) => IntDistribution(low, high)

Now katib installs the latest Optuna. Users will see the deprecation warnings in the Optuna v3 release. I will open a PR that restricts the constraint to avoid such warnings. Note that it doesn't mean Optuna v3 is imcompatible with Optuna v2. It only shows warnings and deprecated distributions are internally converted to appropriate distributions.

Describe the solution you'd like

  • Add version constraint of Optuna to avoid showing deprecation messages to users
  • Track the status of the release of the development of Optuna v3.0.0

I create this issue to track the status of Optuna.
After Optuna v3 is available, we want to upgrade the library.
We will back here when the release is available.

Anything else you would like to add:
If you have some concerns or questions, please feel free to contact Optuna dev-team.
🔗 optuna/optuna#2941


Love this feature? Give it a 👍 We prioritize the features with the most 👍

@johnugeorge
Copy link
Member

Thanks @himkt for reporting this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants