-
Notifications
You must be signed in to change notification settings - Fork 137
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
CUDA memory cache increasing #37
Comments
When you free a tensor, the memory is not returned to the GPU immediately. Instead, it is cached by PyTorch to be reused for future allocations. This is why |
Yes, but it is strange that with the growth of requests, the size of the enhancer increases so much. Also, i think it's strange to have 13Gb CUDA memory, when only ~3 of that is allocated. |
I've run gradio app from repo and saw that CUDA memory grows rapidly from ~3 Gbs to ~12Gbs.
If i put small audio, it is also increasing, but not so much.
CUDA memory when i put small (1 second) audio file:
CUDA memory after putting long audio file (2.5 minutes):
Also, I've checked torch.cuda.memory_allocated() and it was constant, but torch.cuda.memory_cached() was increasing.
Maybe someone can explain me, why CUDA cache is growing?
The text was updated successfully, but these errors were encountered: