SwinIR icon indicating copy to clipboard operation
SwinIR copied to clipboard

The noise removal command eats up my entire RAM and then gets killed

Open Sandjan opened this issue 1 year ago • 6 comments

I have 64GB RAM and 30GB swap but when I run the following command:
python main_test_swinir.py --task colour_dn --noise 15 --model_path model_zoo/swinir/005_colorDN_DFWB_s128w8_SwinIR-M_noise15.pth --folder_gt testsets/own

on a few pictures with 12megapixel first my ram is filled up, then the swap and then the program is killed by the system. I haven't tested what happens with smaller images, but I can't imagine it necessarily takes that much RAM.

Sandjan avatar Jul 26 '23 14:07 Sandjan

add to the startup command: --tile 400

it will turn out like this: python main_test_swinir.py --task colour_dn --noise 15 --model_path model_zoo/swinir/005_colorDN_DFWB_s128w8_SwinIR-M_noise15.pth --folder_gt testsets/own --tile 400

tell me, did you manage to solve the problem later?

OmlineEditor avatar Jan 08 '24 13:01 OmlineEditor

请问这个 tile参数是做什么用的 改变他会影响什么???

guoshuyu123 avatar Feb 01 '24 10:02 guoshuyu123

this option processes the image in chunks, small tiles and not all at once, it saves memory and there is no message about low RAM

OmlineEditor avatar Feb 01 '24 15:02 OmlineEditor

感谢你的告知 我还想问下这个参数400具体指些什么?

guoshuyu123 avatar Feb 03 '24 12:02 guoshuyu123

I do not know exactly what this parameter does inside the program, I know that this parameter helps to process large images without reporting a lack of memory. you need to ask the developer in more detail, but he does not seem to get in touch and is silent.

OmlineEditor avatar Feb 03 '24 14:02 OmlineEditor

这个参数是用来裁剪数据的,不会让显存随着输入图像变大而增加

babyta avatar Jun 20 '24 03:06 babyta