You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

test_ged.py 20 kB

5 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531
  1. #export LD_LIBRARY_PATH=.:/export/home/lambertn/Documents/gedlibpy/lib/fann/:/export/home/lambertn/Documents/gedlibpy/lib/libsvm.3.22:/export/home/lambertn/Documents/gedlibpy/lib/nomad
  2. #Pour que "import script" trouve les librairies qu'a besoin GedLib
  3. #Equivalent à définir la variable d'environnement LD_LIBRARY_PATH sur un bash
  4. #import gedlibpy_linlin.librariesImport
  5. #from gedlibpy_linlin import gedlibpy
  6. from libs import *
  7. import networkx as nx
  8. import numpy as np
  9. from tqdm import tqdm
  10. import sys
  11. def test_NON_SYMBOLIC_cost():
  12. """Test edit cost LETTER2.
  13. """
  14. import sys
  15. sys.path.insert(0, "../")
  16. from preimage.ged import GED, get_nb_edit_operations_nonsymbolic, get_nb_edit_operations_letter
  17. from preimage.test_k_closest_graphs import reform_attributes
  18. from gklearn.utils.graphfiles import loadDataset
  19. dataset = '/media/ljia/DATA/research-repo/codes/Linlin/graphkit-learn/datasets/Letter-high/Letter-high_A.txt'
  20. Gn, y_all = loadDataset(dataset)
  21. g1 = Gn[200]
  22. g2 = Gn[1780]
  23. reform_attributes(g1)
  24. reform_attributes(g2)
  25. c_vi = 0.675
  26. c_vr = 0.675
  27. c_vs = 0.75
  28. c_ei = 0.425
  29. c_er = 0.425
  30. c_es = 0
  31. edit_cost_constant = [c_vi, c_vr, c_vs, c_ei, c_er, c_es]
  32. dis, pi_forward, pi_backward = GED(g1, g2, lib='gedlibpy',
  33. cost='NON_SYMBOLIC', method='IPFP', edit_cost_constant=edit_cost_constant,
  34. algo_options='', stabilizer=None)
  35. n_vi, n_vr, sod_vs, n_ei, n_er, sod_es = get_nb_edit_operations_nonsymbolic(g1, g2,
  36. pi_forward, pi_backward)
  37. print('# of operations:', n_vi, n_vr, sod_vs, n_ei, n_er, sod_es)
  38. print('c_vi, c_vr, c_vs, c_ei, c_er:', c_vi, c_vr, c_vs, c_ei, c_er, c_es)
  39. cost_computed = c_vi * n_vi + c_vr * n_vr + c_vs * sod_vs \
  40. + c_ei * n_ei + c_er * n_er + c_es * sod_es
  41. print('dis (cost computed by GED):', dis)
  42. print('cost computed by # of operations and edit cost constants:', cost_computed)
  43. def test_LETTER2_cost():
  44. """Test edit cost LETTER2.
  45. """
  46. import sys
  47. sys.path.insert(0, "../")
  48. from preimage.ged import GED, get_nb_edit_operations_letter
  49. from preimage.test_k_closest_graphs import reform_attributes
  50. from gklearn.utils.graphfiles import loadDataset
  51. ds = {'dataset': '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/data/collections/Letter.xml',
  52. 'graph_dir': '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/data/datasets/Letter/HIGH/'} # node/edge symb
  53. Gn, y_all = loadDataset(ds['dataset'], extra_params=ds['graph_dir'])
  54. g1 = Gn[200]
  55. g2 = Gn[1780]
  56. reform_attributes(g1)
  57. reform_attributes(g2)
  58. c_vi = 0.675
  59. c_vr = 0.675
  60. c_vs = 0.75
  61. c_ei = 0.425
  62. c_er = 0.425
  63. edit_cost_constant = [c_vi, c_vr, c_vs, c_ei, c_er]
  64. dis, pi_forward, pi_backward = GED(g1, g2, dataset='letter', lib='gedlibpy',
  65. cost='LETTER2', method='IPFP', edit_cost_constant=edit_cost_constant,
  66. algo_options='', stabilizer=None)
  67. n_vi, n_vr, n_vs, sod_vs, n_ei, n_er = get_nb_edit_operations_letter(g1, g2,
  68. pi_forward, pi_backward)
  69. print('# of operations:', n_vi, n_vr, n_vs, sod_vs, n_ei, n_er)
  70. print('c_vi, c_vr, c_vs, c_ei, c_er:', c_vi, c_vr, c_vs, c_ei, c_er)
  71. cost_computed = c_vi * n_vi + c_vr * n_vr + c_vs * sod_vs \
  72. + c_ei * n_ei + c_er * n_er
  73. print('dis (cost computed by GED):', dis)
  74. print('cost computed by # of operations and edit cost constants:', cost_computed)
  75. def test_get_nb_edit_operations_letter():
  76. """Test whether function preimage.ged.get_nb_edit_operations_letter returns
  77. correct numbers of edit operations. The distance/cost computed by GED
  78. should be the same as the cost computed by number of operations and edit
  79. cost constants.
  80. """
  81. import sys
  82. sys.path.insert(0, "../")
  83. from preimage.ged import GED, get_nb_edit_operations_letter
  84. from preimage.test_k_closest_graphs import reform_attributes
  85. from gklearn.utils.graphfiles import loadDataset
  86. ds = {'dataset': '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/data/collections/Letter.xml',
  87. 'graph_dir': '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/data/datasets/Letter/HIGH/'} # node/edge symb
  88. Gn, y_all = loadDataset(ds['dataset'], extra_params=ds['graph_dir'])
  89. g1 = Gn[200]
  90. g2 = Gn[1780]
  91. reform_attributes(g1)
  92. reform_attributes(g2)
  93. c_vir = 0.9
  94. c_eir = 1.7
  95. alpha = 0.75
  96. edit_cost_constant = [c_vir, c_eir, alpha]
  97. dis, pi_forward, pi_backward = GED(g1, g2, dataset='letter', lib='gedlibpy',
  98. cost='LETTER', method='IPFP', edit_cost_constant=edit_cost_constant,
  99. algo_options='', stabilizer=None)
  100. n_vi, n_vr, n_vs, c_vs, n_ei, n_er = get_nb_edit_operations_letter(g1, g2,
  101. pi_forward, pi_backward)
  102. print('# of operations and costs:', n_vi, n_vr, n_vs, c_vs, n_ei, n_er)
  103. print('c_vir, c_eir, alpha:', c_vir, c_eir, alpha)
  104. cost_computed = alpha * c_vir * (n_vi + n_vr) \
  105. + alpha * c_vs \
  106. + (1 - alpha) * c_eir * (n_ei + n_er)
  107. print('dis (cost computed by GED):', dis)
  108. print('cost computed by # of operations and edit cost constants:', cost_computed)
  109. def test_get_nb_edit_operations():
  110. """Test whether function preimage.ged.get_nb_edit_operations returns correct
  111. numbers of edit operations. The distance/cost computed by GED should be the
  112. same as the cost computed by number of operations and edit cost constants.
  113. """
  114. import sys
  115. sys.path.insert(0, "../")
  116. from preimage.ged import GED, get_nb_edit_operations
  117. from gklearn.utils.graphfiles import loadDataset
  118. ds = {'dataset': '../datasets/monoterpenoides/dataset_10+.ds',
  119. 'graph_dir': '/media/ljia/DATA/research-repo/codes/Linlin/graphkit-learn/datasets/monoterpenoides/'} # node/edge symb
  120. Gn, y_all = loadDataset(ds['dataset'])
  121. g1 = Gn[20]
  122. g2 = Gn[108]
  123. c_vi = 3
  124. c_vr = 3
  125. c_vs = 1
  126. c_ei = 3
  127. c_er = 3
  128. c_es = 1
  129. edit_cost_constant = [c_vi, c_vr, c_vs, c_ei, c_er, c_es]
  130. dis, pi_forward, pi_backward = GED(g1, g2, dataset='monoterpenoides', lib='gedlibpy',
  131. cost='CONSTANT', method='IPFP', edit_cost_constant=edit_cost_constant,
  132. algo_options='', stabilizer=None)
  133. n_vi, n_vr, n_vs, n_ei, n_er, n_es = get_nb_edit_operations(g1, g2,
  134. pi_forward, pi_backward)
  135. print('# of operations and costs:', n_vi, n_vr, n_vs, n_ei, n_er, n_es)
  136. print('edit costs:', c_vi, c_vr, c_vs, c_ei, c_er, c_es)
  137. cost_computed = n_vi * c_vi + n_vr * c_vr + n_vs * c_vs \
  138. + n_ei * c_ei + n_er * c_er + n_es * c_es
  139. print('dis (cost computed by GED):', dis)
  140. print('cost computed by # of operations and edit cost constants:', cost_computed)
  141. def test_ged_python_bash_cpp():
  142. """Test ged computation with python invoking the c++ code by bash command (with updated library).
  143. """
  144. sys.path.insert(0, "../")
  145. from gklearn.utils.graphfiles import loadDataset
  146. from preimage.ged import GED
  147. data_dir_prefix = '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/'
  148. # collection_file = data_dir_prefix + 'generated_datsets/monoterpenoides/gxl/monoterpenoides.xml'
  149. collection_file = data_dir_prefix + 'generated_datsets/monoterpenoides/monoterpenoides_3_20.xml'
  150. graph_dir = data_dir_prefix +'generated_datsets/monoterpenoides/gxl/'
  151. Gn, y = loadDataset(collection_file, extra_params=graph_dir)
  152. algo_options = '--threads 8 --initial-solutions 40 --ratio-runs-from-initial-solutions 1'
  153. for repeat in range(0, 3):
  154. # Generate the result file.
  155. ged_filename = data_dir_prefix + 'output/test_ged/ged_mat_python_bash_' + str(repeat) + '_init40.3_20.txt'
  156. # runtime_filename = data_dir_prefix + 'output/test_ged/runtime_mat_python_min_' + str(repeat) + '.txt'
  157. ged_file = open(ged_filename, 'a')
  158. # runtime_file = open(runtime_filename, 'a')
  159. ged_mat = np.empty((len(Gn), len(Gn)))
  160. # runtime_mat = np.empty((len(Gn), len(Gn)))
  161. for i in tqdm(range(len(Gn)), desc='computing GEDs', file=sys.stdout):
  162. for j in range(len(Gn)):
  163. print(i, j)
  164. g1 = Gn[i]
  165. g2 = Gn[j]
  166. upper_bound, _, _ = GED(g1, g2, lib='gedlib-bash', cost='CONSTANT',
  167. method='IPFP',
  168. edit_cost_constant=[3.0, 3.0, 1.0, 3.0, 3.0, 1.0],
  169. algo_options=algo_options)
  170. # runtime = gedlibpy.get_runtime(g1, g2)
  171. ged_mat[i][j] = upper_bound
  172. # runtime_mat[i][j] = runtime
  173. # Write to files.
  174. ged_file.write(str(int(upper_bound)) + ' ')
  175. # runtime_file.write(str(runtime) + ' ')
  176. ged_file.write('\n')
  177. # runtime_file.write('\n')
  178. ged_file.close()
  179. # runtime_file.close()
  180. print('ged_mat')
  181. print(ged_mat)
  182. # print('runtime_mat:')
  183. # print(runtime_mat)
  184. return
  185. def test_ged_best_settings_updated():
  186. """Test ged computation with best settings the same as in the C++ code (with updated library).
  187. """
  188. data_dir_prefix = '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/'
  189. collection_file = data_dir_prefix + 'generated_datsets/monoterpenoides/gxl/monoterpenoides.xml'
  190. # collection_file = data_dir_prefix + 'generated_datsets/monoterpenoides/monoterpenoides_3_20.xml'
  191. graph_dir = data_dir_prefix +'generated_datsets/monoterpenoides/gxl/'
  192. algo_options = '--threads 8 --initial-solutions 40 --ratio-runs-from-initial-solutions 1'
  193. for repeat in range(0, 3):
  194. # Generate the result file.
  195. ged_filename = data_dir_prefix + 'output/test_ged/ged_mat_python_updated_' + str(repeat) + '_init40.txt'
  196. runtime_filename = data_dir_prefix + 'output/test_ged/runtime_mat_python_updated_' + str(repeat) + '_init40.txt'
  197. gedlibpy.restart_env()
  198. gedlibpy.load_GXL_graphs(graph_dir, collection_file)
  199. listID = gedlibpy.get_all_graph_ids()
  200. gedlibpy.set_edit_cost('CONSTANT', [3.0, 3.0, 1.0, 3.0, 3.0, 1.0])
  201. gedlibpy.init()
  202. gedlibpy.set_method("IPFP", algo_options)
  203. gedlibpy.init_method()
  204. ged_mat = np.empty((len(listID), len(listID)))
  205. runtime_mat = np.empty((len(listID), len(listID)))
  206. for i in tqdm(range(len(listID)), desc='computing GEDs', file=sys.stdout):
  207. ged_file = open(ged_filename, 'a')
  208. runtime_file = open(runtime_filename, 'a')
  209. for j in range(len(listID)):
  210. g1 = listID[i]
  211. g2 = listID[j]
  212. gedlibpy.run_method(g1, g2)
  213. upper_bound = gedlibpy.get_upper_bound(g1, g2)
  214. runtime = gedlibpy.get_runtime(g1, g2)
  215. ged_mat[i][j] = upper_bound
  216. runtime_mat[i][j] = runtime
  217. # Write to files.
  218. ged_file.write(str(int(upper_bound)) + ' ')
  219. runtime_file.write(str(runtime) + ' ')
  220. ged_file.write('\n')
  221. runtime_file.write('\n')
  222. ged_file.close()
  223. runtime_file.close()
  224. print('ged_mat')
  225. print(ged_mat)
  226. print('runtime_mat:')
  227. print(runtime_mat)
  228. return
  229. def test_ged_best_settings():
  230. """Test ged computation with best settings the same as in the C++ code.
  231. """
  232. data_dir_prefix = '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/'
  233. collection_file = data_dir_prefix + 'generated_datsets/monoterpenoides/gxl/monoterpenoides.xml'
  234. graph_dir = data_dir_prefix +'generated_datsets/monoterpenoides/gxl/'
  235. algo_options = '--threads 6 --initial-solutions 10 --ratio-runs-from-initial-solutions .5'
  236. for repeat in range(0, 3):
  237. # Generate the result file.
  238. ged_filename = data_dir_prefix + 'output/test_ged/ged_mat_python_best_settings_' + str(repeat) + '.txt'
  239. runtime_filename = data_dir_prefix + 'output/test_ged/runtime_mat_python_best_settings_' + str(repeat) + '.txt'
  240. ged_file = open(ged_filename, 'a')
  241. runtime_file = open(runtime_filename, 'a')
  242. gedlibpy.restart_env()
  243. gedlibpy.load_GXL_graphs(graph_dir, collection_file)
  244. listID = gedlibpy.get_all_graph_ids()
  245. gedlibpy.set_edit_cost('CONSTANT', [3.0, 3.0, 1.0, 3.0, 3.0, 1.0])
  246. gedlibpy.init()
  247. gedlibpy.set_method("IPFP", algo_options)
  248. gedlibpy.init_method()
  249. ged_mat = np.empty((len(listID), len(listID)))
  250. runtime_mat = np.empty((len(listID), len(listID)))
  251. for i in tqdm(range(len(listID)), desc='computing GEDs', file=sys.stdout):
  252. for j in range(len(listID)):
  253. g1 = listID[i]
  254. g2 = listID[j]
  255. gedlibpy.run_method(g1, g2)
  256. upper_bound = gedlibpy.get_upper_bound(g1, g2)
  257. runtime = gedlibpy.get_runtime(g1, g2)
  258. ged_mat[i][j] = upper_bound
  259. runtime_mat[i][j] = runtime
  260. # Write to files.
  261. ged_file.write(str(int(upper_bound)) + ' ')
  262. runtime_file.write(str(runtime) + ' ')
  263. ged_file.write('\n')
  264. runtime_file.write('\n')
  265. ged_file.close()
  266. runtime_file.close()
  267. print('ged_mat')
  268. print(ged_mat)
  269. print('runtime_mat:')
  270. print(runtime_mat)
  271. return
  272. def test_ged_default():
  273. """Test ged computation with default settings.
  274. """
  275. data_dir_prefix = '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/'
  276. collection_file = data_dir_prefix + 'generated_datsets/monoterpenoides/gxl/monoterpenoides.xml'
  277. graph_dir = data_dir_prefix +'generated_datsets/monoterpenoides/gxl/'
  278. for repeat in range(3):
  279. # Generate the result file.
  280. ged_filename = data_dir_prefix + 'output/test_ged/ged_mat_python_default_' + str(repeat) + '.txt'
  281. runtime_filename = data_dir_prefix + 'output/test_ged/runtime_mat_python_default_' + str(repeat) + '.txt'
  282. ged_file = open(ged_filename, 'a')
  283. runtime_file = open(runtime_filename, 'a')
  284. gedlibpy.restart_env()
  285. gedlibpy.load_GXL_graphs(graph_dir, collection_file)
  286. listID = gedlibpy.get_all_graph_ids()
  287. gedlibpy.set_edit_cost('CONSTANT', [3.0, 3.0, 1.0, 3.0, 3.0, 1.0])
  288. gedlibpy.init()
  289. gedlibpy.set_method("IPFP", "")
  290. gedlibpy.init_method()
  291. ged_mat = np.empty((len(listID), len(listID)))
  292. runtime_mat = np.empty((len(listID), len(listID)))
  293. for i in tqdm(range(len(listID)), desc='computing GEDs', file=sys.stdout):
  294. for j in range(len(listID)):
  295. g1 = listID[i]
  296. g2 = listID[j]
  297. gedlibpy.run_method(g1, g2)
  298. upper_bound = gedlibpy.get_upper_bound(g1, g2)
  299. runtime = gedlibpy.get_runtime(g1, g2)
  300. ged_mat[i][j] = upper_bound
  301. runtime_mat[i][j] = runtime
  302. # Write to files.
  303. ged_file.write(str(int(upper_bound)) + ' ')
  304. runtime_file.write(str(runtime) + ' ')
  305. ged_file.write('\n')
  306. runtime_file.write('\n')
  307. ged_file.close()
  308. runtime_file.close()
  309. print('ged_mat')
  310. print(ged_mat)
  311. print('runtime_mat:')
  312. print(runtime_mat)
  313. return
  314. def test_ged_min():
  315. """Test ged computation with the "min" stabilizer.
  316. """
  317. sys.path.insert(0, "../")
  318. from gklearn.utils.graphfiles import loadDataset
  319. from preimage.ged import GED
  320. data_dir_prefix = '/media/ljia/DATA/research-repo/codes/others/gedlib/tests_linlin/'
  321. collection_file = data_dir_prefix + 'generated_datsets/monoterpenoides/gxl/monoterpenoides.xml'
  322. graph_dir = data_dir_prefix +'generated_datsets/monoterpenoides/gxl/'
  323. Gn, y = loadDataset(collection_file, extra_params=graph_dir)
  324. # algo_options = '--threads 6 --initial-solutions 10 --ratio-runs-from-initial-solutions .5'
  325. for repeat in range(0, 3):
  326. # Generate the result file.
  327. ged_filename = data_dir_prefix + 'output/test_ged/ged_mat_python_min_' + str(repeat) + '.txt'
  328. # runtime_filename = data_dir_prefix + 'output/test_ged/runtime_mat_python_min_' + str(repeat) + '.txt'
  329. ged_file = open(ged_filename, 'a')
  330. # runtime_file = open(runtime_filename, 'a')
  331. ged_mat = np.empty((len(Gn), len(Gn)))
  332. # runtime_mat = np.empty((len(Gn), len(Gn)))
  333. for i in tqdm(range(len(Gn)), desc='computing GEDs', file=sys.stdout):
  334. for j in range(len(Gn)):
  335. g1 = Gn[i]
  336. g2 = Gn[j]
  337. upper_bound, _, _ = GED(g1, g2, lib='gedlibpy', cost='CONSTANT',
  338. method='IPFP',
  339. edit_cost_constant=[3.0, 3.0, 1.0, 3.0, 3.0, 1.0],
  340. stabilizer='min', repeat=10)
  341. # runtime = gedlibpy.get_runtime(g1, g2)
  342. ged_mat[i][j] = upper_bound
  343. # runtime_mat[i][j] = runtime
  344. # Write to files.
  345. ged_file.write(str(int(upper_bound)) + ' ')
  346. # runtime_file.write(str(runtime) + ' ')
  347. ged_file.write('\n')
  348. # runtime_file.write('\n')
  349. ged_file.close()
  350. # runtime_file.close()
  351. print('ged_mat')
  352. print(ged_mat)
  353. # print('runtime_mat:')
  354. # print(runtime_mat)
  355. return
  356. def init() :
  357. print("List of Edit Cost Options : ")
  358. for i in gedlibpy.list_of_edit_cost_options :
  359. print (i)
  360. print("")
  361. print("List of Method Options : ")
  362. for j in gedlibpy.list_of_method_options :
  363. print (j)
  364. print("")
  365. print("List of Init Options : ")
  366. for k in gedlibpy.list_of_init_options :
  367. print (k)
  368. print("")
  369. def convertGraph(G):
  370. G_new = nx.Graph()
  371. for nd, attrs in G.nodes(data=True):
  372. G_new.add_node(str(nd), chem=attrs['atom'])
  373. for nd1, nd2, attrs in G.edges(data=True):
  374. G_new.add_edge(str(nd1), str(nd2), valence=attrs['bond_type'])
  375. return G_new
  376. def testNxGrapĥ():
  377. import sys
  378. sys.path.insert(0, "../")
  379. from gklearn.utils.graphfiles import loadDataset
  380. ds = {'name': 'MUTAG', 'dataset': '../datasets/MUTAG/MUTAG_A.txt',
  381. 'extra_params': {}} # node/edge symb
  382. Gn, y_all = loadDataset(ds['dataset'], extra_params=ds['extra_params'])
  383. gedlibpy.restart_env()
  384. for graph in Gn:
  385. g_new = convertGraph(graph)
  386. gedlibpy.add_nx_graph(g_new, "")
  387. listID = gedlibpy.get_all_graph_ids()
  388. gedlibpy.set_edit_cost("CHEM_1")
  389. gedlibpy.init()
  390. gedlibpy.set_method("IPFP", "")
  391. gedlibpy.init_method()
  392. print(listID)
  393. g = listID[0]
  394. h = listID[1]
  395. gedlibpy.run_method(g, h)
  396. print("Node Map : ", gedlibpy.get_node_map(g, h))
  397. print("Forward map : " , gedlibpy.get_forward_map(g, h), ", Backward map : ", gedlibpy.get_backward_map(g, h))
  398. print ("Upper Bound = " + str(gedlibpy.get_upper_bound(g, h)) + ", Lower Bound = " + str(gedlibpy.get_lower_bound(g, h)) + ", Runtime = " + str(gedlibpy.get_runtime(g, h)))
  399. if __name__ == '__main__':
  400. # test_ged_default()
  401. # test_ged_min()
  402. # test_ged_best_settings()
  403. # test_ged_best_settings_updated()
  404. # test_ged_python_bash_cpp()
  405. # test_get_nb_edit_operations()
  406. # test_get_nb_edit_operations_letter()
  407. # test_LETTER2_cost()
  408. test_NON_SYMBOLIC_cost()
  409. #init()
  410. #testNxGrapĥ()

A Python package for graph kernels, graph edit distances and graph pre-image problem.