weakly_connected_components#

weakly_connected_components(graph, iter_count=None)#

Weakly connected components – partitions the graph into node sets which are mutually reachable by an undirected path

This function assigns a component id to each node such that nodes with the same component id are mutually reachable by an undirected path.

Parameters:
  • graph (GraphView) – Raphtory graph

  • iter_count (int, optional) – Maximum number of iterations to run. Note that this will terminate early if the labels converge prior to the number of iterations being reached.

Returns:

Mapping of nodes to their component ids.

Return type:

NodeStateUsize