Prune Recommender on Analyze

This commit is contained in:
Dominik Moritz Roth 2022-02-06 21:35:00 +01:00
parent 7c1585120e
commit ab97f8e390

View File

@ -883,6 +883,8 @@ def analyze(G, type_name, name, dist=2.7):
for n in list(G.nodes): for n in list(G.nodes):
if n not in menge: if n not in menge:
G.remove_node(n) G.remove_node(n)
if dist >= 2:
removeThinRecs(G, 2)
removeHighSpanTags(G, 12) removeHighSpanTags(G, 12)
if dist > 1: if dist > 1:
removeDangling(G, True) removeDangling(G, True)