From fee8b164f41f5da486b3bad49a564426a0d36a97 Mon Sep 17 00:00:00 2001 From: Luca Lombardo Date: Mon, 30 Jan 2023 18:57:28 +0100 Subject: [PATCH] fixed the random graph generator function --- utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utils.py b/utils.py index 376cfd8..184c6f1 100755 --- a/utils.py +++ b/utils.py @@ -512,9 +512,9 @@ def create_random_graphs(G: nx.Graph, model = None, save = True) -> nx.Graph: """ if model is None: - model = "erdos" + model = "erdos_renyi" - if model == "erdos": + if model == "erdos_renyi": G_random = nx.erdos_renyi_graph(G.number_of_nodes(), nx.density(G)) print("Creating a random graph with the Erdos-Renyi model {}" .format(G.name)) print("Number of edges in the original graph: {}" .format(G.number_of_edges()))