Exemple #1
0
def test_modularity_finetune_dir_low_modularity():
	x = load_directed_low_modularity_sample(thres=.67)
	seed = 39602351
	ci,oq = bct.modularity_louvain_dir(x, seed=seed)
	_,q = bct.modularity_finetune_dir(x, ci=ci, seed=seed)
	print q,oq
	assert q >= oq
Exemple #2
0
def test_modularity_finetune_dir():
	x = load_directed_sample()
	seed = 26080
	ci,oq = bct.modularity_louvain_dir(x, seed=seed)
	for i in xrange(100):
		_,q = bct.modularity_finetune_dir(x, ci=ci)
		print q,oq
		assert q >= oq