haseebs / OWE

Pytorch code for An Open-World Extension to Knowledge Graph Completion Models (AAAI 2019)
https://aaai.org/ojs/index.php/AAAI/article/view/4162
37 stars 9 forks source link

How to deal with IndexError: list index out of range #6

Closed mdabedr closed 4 years ago

mdabedr commented 4 years ago

This is what I am getting as error:

Traceback (most recent call last): File "run_closed_world.py", line 115, in main() File "run_closed_world.py", line 100, in main model.init_embeddings(dataset, model_dir) File "/......./OWE-master/owe/models/closed_world/transe.py", line 56, in init_embeddings for l in entity2id_file.open("rt")} File "/....../OWE-master/owe/models/closed_world/transe.py", line 56, in for l in entity2id_file.open("rt")} IndexError: list index out of range

villmow commented 4 years ago

Looks like your entity2id file is not on pair with your KGC model or you didn't specify one. Can you post the command you executed?