import networkx as nx
import matplotlib.pyplot as plt
def get_K_sehll(G):
# 为了不改变原图
graph = G.copy()
k_shells = []
# k从最小度开始
degrees = (graph.degree[n] for n in graph.nodes())
k = min(degrees
k-shell的python实现
最新推荐文章于 2021-06-08 09:22:09 发布