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

[tune] Fix hpo randint limits #11946

Merged
merged 4 commits into from
Nov 12, 2020

Conversation

krfricke
Copy link
Contributor

Why are these changes needed?

HyperOpt actually supports broader limits for randint.

Related issue number

Checks

  • I've run scripts/format.sh to lint the changes in this PR.
  • I've included any doc changes needed for https://docs.ray.io/en/master/.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, see the recent failures at https://flakey-tests.ray.io/
  • Testing Strategy
    • Unit tests
    • Release tests
    • This PR is not tested :(

Copy link
Member

@sumanthratna sumanthratna left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks perfect, assuming tests pass—thanks @krfricke

@sumanthratna
Copy link
Member

@krfricke the CI errors made me realize—this is a breaking change, right? This should be a pretty easy fix for tune users but if we really want to stick to semver maybe we should change low to a kwarg (low=0, high... instead of low, high..). not really sure what the best option here is

@krfricke
Copy link
Contributor Author

Is it a breaking change? As I see it it just affects the search space conversion, and Tune's randint definition always included a lower and a upper bound. Behavior on hyperopt's side is not affected, is it?

@krfricke
Copy link
Contributor Author

But I guess we could pass kwargs to hyperopt. instead of args to be sure. Can you update the PR?

@richardliaw
Copy link
Contributor

I think this is backwards compatible, so it's safe to include without modifications to signature.

@richardliaw
Copy link
Contributor

tests failing though

@sumanthratna
Copy link
Member

sumanthratna commented Nov 12, 2020

Tune's randint definition always included a lower and a upper bound. Behavior on hyperopt's side is not affected, is it?

Ahh yup that's my bad; I forgot we had our own lower arg. You're right, this isn't a breaking change

But I guess we could pass kwargs to hyperopt. instead of args to be sure. Can you update the PR?

sure, is c142b85 what you were expecting?


edit: whoops, just saw this:

I think this is backwards compatible, so it's safe to include without modifications to signature.

happy to revert part of the kwarg commit to stick to args for the signature

@richardliaw richardliaw merged commit 02c0236 into ray-project:master Nov 12, 2020
@krfricke krfricke deleted the tune-hp-randint-bounds branch November 12, 2020 16:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants