Watermark-Removal-Pytorch icon indicating copy to clipboard operation
Watermark-Removal-Pytorch copied to clipboard

[RuntimeError: CUDA out of memory] when max dimensions of final image are increased

Open VygintasC opened this issue 3 years ago • 0 comments

I am getting the following error when I increase the --max-dim parameter above 700 on a 6GiB GPU.

RuntimeError: CUDA out of memory. Tried to allocate 208.00 MiB (GPU 0; 6.00 GiB total capacity; 5.29 GiB already allocated; 0 bytes free; 5.33 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

I tried reducing the --input-depth to see if this would reduce the memory usage, but it didn't help.

Are there any other possible tweaks that would allow for processing of larger images?

VygintasC avatar Sep 06 '22 20:09 VygintasC