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

Large memory consume #11

Open
ZhuFengdaaa opened this issue Mar 27, 2018 · 1 comment
Open

Large memory consume #11

ZhuFengdaaa opened this issue Mar 27, 2018 · 1 comment

Comments

@ZhuFengdaaa
Copy link

I have such warning pytorch-vqa/model.py:96: UserWarning: RNN module weights are not part of single contiguous chunk of memory. This means they need to be compacted at every call, possibly greatly increasing memory usage. To compact weights again call flatten_parameters().

Even though I use self.lstm.flatten_parameters() before _, (_, c) = self.lstm(packed), the programme consume almost all of my memory (16G), which is abnormal. In the issues before, you states that you can run epoch in 7 min, which I guess is because you have SSD.

Let's check the code to see what causes memory leak :)

@Cyanogenoid
Copy link
Owner

Are you running it on multiple GPUs? I've only seen that warning on that setup. Running it on 1 GPU, I get a usage of just under 3 GiB; on 2 GPUs, it goes up to a total of 4 GiB (~2 GiB each).
Are you sure that you have set up updated versions of PyTorch, CUDA and cuDNN correctly?

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