ruotianluo / Context-aware-ZSR

Official code for paper Context-aware Zero-shot Recognition (https://arxiv.org/abs/1904.09320 to appear at AAAI2020)
MIT License
58 stars 8 forks source link

Unable to download pretrained imagenet-model #2

Open buxpeng opened 4 years ago

buxpeng commented 4 years ago

hi ,When I download the pretrained imagenet-model according to the README.md, the connection fails all the time. Is the URL in it changed?

ruotianluo commented 4 years ago

interseting. Maybe the code breaks.

you can still download by enter in the url: https://docs.google.com/uc?export=download&id=1wHSvusQ1CiEMc5Nx5R8adqoHQjIDWXl1

you can replace id with other ids in that python file.

buxpeng commented 4 years ago

Thank you, there is another question, in which folder do I need to put the model downloaded according to the link? Download pretrained model from link in README.md

ruotianluo commented 4 years ago

a new directory called pretrained_model under the repo dir.

buxpeng commented 4 years ago

image Sorry, I mean you reproduce the model in your paper, not pretrained imagenet-model,Is for example this we_relt_geo_sc.pth file .

ruotianluo commented 4 years ago

a dir called pretrained. Checkout scripts/reproduce for clue.

buxpeng commented 4 years ago

thank you very much!

buxpeng commented 4 years ago

Hello, please disturb you again,When I run the test file, it shows that there is no the tagging_eval.pkl file,Does this file need to be downloaded? Where is it if downloaded? Thank you!

ruotianluo commented 4 years ago

no. it's the output of tools/test_net.py. i may put the path wrong. do you mind search a little bit where the tagging_eval.pkl is?

buxpeng commented 4 years ago

image sorry,i didn't find where the file was.

ruotianluo commented 4 years ago

Can you show me the full error log. And if possible can you run line by line in the script; and also what's your version of pytorch.

buxpeng commented 4 years ago

Do you have to use cuda to run? pytorch version is 1.0

ruotianluo commented 4 years ago

Yes, cuda is needed.

buxpeng commented 4 years ago

i know ,thank you very much!

buxpeng commented 4 years ago

image hi,When I run the test file (bash scripts/test/we_infer.sh).I got the above error.These two parameters load_ckpt and load_detectron in the run command are None,Can you look at it for me?

ruotianluo commented 4 years ago

You should run scripts/reproduce

buxpeng commented 4 years ago

image Hi,Do you need both python2 and python3? I'm installing python 3. Do commands like(In python 2 python lib/datasets/vg/convert_from_bansal.py) need to be executed?

ruotianluo commented 4 years ago

I used a conda environment to have both py2 and py3

buxpeng commented 4 years ago

I completed ( Convert from bansal train test split )using python2,but later compilation fails,My machine is ubantu18 cuda 9.0 gcc have 4.8 5.4 6 7,gcc version i have tried,Can you show it to me? image

buxpeng commented 4 years ago

sorry ,gcc have 4.8 5.5 6 7

ruotianluo commented 4 years ago

There is no change in this part compared to the original Detectron.pytorch. I suggest you go there and search for the solution.

buxpeng commented 4 years ago

Can you tell me which version of cuda and GCC you are using?

ruotianluo commented 4 years ago

gcc4.9.4 and cuda10

buxpeng commented 4 years ago

hi,I want to ask where this weight is downloaded? image

ruotianluo commented 4 years ago

Hi, I didn't provide that weight; I only provided the weight after conversion.

buxpeng commented 4 years ago

When I run this test file, I can't find the file. Can I ask if this file can be downloaded? image

image

ruotianluo commented 4 years ago

Have you trained the model by yourself?

buxpeng commented 4 years ago

no ,I am not going to train, I want to use the trained ones directly

ruotianluo commented 4 years ago

https://github.com/ruotianluo/Context-aware-ZSR#to-reproduce-numbers-in-the-paper

You need to run the scripts in scripts/reproduce.

buxpeng commented 4 years ago

Does everything need to be running? I have run the two inside image

ruotianluo commented 4 years ago

It depends on what you want?

buxpeng commented 4 years ago

I want to run this image

ruotianluo commented 4 years ago

that's gcn_infer and sync_infer

buxpeng commented 4 years ago

I have run gcn_infer in scripts/reproduce,But when I run this bash scripts/test/detection_gcn.sh ,Still without this weight ckpt/model_final_gcn_wn.pth image

ruotianluo commented 4 years ago

Sorry, my bad, now I understand. replace the load_ckpt in detection_gcn with the load_ckpt in gcn_infer same for sync.

buxpeng commented 4 years ago

Oh thanks,This is the result of my running bash scripts/test/we_infer.sh,Can you tell me what these numbers represent? image

ruotianluo commented 4 years ago

It corresponds to Table 1 GCN+Context row.

buxpeng commented 4 years ago

thanks,I want to put a picture now, and then use this zero sample to identify what I have seen and what I have n’t seen. Which file do I need to run?

ruotianluo commented 4 years ago

Not sure what you mean.

buxpeng commented 4 years ago

How can the 7794 pictures in the test set be modified into my own pictures?

ruotianluo commented 4 years ago

I haven't done this before. My guess is you need to create a coco annotation type json file for your own images.

If you want to test a single image. You may need to dig around. It shouldn't be too complicated, but it may take a few hours.

buxpeng commented 4 years ago

If I only want to test one picture, what do I need to modify?

ruotianluo commented 4 years ago

Try if you can extend from this function: https://github.com/ruotianluo/Context-aware-ZSR/blob/12c1d08ee0e85e38243528127aed79f2efad05b3/lib/core/test_engine.py#L222

But you still need to be able to run edgebox.

buxpeng commented 4 years ago

image hi,Can this file be replaced? Is it necessary to install matlab to run this?

ruotianluo commented 4 years ago

Unfortunately, it's necessary

buxpeng commented 4 years ago

oh,thanks,Is it okay to follow this instruction? image

ruotianluo commented 4 years ago

Yes.

buxpeng commented 4 years ago

Now need to install matlab, and then install this Matlab Toolbox?

ruotianluo commented 4 years ago

I think so.

buxpeng commented 4 years ago

image image hi,This score is not very clear, why some are greater than 1?

ruotianluo commented 4 years ago

I think it’s because the scores after the Crf is not normalized

Ruotian Luo

On Apr 17, 2020, at 9:23 AM, buxpeng notifications@github.com wrote:



hi,This score is not very clear, why some are greater than 1?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.