99032f5fffa1644cd73e51e99a7347160b83d028,examples/train_transh.py,,,#,5

Before Change


import json

con = config.Config()
con.set_test_flag(True)
con.set_in_path("./benchmarks/FB15K/")
con.set_out_path("./benchmarks/FB15K/a.vec")
// con.set_export_files("res.vec")
//con.set_import_files("res.vec")
// con.set_export_steps(10)
con.set_log_on(1)

After Change


con.set_rel_neg_rate(0)
con.set_opt_method("SGD")
//Model parameters will be exported via torch.save() automatically.
con.set_export_files("./res/transh.pt")
//Model parameters will be exported to json files automatically.
con.set_out_files("./res/transh.vec.json")
con.init()
con.set_model(models.TransH)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 6

Non-data size: 3

Instances


Project Name: thunlp/OpenKE
Commit Name: 99032f5fffa1644cd73e51e99a7347160b83d028
Time: 2018-03-10
Author: 1120991665@qq.com
File Name: examples/train_transh.py
Class Name:
Method Name:


Project Name: thunlp/OpenKE
Commit Name: 99032f5fffa1644cd73e51e99a7347160b83d028
Time: 2018-03-10
Author: 1120991665@qq.com
File Name: examples/train_distmult.py
Class Name:
Method Name:


Project Name: thunlp/OpenKE
Commit Name: 99032f5fffa1644cd73e51e99a7347160b83d028
Time: 2018-03-10
Author: 1120991665@qq.com
File Name: examples/train_complex.py
Class Name:
Method Name:


Project Name: thunlp/OpenKE
Commit Name: 99032f5fffa1644cd73e51e99a7347160b83d028
Time: 2018-03-10
Author: 1120991665@qq.com
File Name: examples/train_rescal.py
Class Name:
Method Name:


Project Name: thunlp/OpenKE
Commit Name: 99032f5fffa1644cd73e51e99a7347160b83d028
Time: 2018-03-10
Author: 1120991665@qq.com
File Name: examples/train_transd.py
Class Name:
Method Name:


Project Name: thunlp/OpenKE
Commit Name: 99032f5fffa1644cd73e51e99a7347160b83d028
Time: 2018-03-10
Author: 1120991665@qq.com
File Name: examples/train_transe.py
Class Name:
Method Name: