ylqi / GL-RG

The code of IJCAI22 paper "GL-RG: Global-Local Representation Granularity for Video Captioning".
MIT License
17 stars 4 forks source link

Thank you for your amazing work! About the msrvtt_train_evalscores.pkl #8

Open tiesanguaixia opened 1 year ago

tiesanguaixia commented 1 year ago

Hi! Thank you for your amazing work! I want to ask how can I generate the _msrvtt_trainevalscores.pkl? I see the shape is [6513,20], so which caption is respectively corresponding to the every 20 scores of a video?

ylqi commented 1 year ago

Hi, Thank you for your interest in our work. Please refer to the commands in preprocess.sh to create the _msrvtt_trainevalscores.pkl.

tiesanguaixia commented 1 year ago

Hi, Thank you for your interest in our work. Please refer to the commands in preprocess.sh to create the _msrvtt_trainevalscores.pkl.

Hi, when I run such command, I notice that there is not a directory named output/metadata and there is not a cocofmt.json in it, so what should the cocofmt_file be like?

python compute_scores.py    --cocofmt_file output/metadata/${DATASET}_${SPLIT}_cocofmt.json\
                            --output_pkl output/metadata/${DATASET}_${SPLIT}_evalscores.pkl\
                            --remove_in_ref

And I encountered this error:

Traceback (most recent call last):
  File "data/preprocess/compute_scores.py", line 59, in <module>
    scorers = [(Bleu(), "Bleu_4"), (Meteor(), "METEOR"), (Rouge(), "ROUGE_L"), (Cider(), "CIDEr")]
TypeError: __init__() missing 1 required positional argument: 'df'

Do you have any advice? Thanks a lot!

ylqi commented 1 year ago

Hi, Thank you for your interest in our work. Please refer to the commands in preprocess.sh to create the _msrvtt_trainevalscores.pkl.

Hi, when I run such command, I notice that there is not a directory named output/metadata and there is not a cocofmt.json in it, so what should the cocofmt_file be like?

python compute_scores.py    --cocofmt_file output/metadata/${DATASET}_${SPLIT}_cocofmt.json\
                            --output_pkl output/metadata/${DATASET}_${SPLIT}_evalscores.pkl\
                            --remove_in_ref

And I encountered this error:

Traceback (most recent call last):
  File "data/preprocess/compute_scores.py", line 59, in <module>
    scorers = [(Bleu(), "Bleu_4"), (Meteor(), "METEOR"), (Rouge(), "ROUGE_L"), (Cider(), "CIDEr")]
TypeError: __init__() missing 1 required positional argument: 'df'

Do you have any advice? Thanks a lot!

Hi, the cocofmt_file is provided in /data/metadata, e.g., msrvtt_val_cocofmt.json. Those files are all created by preprocess.sh, using the official annotation files in data/preprocess/input.