XPixelGroup / DiffBIR

Official codes of DiffBIR: Towards Blind Image Restoration with Generative Diffusion Prior
Apache License 2.0
3.24k stars 272 forks source link

cuda out of memory,跑这个模型需要多大显存? #125

Open wsl1999 opened 2 months ago

wsl1999 commented 2 months ago

刚下载模型,超分 input 文件夹里的样例图片都爆显存了。。。 想问一下这个问题怎么解决? 3060 laptop 6G显存 运行命令报错: torch.cuda.OutOfMemoryError: CUDA out of memory. Tried to allocate 1024.00 MiB. GPU 0 has a total capacity of 6.00 GiB of which 0 bytes is free. Of the allocated memory 10.07 GiB is allocated by PyTorch, and 662.61 MiB is reserved by PyTorch but unallocated. If reserved but unallocated memory is large try setting PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True to avoid fragmentation. See documentation for Memory Management (https://pytorch.org/docs/stable/notes/cuda.html#environment-variables) bash: --device: command not found

wsl1999 commented 2 months ago

bash: --device: command not found 这行报错是什么原因?如何解决?