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

zero.Init() should pin params in GPU memory as requested #2953

Merged
merged 35 commits into from
Apr 7, 2023

Conversation

tjruwase
Copy link
Contributor

@tjruwase tjruwase commented Mar 6, 2023

Currently, zero.Init() will offload all parameters even if user requested some to be pinned in GPU memory (using *_persistence_threshold configs). Those params are eventually pinned into GPU memory after the first forward pass. Unfortunately, zero.Init() may fail CPU OOM which could be avoided by utilizing GPU and CPU memory per user request.
This PR avoids this problem and improves flexibility of combining GPU and CPU memory.

@tjruwase tjruwase requested review from jeffra, samyam and jomayeri March 6, 2023 13:42
@tjruwase tjruwase requested a review from mrwyattii as a code owner March 6, 2023 13:42
@tjruwase tjruwase merged commit 4d27225 into master Apr 7, 2023
@mrwyattii mrwyattii deleted the olruwase/zero_infer_partial_offload branch July 7, 2023 02:36
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.

2 participants