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

RuntimeError: CUDA out of memory. #14

Open
Hamzat0014 opened this issue Dec 2, 2021 · 1 comment
Open

RuntimeError: CUDA out of memory. #14

Hamzat0014 opened this issue Dec 2, 2021 · 1 comment

Comments

@Hamzat0014
Copy link

Hamzat0014 commented Dec 2, 2021

I am using GPU NVIDIA 2070 Super, when i run "python train_Mask-ShadowGAN" command its gives the following runtime error. Please guide me how to resolve.

RuntimeError: CUDA out of memory. Tried to allocate 39.12 MiB (GPU 0; 7.79 GiB total capacity; 6.27 GiB already allocated; 38.25 MiB free; 89.02 MiB cached)

if I don't do --n_cpu=1 it gives the error ValueError: signal number 32 out of range it

image

I reduce the batch size from 32 to 1 (use the different values) but the error is same.
I also tries to clear the cache but it didn't work as
import gc
gc.collect()
torch.cuda.empty_cache()

Please suggest me the solution. Thanks

@laoxie521
Copy link

me too

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