Open TheLiao233 opened 1 month ago
We're sorry about the bugs due to a busy schedule and did not carefully check the uploaded code. We will soon update the repository to correct existing issues. Thanks again for your attention and the reminder about these problems.
Hello, thank you for your outstanding work and publishing the relevant code. I had some problems when I tried to use the command
python train.py --config configs/Retrieval_flickr_train.yaml --source_model ViT-B/16 --source_ckpt '/media/nlp/data/tl/model/vit'
to reproduce.The following error occurred when I set
os.environ["CUDA_VISIBLE_DEVICES"] = '0,1'
to runSo change
clamp_norm = torch.clamp(norm, self.min_norm, self.max_norm)
toclamp_norm = torch.clamp(norm, self.min_norm.to(norm.device), self.max_norm.to(norm.device))
But then the following problem occurred, so I removed the
self.method
from theloss_infoNCE = self.loss_func(adv_txt_embeds, img_embeds, txt2img, target_img_embeds, self.temperature,self.method)
Finally, I encountered the following problems, and then I tried to directly change
loss.backward()
toloss.backward(retain_graph=True)
, and finally the GPU memory overflowed, but no solution was found at present, I hope you can help me solve it, thank you very much!
Hello, Liao. We have fixed the minor bug and updated the code. Feel free to contact us if you have any further questions ~
Hello, thank you for your outstanding work and publishing the relevant code. I had some problems when I tried to use the command
python train.py --config configs/Retrieval_flickr_train.yaml --source_model ViT-B/16 --source_ckpt '/media/nlp/data/tl/model/vit'
to reproduce. The following error occurred when I setos.environ["CUDA_VISIBLE_DEVICES"] = '0,1'
to run So changeclamp_norm = torch.clamp(norm, self.min_norm, self.max_norm)
toclamp_norm = torch.clamp(norm, self.min_norm.to(norm.device), self.max_norm.to(norm.device))
But then the following problem occurred, so I removed theself.method
from theloss_infoNCE = self.loss_func(adv_txt_embeds, img_embeds, txt2img, target_img_embeds, self.temperature,self.method)
Finally, I encountered the following problems, and then I tried to directly changeloss.backward()
toloss.backward(retain_graph=True)
, and finally the GPU memory overflowed, but no solution was found at present, I hope you can help me solve it, thank you very much!Hello, Liao. We have fixed the minor bug and updated the code. Feel free to contact us if you have any further questions ~
Thank you very much for your reply, but when I run train.py
on ubuntu 24.04 with 2 RTX A6000 and 128G cpu memory,It often gets stuck at about one-third and causes the computer to freeze. What could be the reason? Could it be that the Flickr30k dataset is too large?
Hello, thank you for your outstanding work and publishing the relevant code. I had some problems when I tried to use the command
python train.py --config configs/Retrieval_flickr_train.yaml --source_model ViT-B/16 --source_ckpt '/media/nlp/data/tl/model/vit'
to reproduce. The following error occurred when I setos.environ["CUDA_VISIBLE_DEVICES"] = '0,1'
to run So changeclamp_norm = torch.clamp(norm, self.min_norm, self.max_norm)
toclamp_norm = torch.clamp(norm, self.min_norm.to(norm.device), self.max_norm.to(norm.device))
But then the following problem occurred, so I removed theself.method
from theloss_infoNCE = self.loss_func(adv_txt_embeds, img_embeds, txt2img, target_img_embeds, self.temperature,self.method)
Finally, I encountered the following problems, and then I tried to directly changeloss.backward()
toloss.backward(retain_graph=True)
, and finally the GPU memory overflowed, but no solution was found at present, I hope you can help me solve it, thank you very much!Hello, Liao. We have fixed the minor bug and updated the code. Feel free to contact us if you have any further questions ~
Thank you very much for your reply, but when I run
train.py
on ubuntu 24.04 with 2 RTX A6000 and 128G cpu memory,It often gets stuck at about one-third and causes the computer to freeze. What could be the reason? Could it be that the Flickr30k dataset is too large?
Sorry, we didn't not came across this issue in our experiments. Maybe you can take another GPU server to run the code.
Hello, thank you for your outstanding work and publishing the relevant code. I had some problems when I tried to use the command
python train.py --config configs/Retrieval_flickr_train.yaml --source_model ViT-B/16 --source_ckpt '/media/nlp/data/tl/model/vit'
to reproduce.The following error occurred when I set
os.environ["CUDA_VISIBLE_DEVICES"] = '0,1'
to runSo change
clamp_norm = torch.clamp(norm, self.min_norm, self.max_norm)
toclamp_norm = torch.clamp(norm, self.min_norm.to(norm.device), self.max_norm.to(norm.device))
But then the following problem occurred, so I removed the
self.method
from theloss_infoNCE = self.loss_func(adv_txt_embeds, img_embeds, txt2img, target_img_embeds, self.temperature,self.method)
Finally, I encountered the following problems, and then I tried to directly change
loss.backward()
toloss.backward(retain_graph=True)
, and finally the GPU memory overflowed, but no solution was found at present, I hope you can help me solve it, thank you very much!