-
Notifications
You must be signed in to change notification settings - Fork 6k
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] change delimiter for results #16573
Conversation
Signed-off-by: Richard Liaw <rliaw@berkeley.edu>
@krfricke lmk what you think about this. |
"Dataframes will use '/' instead of '.' to delimit " | ||
"nested result keys in future versions of Ray. For forward " | ||
"compatibility, set the environment variable " | ||
"TUNE_RESULT_NEW_DELIM=1.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TUNE_RESULT_DELIM="."
instead?
def _delimiter(self): | ||
delimiter = os.environ.get("TUNE_RESULT_DELIM", "/") | ||
if delimiter == "/" and log_once("delimiter_deprecation"): | ||
warnings.warn( | ||
"Dataframes will use '/' instead of '.' to delimit " | ||
"nested result keys in future versions of Ray. For forward " | ||
"compatibility, set the environment variable " | ||
"TUNE_RESULT_DELIM='.'") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe I'm confused here, but shouldn't this be the other way around?
I.e. we use
delimiter = os.environ.get("TUNE_RESULT_DELIM", ".")
because it is the current behavior. Then we check
if delimiter == "." and log_once("delimiter_deprecation"):
because the .
will be deprecated, and then we suggest
"nested result keys in future versions of Ray. For forward "
"compatibility, set the environment variable "
"TUNE_RESULT_DELIM='/'")
because /
will be used in the future?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did the changes according to my comments and will merge as current behavior will not be changed. We can then switch to the new delimiter in the 1.9.0 release.
Why are these changes needed?
We should have a consistent usage of "/" for all dict flattening?
Related issue number
Checks
scripts/format.sh
to lint the changes in this PR.