NeuralBabyTalk icon indicating copy to clipboard operation
NeuralBabyTalk copied to clipboard

can't find 'Type' in dataset

Open yueyueyu opened this issue 5 years ago • 4 comments

hi,when i run your code ,an error about the annotations of the COCO dataset is occurred as follow:

File "tools/coco-caption/pycocotools/coco.py", line 94, in createIndex if self.dataset['type'] == 'instances': KeyError: 'type'

i download COCO 2014 Train/Val annotation from the link . is there some mistake in the dataset? hepo to get your reply. thank you very much.

yueyueyu avatar Mar 19 '19 13:03 yueyueyu

Hello, I have the same problem. Have you solved it?

Enjiwonlar avatar Apr 15 '19 00:04 Enjiwonlar

me too! so how to solved it?

sue2415535899 avatar May 05 '19 00:05 sue2415535899

I have also encountered this error. So I checked the keys of 'instances_train2014.json' and 'instances_val2014.json', the keys are 'images', 'licenses', 'annotations', 'categories', 'info', no 'instances'. I directly commented the line " if self.dataset['type'] == 'instances' ".

dami23 avatar May 15 '19 14:05 dami23

I have also encountered this error. So I checked the keys of 'instances_train2014.json' and 'instances_val2014.json', the keys are 'images', 'licenses', 'annotations', 'categories', 'info', no 'instances'. I directly commented the line " if self.dataset['type'] == 'instances' ".

Hello,I commented the line " if self.dataset['type'] == 'instances' ",but when load other not instance file,there is no 'categories' image

Longcuirong avatar Jan 10 '20 06:01 Longcuirong