Scene-Graph-Benchmark.pytorch icon indicating copy to clipboard operation
Scene-Graph-Benchmark.pytorch copied to clipboard

IndexError: list index out of range

Open Ankit-Vohra opened this issue 5 years ago • 7 comments

❓ Questions and Help

I am facing this error while implementing SGGDet on custom images. Can you please help me with this?

File "/home/dell-7559/Scene-Graph-Benchmark.pytorch/maskrcnn_benchmark/data/datasets/visual_genome.py", line 63, in self.filenames = [self.filenames[i] for i in np.where(self.split_mask)[0]] IndexError: list index out of range

Ankit-Vohra avatar Aug 08 '20 18:08 Ankit-Vohra

I've just fixed this bug. You can directly comment out lines 52-64 in this file (visual_genome.py) to solve the issue.

KaihuaTang avatar Aug 10 '20 14:08 KaihuaTang

Hi Kai,

Thanks for the reply. I was also trying to debug the aforementioned issue.

I just wanted to know if we ever need to uncomment these lines while we finetune/train from scratch the model?

ajeetksingh avatar Aug 11 '20 05:08 ajeetksingh

❓ Questions and Help

I am facing this error while implementing SGGDet on custom images. Can you please help me with this?

File "/home/dell-7559/Scene-Graph-Benchmark.pytorch/maskrcnn_benchmark/data/datasets/visual_genome.py", line 63, in self.filenames = [self.filenames[i] for i in np.where(self.split_mask)[0]] IndexError: list index out of range

Hi, have you fixed this bug? #69

liuhl-source avatar Aug 13 '20 13:08 liuhl-source

My recent commit should fix the problem. https://github.com/KaihuaTang/Scene-Graph-Benchmark.pytorch/commit/81714a337ada463f428b2d0a1521730c5c597571

KaihuaTang avatar Aug 14 '20 03:08 KaihuaTang

My recent commit should fix the problem. 81714a3

Hi, I met the same problem, and I used the newest commit 1b955c6

File "/home/xxx/Project/Scene-Graph-Benchmark.pytorch/maskrcnn_benchmark/data/datasets/visual_genome.py", line 66, in self.filenames = [self.filenames[i] for i in np.where(self.split_mask)[0]] IndexError: list index out of range

YvonneZhao0305 avatar Oct 14 '20 08:10 YvonneZhao0305

My recent commit should fix the problem. 81714a3

Hi, I met the same problem, and I used the newest commit 1b955c6

File "/home/xxx/Project/Scene-Graph-Benchmark.pytorch/maskrcnn_benchmark/data/datasets/visual_genome.py", line 66, in self.filenames = [self.filenames[i] for i in np.where(self.split_mask)[0]] IndexError: list index out of range

Me too. Have you already soloved?

Sunting78 avatar Feb 01 '21 11:02 Sunting78

The new commint https://github.com/KaihuaTang/Scene-Graph-Benchmark.pytorch/commit/81714a337ada463f428b2d0a1521730c5c597571 does not resolve the problem for me? It seems that somewhere before the line 'data_loaders_val = make_data_loader(cfg, mode="test", is_distributed=distributed)' in tools/relation_test_net.py another dataloader of 'custom_eval False split train' is created.

winnechan avatar Nov 08 '21 10:11 winnechan