networkx 2.8.2 Pypi GitHub Homepage
Other Docs
ParametersReturns
_snap_split(groups, neighbor_info, group_lookup, group_id)

Splits the group with the given group_id based on the edge types of the nodes so that each new grouping will all have the same edges with other nodes.

Parameters

groups: dict :

A dictionary of unique group IDs and their corresponding node groups

neighbor_info: dict :

A data structure indicating the number of edges a node has with the groups in the current summarization of each edge type

edge_types: dict :

dictionary of edges in the graph and their corresponding attributes recognized in the summarization

group_lookup: dict :

dictionary of nodes and their current corresponding group ID

group_id: object :

ID of group to be split

Returns

dict

The updated groups based on the split

Splits a group based on edge types and updates the groups accordingly

Examples

See :

Local connectivity graph

Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.

Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)

SVG is more flexible but power hungry; and does not scale well to 50 + nodes.

All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them


GitHub : /networkx/algorithms/summarization.py#357
type: <class 'function'>
Commit: