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

CUDA memory requirement #6

Closed
HeChengHui opened this issue Sep 20, 2023 · 5 comments
Closed

CUDA memory requirement #6

HeChengHui opened this issue Sep 20, 2023 · 5 comments

Comments

@HeChengHui
Copy link

@yxlu-0102
I would like to check what is the minimum vram to run this model. I have a 2070Super and running into OOM error.

    skip = torch.cat([x, skip], dim=1)
torch.cuda.OutOfMemoryError: CUDA out of memory. Tried to allocate 1.84 GiB (GPU 0; 8.00 GiB total capacity; 5.63 GiB already allocated; 455.00 MiB free; 5.65 GiB reserved in total by PyTorch) If reserved memory is >> allocated memory try setting max_split_size_mb to avoid fragmentation.  See documentation for Memory Management and PYTORCH_CUDA_ALLOC_CONF
@yxlu-0102
Copy link
Owner

I used two 3090ti GPUs to train the MP-SENet model, each with a memory size of 24 GB.

@HeChengHui
Copy link
Author

@yxlu-0102
Is it the same for inference?

@yxlu-0102
Copy link
Owner

One GPU with a memory size of 24 GB is enough for the inference process.

@HeChengHui
Copy link
Author

HeChengHui commented Sep 21, 2023

@yxlu-0102
I just tried inferencing on my 3090ti (24gb vram), and I am still getting OOM error. Is there a way to reduce the memory usage?

@yxlu-0102
Copy link
Owner

Due to the variable length of speech, the memory consumption for generating each speech is not fixed, and it doesn't depend on whether the GPU is a 3090 or not. It primarily depends on the amount of GPU memory you have.

During training, you can reduce GPU memory usage by adjusting the batch size and segment length, but this may have an impact on the training results.

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

No branches or pull requests

2 participants