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

Skip extra downloads when not using a format string #2073

Merged
merged 3 commits into from
Mar 15, 2023

Conversation

dakinggg
Copy link
Contributor

@dakinggg dakinggg commented Mar 15, 2023

What does this PR do?

Previously, if the load_path was specified as a not format string, all ranks would download the same checkpoint, resulting in 8x the ingress to the node. This PR gates the downloads behind a check for whether sharded checkpoints are used so that only local rank 0 downloads the checkpoint.

Before and after of network usage for a resumption:
Screen Shot 2023-03-14 at 11 54 59 PM

What issue(s) does this change relate to?

Closes CO-1883

Before submitting

  • Have you read the contributor guidelines?
  • Was this change discussed/approved in a GitHub issue first? It is much more likely to be merged if so.
  • Did you update any related docs and document your change?
  • Did you update any related tests and add any new tests related to your change? (see testing)
  • Did you run the tests locally to make sure they pass?
  • Did you run pre-commit on your change? (see the pre-commit section of prerequisites)

@dakinggg dakinggg marked this pull request as ready for review March 15, 2023 04:16
@mvpatel2000 mvpatel2000 self-requested a review March 15, 2023 17:30
Copy link
Contributor

@eracah eracah left a comment

Choose a reason for hiding this comment

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

LGTM. Very clean!

@eracah eracah merged commit ed686eb into mosaicml:dev Mar 15, 2023
bandish-shah pushed a commit that referenced this pull request Mar 15, 2023
Previously, if the load_path was specified as a not format string, all ranks would download the same checkpoint, resulting in 8x the ingress to the node. This PR gates the downloads behind a check for whether sharded checkpoints are used so that only local rank 0 downloads the checkpoint.
@dakinggg dakinggg deleted the skip_extra_downloads branch September 9, 2023 22:47
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.

3 participants