def test_agdl(self):
     g = get_string_graph()
     coms = algorithms.agdl(g, 3, 2, 2, 0.5)
     self.assertEqual(type(coms.communities), list)
     if len(coms.communities) > 0:
         self.assertEqual(type(coms.communities[0]), list)
         self.assertEqual(type(coms.communities[0][0]), str)
Beispiel #2
0
 def agdl(n_coms, nn, kc, a) : return lambda G : algorithms.agdl(G, n_coms, nn, kc, a)
 algos['agdl'] = [agdl(len(c), 3, 4, 1) for c in lfr_comms]