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

[Doc] Clarified when to use Mlflow logger and setup_mlflow; fix #36257 #37854

Merged
merged 2 commits into from
Nov 8, 2023

Conversation

hahahannes
Copy link
Contributor

Why are these changes needed?

Information was missing about when to use Mlflow Callback or setup_mlflow. I added the explanation of @krfricke.

Related issue number

See #36257

Checks

  • I've signed off every commit(by using the -s flag, i.e., git commit -s) in this PR.
  • 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 added any new APIs to the API Reference. For example, if I added a
      method in Tune, I've added it in doc/source/tune/api/ under the
      corresponding .rst file.
  • 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 :(

@stale
Copy link

stale bot commented Sep 16, 2023

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.

  • If you'd like to keep this open, just leave any comment, and the stale label will be removed.

@stale stale bot added the stale The issue is stale. It will be closed within 7 days unless there are further conversation label Sep 16, 2023
@hahahannes
Copy link
Contributor Author

ping @krfricke

I am not sure whether the tests are related to documentation

@stale
Copy link

stale bot commented Oct 15, 2023

Hi again! The issue will be closed because there has been no more activity in the 14 days since the last message.

Please feel free to reopen or open a new issue if you'd still like it to be addressed.

Again, you can always ask for help on our discussion forum or Ray's public slack channel.

Thanks again for opening the issue!

@stale stale bot closed this Oct 15, 2023
@hahahannes
Copy link
Contributor Author

@krfricke Hi, just a quick ping, if I shall reopen the PR ? Totally understand, that this is not an important issue

@jjyao
Copy link
Contributor

jjyao commented Oct 23, 2023

@matthewdeng can you follow up.

@matthewdeng matthewdeng reopened this Oct 24, 2023
@stale stale bot removed the stale The issue is stale. It will be closed within 7 days unless there are further conversation label Oct 24, 2023
Copy link
Contributor

@matthewdeng matthewdeng left a comment

Choose a reason for hiding this comment

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

Thanks 😄

@@ -45,8 +45,8 @@ def setup_mlflow(
) -> Union[ModuleType, _NoopModule]:
"""Set up a MLflow session.

This function can be used to initialize an MLflow session in a
(distributed) training or tuning run.
This function can be used to initialize a MLflow session in a
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: This should still be an since the M starts with a vowel sound.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done in the last commit

Comment on lines 201 to 205
Keep in mind, that the callback will open a Mlflow session on the driver and
not on the trainable. Therefore, it is not possible to call mlflow methods
like ``mlflow.log_figure()`` inside the trainable as there is no Mlflow session
on the trainable. Use :func:`setup_mlflow` if you need more fine grained control.

Copy link
Contributor

Choose a reason for hiding this comment

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

nit:

    Keep in mind that the callback will open an MLflow session on the driver and
    not on the trainable. Therefore, it is not possible to call MLflow functions
    like ``mlflow.log_figure()`` inside the trainable as there is no MLflow session
    on the trainable. For more fine grained control, use :func:`setup_mlflow`.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done in the last commit

@hahahannes
Copy link
Contributor Author

Hi @matthewdeng Sorry for the late response! I applied your changes, thank you!

Copy link
Contributor

@matthewdeng matthewdeng left a comment

Choose a reason for hiding this comment

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

Thanks for the contribution! It looks like the docs are not rendering properly due to a different reason, will address that separately.

@matthewdeng matthewdeng merged commit 913258e into ray-project:master Nov 8, 2023
19 of 26 checks passed
ujjawal-khare pushed a commit to ujjawal-khare-27/ray that referenced this pull request Nov 29, 2023
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