test
This commit is contained in:
parent
975a0a77c2
commit
2637f53848
1
main.py
1
main.py
@ -91,6 +91,7 @@ class Main(object):
|
|||||||
for line in open('./data/{}/{}'.format(self.p.dataset, "relations.dict")):
|
for line in open('./data/{}/{}'.format(self.p.dataset, "relations.dict")):
|
||||||
id, rel = map(str.lower, line.strip().split('\t'))
|
id, rel = map(str.lower, line.strip().split('\t'))
|
||||||
self.rel2id[rel] = int(id)
|
self.rel2id[rel] = int(id)
|
||||||
|
rel_set.add(rel)
|
||||||
|
|
||||||
# self.ent2id = {ent: idx for idx, ent in enumerate(ent_set)}
|
# self.ent2id = {ent: idx for idx, ent in enumerate(ent_set)}
|
||||||
# self.rel2id = {rel: idx for idx, rel in enumerate(rel_set)}
|
# self.rel2id = {rel: idx for idx, rel in enumerate(rel_set)}
|
||||||
|
Loading…
Reference in New Issue
Block a user