TakumaE / TorusE

TorusE

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TorusE

An embedding model onto a torus for knowledge graph completion.

Paper: TorusE: Knowledge Graph Embedding on a Lie Group

@inproceedings{TorusE,
  author    = {Takuma Ebisu and
               Ryutaro Ichise},
  title     = {TorusE: Knowledge Graph Embedding on a Lie Group},
  booktitle = {Proceedings of the Thirtieth {AAAI} Conference on Artificial Intelligence},
  year      = {2018},
}

Accuracy

Dataset MRR Hits@1 Hits@3 Hits@10
WN18 0.947 0.943 0.950 0.954
FB15k 0.747 0.690 0.785 0.840

The results on FB15k is slightly better than the results in the paper. This is because there was a bug with the eL2 distance function in the original implementation. According to fix, we retuned hyperparameters for FB15k.

Requirement

Tensorflow Numpy

Data Format

Datasets for this implementation should have three files named as following: train, valid, and test. You need to put under the directory, data/datasets_name/. Each line in these files represent a triple. For example, a line in a file, "son sibling_of daughter", represents the triple (son, sibling_of, daughter).

Example data are in data/example/.

Reproduction of the results

  1. Put the datasets WN18 and FB15k under ./data/wn18 and ./data/fb15k.

2a. run the following command for FB15k

python run.py -reproduce transe-fb15k

2b. run the following command for WN18

python run.py -reproduce transe-wn18

Acknowledgement

I really appreciate Phuc Nguyen. He helped me to reconstruct my code for readability.

About

TorusE

License:MIT License


Languages

Language:Python 100.0%