Giter Site home page Giter Site logo

plogicnet's Issues

Load data with different triples format

When you have a train dataset that entities contains ":" (for example, one entity could be an url) the program will crash since it is the character than the program use for adding the probability value to the entity.

#Save the predictions on test data
with open(local_path + '/pred_kge.txt', 'w') as fo:
    for h, r, t, f, rk, l in preds:
        fo.write('{}\t{}\t{}\t{}\t{}\n'.format(id2entity[h], id2relation[r], id2entity[t], f, rk))
        for e, val in l:
            fo.write('{}:{:.4f} '.format(id2entity[e], val))
            fo.write('\n')

So when the program try to split the value in order to evaluate the model, it will not split it properly and it will crash.

preds = [[pred.split(':')[0], float(pred.split(':')[1])] for pred in preds]

Maybe, I would recomend to change the character to another one since it can appear in url entities. Another option maybe would be try to select in a different way the probability value and the entity.

Python version?

Hello,

Could you mention what python version is supported for this code? I tried python3.7 and python2.7 both gave me the following error:

    **save_variable_list,
     ^
SyntaxError: invalid syntax

Thanks,
Harsha Kokel

How to understand the implementation of train_epoch function?

First of all, i want to make sure whether this repo is the official implementation of the paper?

According to the implementation of train_epoch:

I am really confused about how these formulas have been derived according to the paper. I look forward to your reply. Thanks

Where is the run.sh

Could you please explain the meaning of each term in the best_config.sh? Thanks!

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.