djiajunustc / TransVG

157 stars 26 forks source link

data pre #2

Closed OliverHuang1220 closed 3 years ago

OliverHuang1220 commented 3 years ago

Hi@djiajunustc You mention prepare the data following the README in ./data and ./ln_data folders.But this repository don't have it. If i should follow the installation steps in ReSC to prepare the data. Thanks for your reply!

djiajunustc commented 3 years ago

Sorry for that I wrongly add them into .gitignore. They are included now.

OliverHuang1220 commented 3 years ago

Thanks ! Now i begin to run the code.How long will it take when you train on the Refcoco/Refcoco+/Refcocog?

OliverHuang1220 commented 3 years ago

Hi@djiajunustc i have a error when i run the code.


Traceback (most recent call last): File "train.py", line 282, in main(args) File "train.py", line 239, in main args, model, data_loader_train, optimizer, device, epoch, args.clip_max_norm File "/home1/huangqiangHD/TransVG/engine.py", line 38, in train_one_epoch output = model(img_data, text_data) File "/home/huangqiang/.conda/envs/trans_vg/lib/python3.6/site-packages/torch/nn/modules/module.py", line 532, in call result = self.forward(*input, kwargs) File "/home1/huangqiangHD/TransVG/models/trans_vg.py", line 38, in forward visu_mask, visu_src = self.visumodel(img_data) File "/home/huangqiang/.conda/envs/trans_vg/lib/python3.6/site-packages/torch/nn/modules/module.py", line 532, in call result = self.forward(*input, *kwargs) File "/home1/huangqiangHD/TransVG/models/visual_model/detr.py", line 72, in forward out = self.transformer(self.input_proj(src), mask, pos[-1], query_embed=None) File "/home/huangqiang/.conda/envs/trans_vg/lib/python3.6/site-packages/torch/nn/modules/module.py", line 532, in call result = self.forward(input, kwargs) File "/home1/huangqiangHD/TransVG/models/visual_model/transformer.py", line 59, in forward query_embed = query_embed.unsqueeze(1).repeat(1, bs, 1) AttributeError: 'NoneType' object has no attribute 'unsqueeze'


I find 'query_embed' can only be equal to None ,not assigned elsewhere.So it cause this error.I've checked all the relevant dataset.