Memory leak when built from source

I’ve run into memory leak issues when running various projects (semantic segmentation w/ CUDA and CPU-only RL) after building PyTorch from source. This has been an issue for me (Ubuntu 14.04, CUDA 8.0, Python 3.6 via conda) and a colleague (Ubuntu 16.04, no CUDA, Python 3.6 via conda). I’ve tried building from master from several commits, and from the last tagged release (0.1.12), but no difference. Using the conda install works absolutely fine. Any ideas on what to look out for/help me provide more information?

1 Like

Could you share a script to replicate the memory leak, please ? I’ve had some issues like that as well, but not quite sure it comes from compiling from sources. I’d be interested to see if we can pin point what leaks.

Unfortunately I don’t have a minimal script to reproduce it, but have experienced when running the code in the open source projects that I’ve linked above. They are relatively complex, although the segmentation code is not so bad.