rentainhe / TRAR-VQA

[ICCV 2021] Official implementation of the paper "TRAR: Routing the Attention Spans in Transformers for Visual Question Answering"
MIT License
64 stars 18 forks source link

--weights_path ./weight/X-152.pth where download? #2

Open alice-cool opened 1 year ago

alice-cool commented 1 year ago

Dear scholar, I want to extract the 16 times 16 features using the ResNext152 described in your paper.

alice-cool commented 1 year ago

https://github.com/facebookresearch/grid-feats-vqa is it right?

alice-cool commented 1 year ago

When I INPUT "CUDA_VISIBLE_DEVICES=1 python extract_trar_grid_feature.py --config-file configs/X-152-grid.yaml --dataset coco_2015_test --weight_path ./weight/X-152.pth --output_dir ./data/" to extract from coco test2015.zip jpg. It throws the exception like the following:

raise KeyError( KeyError: "Dataset 'coco_2015_test' is not registered!

image When adding the code to fix it and entering a new window again, the error eliminates. image

But it didn't give any information about the number of instances over 80 categories.

alice-cool commented 1 year ago

image When using multiple GPUs to run the code, the code throws the exception like the above picture...

Now I did the following modifications: ①in train_egine.py image

②in test_egine.py Just narrow tab it. image

And the error eliminate. Because of the large scale input feature, the code is running for a long time....

rentainhe commented 1 year ago

https://github.com/facebookresearch/grid-feats-vqa is it right?

Yes, you can use this code to extract 16x16 features, and we have also released our feature-extraction code here: TRAR-Feature-Extraction, maybe you can extract 16x16 features by modifing the configs

rentainhe commented 1 year ago

Dear scholar, I want to extract the 16 times 16 features using the ResNext152 described in your paper.

Maybe you can download it by using this scripts:

wget https://dl.fbaipublicfiles.com/grid-feats-vqa/X-152/X-152.pth

I borrowed it from here: https://github.com/facebookresearch/grid-feats-vqa#pre-trained-models-and-features

alice-cool commented 1 year ago

Thanks for  your timely reply. I will try it now.

---原始邮件--- 发件人: "Ren @.> 发送时间: 2022年9月29日(星期四) 下午5:09 收件人: @.>; 抄送: @.**@.>; 主题: Re: [rentainhe/TRAR-VQA] --weights_path ./weight/X-152.pth wheredownload? (Issue #2)

https://github.com/facebookresearch/grid-feats-vqa is it right?

Yes, you can use this code to extract 16x16 features, and we have also released our feature-extraction code here: TRAR-Feature-Extraction, maybe you can extract 16x16 features by modifing the configs

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

rentainhe commented 1 year ago

When I INPUT "CUDA_VISIBLE_DEVICES=1 python extract_trar_grid_feature.py --config-file configs/X-152-grid.yaml --dataset coco_2015_test --weight_path ./weight/X-152.pth --output_dir ./data/" to extract from coco test2015.zip jpg. It throws the exception like the following:

raise KeyError( KeyError: "Dataset 'coco_2015_test' is not registered!

image When adding the code to fix it and entering a new window again, the error eliminates. image

But it didn't give any information about the number of instances over 80 categories.

I have no idea about this problem, cuz I think this may be specified settings in detectron2, I've try to extract GQA features using this code, however, it did not print the categories information too.

alice-cool commented 1 year ago

When I INPUT "CUDA_VISIBLE_DEVICES=1 python extract_trar_grid_feature.py --config-file configs/X-152-grid.yaml --dataset coco_2015_test --weight_path ./weight/X-152.pth --output_dir ./data/" to extract from coco test2015.zip jpg. It throws the exception like the following: raise KeyError( KeyError: "Dataset 'coco_2015_test' is not registered! image When adding the code to fix it and entering a new window again, the error eliminates. image But it didn't give any information about the number of instances over 80 categories.

I have no idea about this problem, cuz I think this may be specified settings in detectron2, I've try to extract GQA features using this code, however, it did not print the categories information too.

Thanks for your timely reply.

rentainhe commented 1 year ago

image When using multiple GPUs to run the code, the code throws the exception like the above picture...

Now I did the following modifications: ①in train_egine.py image

②in test_egine.py Just narrow tab it. image

And the error eliminate. Because of the large scale input feature, the code is running for a long time....

Thanks a lot! I've no idea if this is a bug in my code (cuz this code has not been updated for a long time), if this is a bug, would you like to submit a pull request to fix it ? : )