Skip to content
Snippets Groups Projects
Commit eec1b67b authored by Fize Jacques's avatar Fize Jacques
Browse files

Update parameters theoric

parent 586701ad
No related branches found
No related tags found
No related merge requests found
...@@ -43,7 +43,7 @@ parameters = { ...@@ -43,7 +43,7 @@ parameters = {
}, },
"fast_gnp_random_graph": { "fast_gnp_random_graph": {
"n": GRAPH_SIZE, "n": GRAPH_SIZE,
"p": [0.1,0.4,0.6] "p": [0.4,0.6]
}, },
"random_powerlaw_tree_sequence": { # configuration_model "random_powerlaw_tree_sequence": { # configuration_model
"n": GRAPH_SIZE, "n": GRAPH_SIZE,
...@@ -55,12 +55,12 @@ parameters = { ...@@ -55,12 +55,12 @@ parameters = {
}, },
"waxman_graph": { "waxman_graph": {
"n": GRAPH_SIZE, "n": GRAPH_SIZE,
"beta": [0.1,0.4,0.6], "beta": [0.4,0.6],
"alpha": [0.1,0.4,0.6] "alpha": [0.4,0.6]
}, },
"geographical_threshold_graph": { "geographical_threshold_graph": {
"n": GRAPH_SIZE, "n": GRAPH_SIZE,
"theta": [0.1,0.2,0.3] "theta": [0.2,0.3]
}, },
} }
# Generating transition matrices for stochastic block model # Generating transition matrices for stochastic block model
...@@ -96,28 +96,3 @@ for method,args in pbar: ...@@ -96,28 +96,3 @@ for method,args in pbar:
# print(e) # print(e)
"""
nx.planted_partition_graph(5, 5, 0.8,
0.1) # nb of blocks, nb of vertices in each block, probability of link in block , prob. of link between blocks
nx.stochastic_block_model([5, 3, 6],
[[1, 0.1, 0.1], [0.1, 1, 0.1], [0.1, 0.1, 1]]) # sizes of blocks,probability between blocks
## Random Graph
nx.fast_gnp_random_graph(10, 0.5) # nb of nodes, prob of link
sequence = nx.random_powerlaw_tree_sequence(50, tries=500) # degree sequence
G = nx.configuration_model(sequence) # sequence
## Spatial graph
nx.random_geometric_graph(20, 0.5) # size of graph, max radius between edge connected
dist = lambda x, y: sum(abs(a - b) for a, b in zip(x, y)) # euclidian distance
G = nx.waxman_graph(50, 0.5, 0.1, metric=dist) # nb of nodes, beta, alpha
# beta -> the higher the parameter the higher the density is
# alpha -> the lower the higher the number of short edge is
G = nx.geographical_threshold_graph(20, 1, metric=dist) # nb of node, theta
# theta --> distance thresold
"""
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment