📜  networkx - 从图中删除小组件 - Python 代码示例
📅  最后修改于: 2022-03-11 14:45:33.830000             🧑  作者: Mango
代码示例1
for component in list(nx.connected_components(G)):
if len(component)<3:
for node in component:
G.remove_node(node)