removing old unused commented out code
This commit is contained in:
parent
68c22d4e27
commit
bf0ed35e00
26
wani.py
26
wani.py
|
@ -1358,14 +1358,6 @@ class StructureMatch:
|
||||||
dm.add(" ".join(words[k].text for k in keys))
|
dm.add(" ".join(words[k].text for k in keys))
|
||||||
return len(dm)
|
return len(dm)
|
||||||
|
|
||||||
# def distinct_2w_forms(self, jppb):
|
|
||||||
# dm = set()
|
|
||||||
# for words in self.matches:
|
|
||||||
# cw1 = words[jppb[0]]
|
|
||||||
# cw2 = words[jppb[1]]
|
|
||||||
# dm.add((cw1.text, cw2.text))
|
|
||||||
# return len(dm)
|
|
||||||
|
|
||||||
def append(self, match):
|
def append(self, match):
|
||||||
self.matches.append(match)
|
self.matches.append(match)
|
||||||
|
|
||||||
|
@ -1398,18 +1390,6 @@ class ColocationIds:
|
||||||
|
|
||||||
yield sm
|
yield sm
|
||||||
|
|
||||||
# all_words = []
|
|
||||||
# more_data = []
|
|
||||||
|
|
||||||
# for words in sm.matches:
|
|
||||||
# more_data.append((sm.match_id, words, len(sm), sm.representations))
|
|
||||||
# all_words.append(words)
|
|
||||||
|
|
||||||
# if group:
|
|
||||||
# more_data = more_data[:1]
|
|
||||||
|
|
||||||
# yield all_words, more_data
|
|
||||||
|
|
||||||
def set_representations(self, word_renderer):
|
def set_representations(self, word_renderer):
|
||||||
for _1, sm in tqdm(self.data.items()):
|
for _1, sm in tqdm(self.data.items()):
|
||||||
ComponentRendition.set_representations(sm, word_renderer)
|
ComponentRendition.set_representations(sm, word_renderer)
|
||||||
|
@ -1444,12 +1424,6 @@ def main(structures_file, args):
|
||||||
colocation_ids = ColocationIds()
|
colocation_ids = ColocationIds()
|
||||||
word_renderer = WordMsdRenderer(lemma_msds)
|
word_renderer = WordMsdRenderer(lemma_msds)
|
||||||
|
|
||||||
# if True:
|
|
||||||
# with open("match_word.p", "rb") as fp:
|
|
||||||
# words, matches = pickle.load(fp)
|
|
||||||
# colocation_ids.add_matches(matches)
|
|
||||||
# word_renderer.add_words(words)
|
|
||||||
|
|
||||||
if args.parallel:
|
if args.parallel:
|
||||||
num_parallel = int(args.parallel)
|
num_parallel = int(args.parallel)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user