Giter Site home page Giter Site logo

repro-ea-ued's Introduction

UED

Code and data for "An Accurate Unsupervised Method for Joint Entity Alignment and Dangling Entity Detection".

Usage

Training and local alignment:
--mt_pair: use pseudo pairs
--mt_anchor_weight: use globally guided loss
--weight_decay: the weight decreasing mechanism of globally guided loss
--data: path of data, e.g.: ./data/DBP15K or ./data/MedED
--rate: #training_pairs / (#training_pairs + #testing_pairs)
--cuda: gpu or cpu

example 1:
python UED.py --mt_pair --mt_anchor_weight --weight_decay --lang zh_en --data ./data/DBP15K --rate 0.3 --cuda
example 2:
python UED.py --mt_pair --mt_anchor_weight --weight_decay --lang es_en --data ./data/MedED --rate 0.3

For the hyper-parameters, you can tune the hyper-parameters on the obtained pseudo entity pairs as the pseudo learning labels by generate more pseudo entity pairs with a lower threshold.

Global alignment method and testing:
python OTP.py --log_path train_logmt_pair_mt_anchor_weight_weight_decay_rate0.3 --lang zh_en --data ./data/DBP15K --rate 0.3

Datasets:

a. For DBP15K, we add mt_pair99, mt_sim_topK3 to the dataset we inherit from previous works (See ./data and our paper for details).

b. For MedED, due to copyright of UMLS, if you need to obtain the real information of the entity and relationship, or construct KGs of other sizes, please download UMLS (version=2019ab, at https://www.nlm.nih.gov/research/umls/archive/archive_home.html), and refer to our data generation code in ./data

requirement:

apex
pytorch >= 1.7.1
torch_geometric >= 1.7.0
torch_sparse >= 0.6.9
mip >= 1.13.0

repro-ea-ued's People

Contributors

luosx18 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.