diff --git a/src/absinth.py b/src/absinth.py index 601f6103cdb4a33a7f574445ca7b44102ea1ef21..13aaa3db9503b969b5135a09e7d5a48011be6b46 100644 --- a/src/absinth.py +++ b/src/absinth.py @@ -608,10 +608,10 @@ def colour_graph(graph: nx.Graph, root_hub_list: list) -> nx.Graph: return graph -def disambiguate_colour(graph: nx.Graph, root_hub_list, context_list: list) -> dict: +def disambiguate_colour(graph: nx.Graph, root_hub_list: list, context_list: list) -> dict: """Clusters senses to root hubs using a coloured graph. - This algorithm colours the graph using (a method with a name i don't know) + This algorithm colours the graph using evolutionary graph theory and calculates scores for each root hub given a context based on this graph. Args: @@ -766,7 +766,7 @@ def disambiguate_mst(graph: nx.Graph, root_hub_list: list, pass # If disambiguator does not detect a sense, return singleton. - if np.max(score_array) == 0: + if any(score_array): pass