Fixing example clusters last commit.
This commit is contained in:
parent
3844c7025b
commit
51fb697690
|
@ -28,12 +28,16 @@ class ExampleClusters:
|
|||
for sense in model.entry.senses:
|
||||
for example in sense.examples:
|
||||
structure = example.get_structure()
|
||||
key = ExampleClusters.get_key(sense, example)
|
||||
cluster = example.get_cluster()
|
||||
|
||||
if cluster is None:
|
||||
continue
|
||||
|
||||
key = ExampleClusters.get_key(sense, example)
|
||||
if key not in self.lists:
|
||||
self.lists[key] = set()
|
||||
|
||||
self.lists[key].add(example.get_cluster())
|
||||
self.lists[key].add(cluster)
|
||||
|
||||
for key in self.lists.keys():
|
||||
self.lists[key] = sorted(self.lists[key], key=lambda x: x)
|
||||
|
|
Loading…
Reference in New Issue
Block a user