Open Au-LiuJY opened 1 week ago
I try to modify the function "select_timestep",line 754 to set "for index in range(0, 5)"-> for index in range(0, 3), And try to decrease the max_train_steps/max_f_train_steps or max_adv_train_steps, it also doesn't work.
When I run your demo--bash scripts/attack_timestep.sh ,OOM problems occurs.: torch.cuda.OutOfMemoryError: CUDA out of memory. Tried to allocate 256.00 MiB. GPU 0 has a total capacity of 23.69 GiB of which 69.94 MiB is free. Iuding non-PyTorch memory, this process has 23.61 GiB memory in use. Of the allocated memory 23.10 GiB is allocated by PyTorch, and 172.36 MiB is resed by PyTorch but unallocated. If reserved but unallocated memory is large try setting PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True to avoid frantation.
I use sd-v1.5,RTX3090,CUDA 11.8.The environment setting is the same as your readme.
I want to know how can I cut down the memory use to run the demo. Thanks in advance!