├── .gitignore ├── LICENSE.txt ├── README.md ├── qubo_nn ├── __init__.py ├── config.py ├── contrib │ ├── all_qubos.py │ ├── gg.py │ ├── m2sat_to_bip.py │ ├── non_reversible.py │ ├── rl.py │ ├── simulations.json │ └── sp.py ├── data.py ├── datasets │ └── .gitkeep ├── decision_tree.pickle ├── decision_tree.py ├── decision_tree2.pickle ├── decision_tree_inf.py ├── filling_level_diag.py ├── filling_level_zeros.py ├── gen_red_cfg.py ├── logger.py ├── main.py ├── models │ └── .gitkeep ├── nn │ ├── __init__.py │ └── models.py ├── noisy_similarity_algo.py ├── noisy_similarity_algo_all.py ├── noisy_similarity_algo_multi.py ├── noisy_similarity_algo_pairwise.py ├── noisy_similarity_algo_pairwise2.py ├── pipeline.py ├── plots │ ├── README.md │ ├── __init__.py │ ├── architecture.pdf │ ├── architecture.png │ ├── big_arch_generalized.pickle │ ├── big_arch_generalized_gc.pdf │ ├── big_arch_generalized_gc.png │ ├── big_arch_gi_sgi_mcq.pickle │ ├── big_arch_gi_sgi_mcq_gi.pdf │ ├── big_arch_gi_sgi_mcq_gi.png │ ├── big_arch_gi_sgi_mcq_mcq.pdf │ ├── big_arch_gi_sgi_mcq_mcq.png │ ├── big_arch_gi_sgi_mcq_sgi.pdf │ ├── big_arch_gi_sgi_mcq_sgi.png │ ├── big_arch_qa_np_sp_m2sat.pickle │ ├── big_arch_qa_np_sp_m2sat_m2sat.pdf │ ├── big_arch_qa_np_sp_m2sat_m2sat.png │ ├── big_arch_qa_np_sp_m2sat_np.pdf │ ├── big_arch_qa_np_sp_m2sat_np.png │ ├── big_arch_qa_np_sp_m2sat_qa.pdf │ ├── big_arch_qa_np_sp_m2sat_qa.png │ ├── big_arch_qa_np_sp_m2sat_sp.pdf │ ├── big_arch_qa_np_sp_m2sat_sp.png │ ├── confusion_100_genX_100_genX.pdf │ ├── confusion_100_genX_100_genX.png │ ├── confusion_27_noscramble_100k.pdf │ ├── confusion_27_noscramble_100k.png │ ├── confusion_27_scramble_100k.pdf │ ├── confusion_27_scramble_100k.png │ ├── confusion_30_gen4_30_gen4.pdf │ ├── confusion_30_gen4_30_gen4.png │ ├── confusion_30_gen4_30_gen4_scramble.pdf │ ├── confusion_30_gen4_30_gen4_scramble.png │ ├── confusion_gen4_27_gen4.pdf │ ├── confusion_gen4_27_gen4.png │ ├── confusion_gen4_27_gen4_scramble.pdf │ ├── confusion_gen4_27_gen4_scramble.png │ ├── def_a3.pickle │ ├── def_a3_a3_1.pdf │ ├── def_a3_a3_1.png │ ├── def_a3_a3_3.pdf │ ├── def_a3_a3_3.png │ ├── def_a3_a3ng.pdf │ ├── def_a3_a3ng.png │ ├── def_a3_a3ng_v2_e1.pdf │ ├── def_a3_a3ng_v2_e1.png │ ├── gc_matrix_large.pdf │ ├── gc_matrix_large.png │ ├── gc_matrix_small.pdf │ ├── gc_matrix_small.png │ ├── gen_big_arch_generalized.py │ ├── gen_big_arch_gi_sgi_mcq.py │ ├── gen_big_arch_qa_np_sp_m2sat.py │ ├── gen_def_a3.py │ ├── gen_gi_sgi_same.py │ ├── gen_large_arch_generalized.py │ ├── gen_m23sat.py │ ├── gen_m2sat_comp_pickle.py │ ├── gen_m2sat_three_case.py │ ├── gen_maxpool_comp.py │ ├── gen_mc_comp_edges.py │ ├── gen_np.py │ ├── gen_qa_comp.py │ ├── gen_qa_ones.py │ ├── gen_qa_zeros.py │ ├── gen_qb.py │ ├── gen_qk.py │ ├── gen_qubo_map_pickle.py │ ├── gen_red_ae.py │ ├── gen_reverse_loss_pickle.py │ ├── gen_sim.py │ ├── gen_sim_pair.py │ ├── gen_sim_pair2.py │ ├── gen_small_arch_generalized.py │ ├── gen_small_arch_gi_sgi_mcq.py │ ├── gen_small_arch_m2sat.py │ ├── gen_small_arch_sp.py │ ├── gen_sp_vars.py │ ├── gen_tot_mc_100_genX.py │ ├── gen_tot_mc_30_gen4.py │ ├── gen_tot_mc_gen4.py │ ├── gen_tot_mc_pickle.py │ ├── gen_tsne.py │ ├── gen_tsne_100_genX.py │ ├── gen_tsne_30_gen4.py │ ├── gen_tsne_gen4.py │ ├── gen_tsp_comp.py │ ├── gen_tt1.py │ ├── gen_v4.py │ ├── gi_sgi_same.pickle │ ├── gi_sgi_same_gi_sgi_same.pdf │ ├── gi_sgi_same_gi_sgi_same.png │ ├── gi_sgi_same_sgi_gi_same.pdf │ ├── gi_sgi_same_sgi_gi_same.png │ ├── labellines.py │ ├── lib.py │ ├── m23sat.pickle │ ├── m2sat_comp.pdf │ ├── m2sat_comp.pickle │ ├── m2sat_comp.png │ ├── m2sat_comp_16x16_1M.pdf │ ├── m2sat_comp_16x16_1M.png │ ├── m2sat_comp_16x16_300k.pdf │ ├── m2sat_comp_16x16_300k.png │ ├── m2sat_comp_8x8_1M.pdf │ ├── m2sat_comp_8x8_1M.png │ ├── m2sat_three_case.pickle │ ├── m2sat_three_case_loss.pdf │ ├── m2sat_three_case_loss.png │ ├── m2sat_three_case_r2.pdf │ ├── m2sat_three_case_r2.png │ ├── m3sat_comp_A_F.pdf │ ├── m3sat_comp_A_F.png │ ├── m3sat_comp_A_F_vars_c10.pdf │ ├── m3sat_comp_A_F_vars_c10.png │ ├── maxpool_comp.pdf │ ├── maxpool_comp.pickle │ ├── maxpool_comp.png │ ├── mc_comp_edges.pickle │ ├── mc_comp_edges_r2.pdf │ ├── mc_comp_edges_r2.png │ ├── mc_comp_loss.pdf │ ├── mc_comp_loss.png │ ├── np_comp.pickle │ ├── np_comp_nodes.pdf │ ├── np_comp_nodes.png │ ├── np_comp_nodes5x5.pdf │ ├── np_comp_nodes5x5.png │ ├── np_comp_nodes64x64.pdf │ ├── np_comp_nodes64x64.png │ ├── plot_big_arch_generalized.py │ ├── plot_big_arch_gi_sgi_mcq.py │ ├── plot_big_arch_qa_np_sp_m2sat.py │ ├── plot_def_a3.py │ ├── plot_gc_matrix.py │ ├── plot_gi_sgi_same.py │ ├── plot_m2sat_comp.py │ ├── plot_m2sat_comp_16x16_1M.py │ ├── plot_m2sat_comp_8x8_1M.py │ ├── plot_m2sat_three_case.py │ ├── plot_m3sat_comp_A_F.py │ ├── plot_m3sat_comp_A_F_clauses.py │ ├── plot_maxpool_comp.py │ ├── plot_mc_comp_edges.py │ ├── plot_np_comp.py │ ├── plot_qa_best_99_example.py │ ├── plot_qa_comp.py │ ├── plot_qa_debug.py │ ├── plot_qa_ones.py │ ├── plot_qa_res.py │ ├── plot_qa_zeros.py │ ├── plot_qb.py │ ├── plot_qk.py │ ├── plot_qubo_map.py │ ├── plot_red_ae.py │ ├── plot_reverse_losses.py │ ├── plot_sim.py │ ├── plot_sim_pair.py │ ├── plot_sim_pair2.py │ ├── plot_small_arch_generalized.py │ ├── plot_small_arch_gi_sgi_mcq.py │ ├── plot_small_arch_m2sat.py │ ├── plot_small_arch_sp.py │ ├── plot_sp_vars.py │ ├── plot_tot_mc.py │ ├── plot_tot_mc_100_genX.py │ ├── plot_tot_mc_30_gen4.py │ ├── plot_tot_mc_gen4.py │ ├── plot_tsne.py │ ├── plot_tsne_100_genX.py │ ├── plot_tsne_30_gen4.py │ ├── plot_tsne_gen4.py │ ├── plot_tsp_comp.py │ ├── plot_tt1.py │ ├── plot_v4.py │ ├── plot_weights.py │ ├── plot_weights_matrices.py │ ├── qa_avg_residuals1.pdf │ ├── qa_avg_residuals1.png │ ├── qa_avg_residuals2.pdf │ ├── qa_avg_residuals2.png │ ├── qa_best_99_residual.pdf │ ├── qa_best_99_residual.png │ ├── qa_best_99_value.pdf │ ├── qa_best_99_value.png │ ├── qa_comp.pdf │ ├── qa_comp.pickle │ ├── qa_comp.png │ ├── qa_comp_datasize.pdf │ ├── qa_comp_datasize.png │ ├── qa_comp_special_loss.pdf │ ├── qa_comp_special_loss.png │ ├── qa_debug.pickle │ ├── qa_ones.pickle │ ├── qa_ones_loss.pdf │ ├── qa_ones_loss.png │ ├── qa_ones_r2.pdf │ ├── qa_ones_r2.png │ ├── qa_zeros.pdf │ ├── qa_zeros.pickle │ ├── qa_zeros.png │ ├── qb.pickle │ ├── qb_qb1.pdf │ ├── qb_qb1.png │ ├── qb_qb1_1.pdf │ ├── qb_qb1_1.png │ ├── qb_qb2.pdf │ ├── qb_qb2.png │ ├── qb_qb2_1.pdf │ ├── qb_qb2_1.png │ ├── qk.pickle │ ├── qk_high.pdf │ ├── qk_high.png │ ├── qk_norm.pdf │ ├── qk_norm.png │ ├── qubo_map.pickle │ ├── qubo_map_medians.png │ ├── qubo_map_singles.png │ ├── red_ae.pickle │ ├── red_ae_all.pdf │ ├── red_ae_all.png │ ├── red_ae_all_matrix.pdf │ ├── red_ae_all_matrix.png │ ├── red_ae_np.pdf │ ├── red_ae_np.png │ ├── reverse_loss.pdf │ ├── reverse_loss.png │ ├── reverse_losses.pickle │ ├── reverse_r2.pdf │ ├── reverse_r2.png │ ├── sim.pickle │ ├── sim_pair.pickle │ ├── sim_pair2.pickle │ ├── sim_pair2_sim2.pdf │ ├── sim_pair2_sim2.png │ ├── sim_pair_all_matrix.pdf │ ├── sim_pair_all_matrix.png │ ├── sim_pair_sim.pdf │ ├── sim_pair_sim.png │ ├── sim_sim.pdf │ ├── sim_sim.png │ ├── small_arch_generalized.pickle │ ├── small_arch_generalized_gc.pdf │ ├── small_arch_generalized_gc.png │ ├── small_arch_generalized_mc.pdf │ ├── small_arch_generalized_mc.png │ ├── small_arch_generalized_mvc.pdf │ ├── small_arch_generalized_mvc.png │ ├── small_arch_generalized_np.pdf │ ├── small_arch_generalized_np.png │ ├── small_arch_generalized_qa.pdf │ ├── small_arch_generalized_qa.png │ ├── small_arch_generalized_tsp.pdf │ ├── small_arch_generalized_tsp.png │ ├── small_arch_gi_sgi_mcq.pickle │ ├── small_arch_gi_sgi_mcq_gi.pdf │ ├── small_arch_gi_sgi_mcq_gi.png │ ├── small_arch_gi_sgi_mcq_mcq.pdf │ ├── small_arch_gi_sgi_mcq_mcq.png │ ├── small_arch_gi_sgi_mcq_sgi.pdf │ ├── small_arch_gi_sgi_mcq_sgi.png │ ├── small_arch_m2sat.pickle │ ├── small_arch_m2sat_m2sat.pdf │ ├── small_arch_m2sat_m2sat.png │ ├── small_arch_sp.pickle │ ├── small_arch_sp_sp.pdf │ ├── small_arch_sp_sp.png │ ├── sp_loss.pdf │ ├── sp_loss.png │ ├── sp_sorted.pdf │ ├── sp_sorted.png │ ├── sp_vars.pdf │ ├── sp_vars.pickle │ ├── sp_vars.png │ ├── tot_mc.pickle │ ├── tot_mc.png │ ├── tot_mc_100_genX_100_genX.pdf │ ├── tot_mc_100_genX_100_genX.pickle │ ├── tot_mc_100_genX_100_genX.png │ ├── tot_mc_100_genX_100_genX_2.pdf │ ├── tot_mc_100_genX_100_genX_2.pickle │ ├── tot_mc_100_genX_100_genX_2.png │ ├── tot_mc_18_lr2_leaky.pdf │ ├── tot_mc_18_lr2_leaky.png │ ├── tot_mc_23.pdf │ ├── tot_mc_23.png │ ├── tot_mc_27_noscramble_100k.pdf │ ├── tot_mc_27_noscramble_100k.png │ ├── tot_mc_27_scramble_100k.pdf │ ├── tot_mc_27_scramble_100k.png │ ├── tot_mc_30_gen4_30_gen4.pdf │ ├── tot_mc_30_gen4_30_gen4.png │ ├── tot_mc_30_gen4_30_gen4_scramble.pdf │ ├── tot_mc_30_gen4_30_gen4_scramble.png │ ├── tot_mc_gen4_27_gen4.pdf │ ├── tot_mc_gen4_27_gen4.png │ ├── tot_mc_gen4_27_gen4_scramble.pdf │ ├── tot_mc_gen4_27_gen4_scramble.png │ ├── tot_misclassifications_18_lr2_leaky.pickle │ ├── tot_misclassifications_23.pickle │ ├── tot_misclassifications_27_noscramble_100k.pickle │ ├── tot_misclassifications_27_scramble_100k.pickle │ ├── tot_misclassifications_30_gen4_30_gen4.pickle │ ├── tot_misclassifications_30_gen4_30_gen4_scramble.pickle │ ├── tot_misclassifications_gen4_27_gen4.pickle │ ├── tot_misclassifications_gen4_27_gen4_scramble.pickle │ ├── tsne10.pdf │ ├── tsne10.png │ ├── tsne100.pdf │ ├── tsne100.png │ ├── tsne1000.pdf │ ├── tsne1000.png │ ├── tsne1000_small.pdf │ ├── tsne1000_small.png │ ├── tsne100_small.pdf │ ├── tsne100_small.png │ ├── tsne10_small.pdf │ ├── tsne10_small.png │ ├── tsne20.pdf │ ├── tsne20.png │ ├── tsne200.pdf │ ├── tsne200.png │ ├── tsne200_small.pdf │ ├── tsne200_small.png │ ├── tsne20_small.pdf │ ├── tsne20_small.png │ ├── tsne30.pdf │ ├── tsne30.png │ ├── tsne30_small.pdf │ ├── tsne30_small.png │ ├── tsne50.pdf │ ├── tsne50.png │ ├── tsne500.pdf │ ├── tsne500.png │ ├── tsne500_small.pdf │ ├── tsne500_small.png │ ├── tsne50_small.pdf │ ├── tsne50_small.png │ ├── tsne70.pdf │ ├── tsne70.png │ ├── tsne70_small.pdf │ ├── tsne70_small.png │ ├── tsne_100_genX_10.pdf │ ├── tsne_100_genX_10.png │ ├── tsne_100_genX_100.pdf │ ├── tsne_100_genX_100.png │ ├── tsne_100_genX_1000.pdf │ ├── tsne_100_genX_1000.png │ ├── tsne_100_genX_20.pdf │ ├── tsne_100_genX_20.png │ ├── tsne_100_genX_200.pdf │ ├── tsne_100_genX_200.png │ ├── tsne_100_genX_30.pdf │ ├── tsne_100_genX_30.png │ ├── tsne_100_genX_50.pdf │ ├── tsne_100_genX_50.png │ ├── tsne_100_genX_500.pdf │ ├── tsne_100_genX_500.png │ ├── tsne_100_genX_70.pdf │ ├── tsne_100_genX_70.png │ ├── tsne_100_genX_data10.pickle │ ├── tsne_100_genX_data100.pickle │ ├── tsne_100_genX_data1000.pickle │ ├── tsne_100_genX_data20.pickle │ ├── tsne_100_genX_data200.pickle │ ├── tsne_100_genX_data30.pickle │ ├── tsne_100_genX_data50.pickle │ ├── tsne_100_genX_data500.pickle │ ├── tsne_100_genX_data70.pickle │ ├── tsne_30_gen4_10.pdf │ ├── tsne_30_gen4_10.png │ ├── tsne_30_gen4_100.pdf │ ├── tsne_30_gen4_100.png │ ├── tsne_30_gen4_1000.pdf │ ├── tsne_30_gen4_1000.png │ ├── tsne_30_gen4_20.pdf │ ├── tsne_30_gen4_20.png │ ├── tsne_30_gen4_200.pdf │ ├── tsne_30_gen4_200.png │ ├── tsne_30_gen4_30.pdf │ ├── tsne_30_gen4_30.png │ ├── tsne_30_gen4_50.pdf │ ├── tsne_30_gen4_50.png │ ├── tsne_30_gen4_500.pdf │ ├── tsne_30_gen4_500.png │ ├── tsne_30_gen4_70.pdf │ ├── tsne_30_gen4_70.png │ ├── tsne_30_gen4_data10.pickle │ ├── tsne_30_gen4_data100.pickle │ ├── tsne_30_gen4_data1000.pickle │ ├── tsne_30_gen4_data20.pickle │ ├── tsne_30_gen4_data200.pickle │ ├── tsne_30_gen4_data30.pickle │ ├── tsne_30_gen4_data50.pickle │ ├── tsne_30_gen4_data500.pickle │ ├── tsne_30_gen4_data70.pickle │ ├── tsne_data.pickle │ ├── tsne_data10.pickle │ ├── tsne_data100.pickle │ ├── tsne_data1000.pickle │ ├── tsne_data20.pickle │ ├── tsne_data200.pickle │ ├── tsne_data30.pickle │ ├── tsne_data50.pickle │ ├── tsne_data500.pickle │ ├── tsne_data70.pickle │ ├── tsne_gen4_10.pdf │ ├── tsne_gen4_10.png │ ├── tsne_gen4_100.pdf │ ├── tsne_gen4_100.png │ ├── tsne_gen4_1000.pdf │ ├── tsne_gen4_1000.png │ ├── tsne_gen4_20.pdf │ ├── tsne_gen4_20.png │ ├── tsne_gen4_200.pdf │ ├── tsne_gen4_200.png │ ├── tsne_gen4_30.pdf │ ├── tsne_gen4_30.png │ ├── tsne_gen4_50.pdf │ ├── tsne_gen4_50.png │ ├── tsne_gen4_500.pdf │ ├── tsne_gen4_500.png │ ├── tsne_gen4_70.pdf │ ├── tsne_gen4_70.png │ ├── tsne_gen4_data10.pickle │ ├── tsne_gen4_data100.pickle │ ├── tsne_gen4_data1000.pickle │ ├── tsne_gen4_data20.pickle │ ├── tsne_gen4_data200.pickle │ ├── tsne_gen4_data30.pickle │ ├── tsne_gen4_data50.pickle │ ├── tsne_gen4_data500.pickle │ ├── tsne_gen4_data70.pickle │ ├── tsp_comp.pdf │ ├── tsp_comp.pickle │ ├── tsp_comp.png │ ├── tsp_comp_81.pdf │ ├── tsp_comp_81.png │ ├── tsp_comp_comp.pdf │ ├── tsp_comp_comp.png │ ├── tt1.pickle │ ├── tt1_tt1.pdf │ ├── tt1_tt1.png │ ├── v4.pickle │ ├── v4_gc.pdf │ ├── v4_gc.png │ ├── v4_mvc.pdf │ ├── v4_mvc.png │ ├── v4_np.pdf │ ├── v4_np.png │ ├── v4_sp.pdf │ ├── v4_sp.png │ ├── weights_a19_2_r2.pdf │ ├── weights_a19_2_r2.png │ ├── weights_all.pdf │ ├── weights_all.png │ ├── weights_gc1_r2.pdf │ ├── weights_gc1_r2.png │ ├── weights_hist_a19_2_r2.pdf │ ├── weights_hist_a19_2_r2.png │ ├── weights_hist_a19_2_r22.pdf │ ├── weights_hist_a19_2_r22.png │ ├── weights_hist_gc1_r2.pdf │ ├── weights_hist_gc1_r2.png │ ├── weights_hist_gc1_r22.pdf │ ├── weights_hist_gc1_r22.png │ ├── weights_hist_m2sat_16x16_5_F_v2.pdf │ ├── weights_hist_m2sat_16x16_5_F_v2.png │ ├── weights_hist_m2sat_16x16_5_F_v22.pdf │ ├── weights_hist_m2sat_16x16_5_F_v22.png │ ├── weights_hist_mvc3_r2.pdf │ ├── weights_hist_mvc3_r2.png │ ├── weights_hist_mvc3_r22.pdf │ ├── weights_hist_mvc3_r22.png │ ├── weights_hist_np19_LONG_r2.pdf │ ├── weights_hist_np19_LONG_r2.png │ ├── weights_hist_np19_LONG_r22.pdf │ ├── weights_hist_np19_LONG_r22.png │ ├── weights_hist_qa_N_100_norm3.pdf │ ├── weights_hist_qa_N_100_norm3.png │ ├── weights_hist_qa_N_100_norm32.pdf │ ├── weights_hist_qa_N_100_norm32.png │ ├── weights_hist_sp4.pdf │ ├── weights_hist_sp4.png │ ├── weights_hist_sp42.pdf │ ├── weights_hist_sp42.png │ ├── weights_hist_tsp2_r2.pdf │ ├── weights_hist_tsp2_r2.png │ ├── weights_hist_tsp2_r22.pdf │ ├── weights_hist_tsp2_r22.png │ ├── weights_m2sat_16x16_5_F_v2.pdf │ ├── weights_m2sat_16x16_5_F_v2.png │ ├── weights_mvc3_r2.pdf │ ├── weights_mvc3_r2.png │ ├── weights_np19_LONG_r2.pdf │ ├── weights_np19_LONG_r2.png │ ├── weights_qa_N_100_norm3.pdf │ ├── weights_qa_N_100_norm3.png │ ├── weights_sp4.pdf │ ├── weights_sp4.png │ ├── weights_tsp2_r2.pdf │ └── weights_tsp2_r2.png ├── problems │ ├── __init__.py │ ├── binary_integer_linear_programming.py │ ├── exact_cover.py │ ├── graph_coloring.py │ ├── graph_isomorphism.py │ ├── knapsack_integer_weights.py │ ├── max2sat.py │ ├── max3sat.py │ ├── max_clique.py │ ├── max_cut.py │ ├── max_independent_set.py │ ├── minimum_maximum_matching.py │ ├── minimum_vertex_cover.py │ ├── number_partitioning.py │ ├── problem.py │ ├── quadratic_assignment.py │ ├── quadratic_knapsack.py │ ├── set_cover.py │ ├── set_packing.py │ ├── set_partitioning.py │ ├── subgraph_isomorphism.py │ ├── test │ │ ├── __init__.py │ │ ├── test_binary_integer_linear_programming.py │ │ ├── test_exact_cover.py │ │ ├── test_graph_coloring.py │ │ ├── test_graph_isomorphism.py │ │ ├── test_knapsack_integer_weights.py │ │ ├── test_max2sat.py │ │ ├── test_max3sat.py │ │ ├── test_max_clique.py │ │ ├── test_max_cut.py │ │ ├── test_max_independent_set.py │ │ ├── test_minimum_maximum_matching.py │ │ ├── test_minimum_vertex_cover.py │ │ ├── test_number_partitioning.py │ │ ├── test_quadratic_assignment.py │ │ ├── test_quadratic_knapsack.py │ │ ├── test_set_cover.py │ │ ├── test_set_packing.py │ │ ├── test_set_partitioning.py │ │ ├── test_subgraph_isomorphism.py │ │ └── test_tsp.py │ ├── tsp.py │ └── util.py └── simulations.json ├── requirements.txt ├── setup.cfg ├── setup.py └── test.sh /.gitignore: -------------------------------------------------------------------------------- 1 | __pycache__ 2 | *.swp 3 | *egg-info 4 | .pickle.gz 5 | qubo_nn/runs/*-* 6 | qubo_nn/models/*-* 7 | qubo_nn/datasets/*.gz 8 | qubo_nn/datasets/* 9 | *.bak 10 | runs*/ 11 | qubo_nn/models/*.pickle 12 | dist/ 13 | bak/ 14 | -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- 1 | MIT License 2 | Copyright (c) 2018 InstanceLabs 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | The above copyright notice and this permission notice shall be included in all 10 | copies or substantial portions of the Software. 11 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 12 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 13 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 14 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 15 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 16 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 17 | SOFTWARE. 18 | -------------------------------------------------------------------------------- /qubo_nn/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/__init__.py -------------------------------------------------------------------------------- /qubo_nn/config.py: -------------------------------------------------------------------------------- 1 | import copy 2 | import json 3 | 4 | 5 | class Config: 6 | def __init__(self, base_path=''): 7 | with open(base_path + 'simulations.json', 'r') as f: 8 | self.cfg = json.load(f) 9 | 10 | def _update_cfg(self, base_cfg, new_cfg): 11 | # We support one level for now. 12 | for k in new_cfg.keys(): 13 | if k == 'base_cfg' or k == 'desc' or k == 'dataset_id': 14 | continue 15 | base_cfg[k].update(new_cfg[k]) 16 | base_cfg['dataset_id'] = new_cfg['dataset_id'] 17 | 18 | def get_cfg(self, cfg_id): 19 | if cfg_id not in self.cfg: 20 | raise Exception( 21 | 'Error: Key %s does not exist in simulations.json.' % cfg_id 22 | ) 23 | 24 | initial_base_cfg = self.cfg["1"] 25 | base_cfg = self.cfg[self.cfg[cfg_id].get('base_cfg', cfg_id)] 26 | # All base configs are based on config "1". 27 | # This enables backwards compatibility when new options are added. 28 | self._update_cfg(initial_base_cfg, base_cfg) 29 | 30 | cfg = copy.deepcopy(initial_base_cfg) 31 | self._update_cfg(cfg, self.cfg[cfg_id]) 32 | 33 | cfg['cfg_id'] = cfg_id 34 | return cfg 35 | 36 | 37 | if __name__ == '__main__': 38 | cfg = Config() 39 | print('\n'.join(cfg.cfg.keys())) 40 | -------------------------------------------------------------------------------- /qubo_nn/contrib/non_reversible.py: -------------------------------------------------------------------------------- 1 | import itertools 2 | from qubo_nn.problems import Max2SAT 3 | from qubo_nn.problems import Max3SAT 4 | from qubo_nn.problems import SetPartitioning 5 | 6 | 7 | # M2SAT 8 | n = [] 9 | m = [] 10 | for comb in itertools.product([True, False], repeat=6): 11 | x = Max2SAT([((0, comb[0]), (1, comb[1])), ((0, comb[2]), (1, comb[3])), ((0, comb[4]), (2, comb[5]))], 3) 12 | a = x.gen_qubo_matrix() 13 | a.flags.writeable = False 14 | h = hash(a.tostring()) 15 | n.append(comb) 16 | m.append(a.tolist()) 17 | 18 | for m_ in m: 19 | if m.count(m_) > 1: 20 | print(m_) 21 | for i, nnn in enumerate(m): 22 | if nnn == m_: 23 | print(n[i]) 24 | 25 | 26 | # # M3SAT 27 | # n = [] 28 | # m = [] 29 | # o = [] 30 | # for comb in itertools.product([True, False], repeat=6): 31 | # x = Max3SAT([((0, comb[0]), (1, comb[1]), (0, comb[2])), ((1, comb[3]), (0, comb[4]), (2, comb[5]))], 3) 32 | # a = x.gen_qubo_matrix() 33 | # a.flags.writeable = False 34 | # h = hash(a.tostring()) 35 | # n.append(comb) 36 | # m.append(a.tolist()) 37 | # o.append(h) 38 | # 39 | # for m_ in m: 40 | # if m.count(m_) > 1: 41 | # print(m_) 42 | # for i, nnn in enumerate(m): 43 | # if nnn == m_: 44 | # print(n[i]) 45 | # print(len(o), len(set(o))) 46 | # 47 | # 48 | # # NP 49 | # sp = SetPartitioning([1, 2], [[1], [2]], [5, 9], 20) 50 | # a = sp.gen_qubo_matrix() 51 | # print(a) 52 | # sp = SetPartitioning([1, 2], [[1], [2]], [5, 9], 15) 53 | # a = sp.gen_qubo_matrix() 54 | # print(a) 55 | # 56 | # 57 | # # QK 58 | # qk = QuadraticKnapsack(np.array([[13, 4], [4, 6]]), np.array([23, 10, 2]), 5) 59 | # a = qk.gen_qubo_matrix() 60 | # print(a) 61 | -------------------------------------------------------------------------------- /qubo_nn/contrib/simulations.json: -------------------------------------------------------------------------------- 1 | { 2 | "1": { 3 | "ppo": { 4 | "network": "mlp", 5 | "total_timesteps": 2e6, 6 | "seed": 42, 7 | "ent_coef": 0.0, 8 | "lr": 3e-5, 9 | "vf_coef": 0.5, 10 | "max_grad_norm": 0.5, 11 | "gamma": 0.99, 12 | "lam": 0.95, 13 | "log_interval": 10, 14 | "nminibatches": 1, 15 | "noptepochs": 4, 16 | "cliprange": 0.1, 17 | "save_interval": 0, 18 | "num_layers": 2, 19 | "num_hidden": 64 20 | } 21 | }, 22 | "2": { 23 | "ppo": { 24 | "network": "mlp", 25 | "total_timesteps": 2e6, 26 | "seed": 42, 27 | "ent_coef": 0.0, 28 | "lr": 3e-5, 29 | "vf_coef": 0.5, 30 | "max_grad_norm": 0.5, 31 | "gamma": 0.99, 32 | "lam": 0.95, 33 | "log_interval": 10, 34 | "nminibatches": 1, 35 | "noptepochs": 4, 36 | "cliprange": 0.3, 37 | "save_interval": 0, 38 | "num_layers": 2, 39 | "num_hidden": 64 40 | } 41 | }, 42 | "3": { 43 | "ppo": { 44 | "network": "mlp", 45 | "total_timesteps": 2e6, 46 | "seed": 42, 47 | "ent_coef": 0.0, 48 | "lr": 1e-7, 49 | "vf_coef": 0.5, 50 | "max_grad_norm": 0.5, 51 | "gamma": 0.99, 52 | "lam": 0.99, 53 | "log_interval": 10, 54 | "nminibatches": 1, 55 | "noptepochs": 4, 56 | "cliprange": 0.1, 57 | "save_interval": 0, 58 | "num_layers": 1, 59 | "num_hidden": 256 60 | } 61 | } 62 | } 63 | -------------------------------------------------------------------------------- /qubo_nn/contrib/sp.py: -------------------------------------------------------------------------------- 1 | import numpy as np 2 | from qubo_nn.problems import SetPacking 3 | 4 | 5 | cfg = { 6 | "problems": {"SP": {}} 7 | } 8 | 9 | # problems = SetPacking.gen_problems(cfg, 1, size=(5, 4)) 10 | # 11 | # for problem in problems: 12 | # m = SetPacking(cfg, **problem) 13 | # qubo = m.gen_qubo_matrix() 14 | # qubo[np.tril_indices(4, -1)] = 0. 15 | # print(problem) 16 | # print(qubo) 17 | 18 | 19 | def gen(problem): 20 | m = SetPacking(cfg, **problem) 21 | qubo = m.gen_qubo_matrix() 22 | qubo[np.tril_indices(4, -1)] = 0. 23 | print(problem) 24 | print(qubo) 25 | 26 | 27 | gen({'set_': [0, 1, 2, 3, 4], 'subsets': [[0, 1, 4], [0, 2, 3], [2, 3], [3, 4]]}) 28 | gen({'set_': [0, 1, 2, 3, 4], 'subsets': [[0, 1, 4], [1, 2, 3], [2, 3], [3, 4]]}) 29 | # gen({'set_': [0, 1, 2, 3, 4], 'subsets': [[0, 1], [1, 2, 3], [2, 3, 4], [2, 4]]}) 30 | 31 | 32 | # [0, 1] 33 | # [0] 34 | # [1, 2] 35 | # [1, 2, 3] 36 | # [0, 3] 37 | # [[1. 1. 0. 0.] 38 | # [1. 0. 0. 0.] 39 | # [0. 1. 1. 0.] 40 | # [0. 1. 1. 1.] 41 | # [1. 0. 0. 1.]] 42 | # {'set_': [0, 1, 2, 3, 4], 'subsets': [[0, 1, 4], [0, 2, 3], [2, 3], [3, 4]]} 43 | # [[-2. -3. 0. -3.] 44 | # [ 0. 1. -6. -3.] 45 | # [ 0. 0. 1. -3.] 46 | # [ 0. 0. 0. 1.]] 47 | -------------------------------------------------------------------------------- /qubo_nn/datasets/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/datasets/.gitkeep -------------------------------------------------------------------------------- /qubo_nn/decision_tree.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/decision_tree.pickle -------------------------------------------------------------------------------- /qubo_nn/decision_tree.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | 3 | import pyxis as px 4 | import numpy as np 5 | from sklearn.tree import DecisionTreeClassifier 6 | from sklearn.model_selection import train_test_split 7 | from sklearn.metrics import classification_report, confusion_matrix 8 | 9 | from qubo_nn.config import Config 10 | from qubo_nn.data import LMDBDataLoader 11 | 12 | 13 | cfg = Config().get_cfg('100_genX') 14 | cfg["use_big"] = False 15 | lmdb_loader = LMDBDataLoader(cfg) 16 | loader =lmdb_loader.train_data_loader 17 | X = np.array([]) 18 | y = np.array([]) 19 | for i, item in enumerate(loader): 20 | if i % 10 == 0: 21 | print(i) 22 | if X.shape[0] == 0: 23 | X = item[0].detach().numpy().reshape((500, 4096)) 24 | y = item[1].detach().numpy() 25 | if item[0].shape[0] == 500: 26 | X = np.concatenate([X, item[0].detach().numpy().reshape((500, 4096))]) 27 | y = np.concatenate([y, item[1].detach().numpy()]) 28 | 29 | print(X.shape, y.shape) 30 | 31 | results = [] 32 | for _ in range(10): 33 | X_train, X_test, y_train, y_test = train_test_split(X, y) # test size was .25 per default. 34 | # X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=.1) 35 | clf = DecisionTreeClassifier() 36 | clf.fit(X_train, y_train) 37 | y_pred = clf.predict(X_test) 38 | conf_matrix = confusion_matrix(y_test, y_pred) 39 | report = classification_report(y_test, y_pred) 40 | results.append((conf_matrix, report, clf)) 41 | with open('decision_tree2.pickle', 'wb+') as f: 42 | pickle.dump(results, f) 43 | -------------------------------------------------------------------------------- /qubo_nn/decision_tree2.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/decision_tree2.pickle -------------------------------------------------------------------------------- /qubo_nn/decision_tree_inf.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import numpy as np 3 | import scipy.stats as st 4 | from sklearn.tree import DecisionTreeClassifier 5 | 6 | 7 | def calc_ci(arr): 8 | mean = np.mean(arr, axis=0) 9 | ci = st.t.interval( 10 | 0.95, 11 | len(arr) - 1, 12 | loc=np.mean(arr, axis=0), 13 | scale=st.sem(arr, axis=0) 14 | ) 15 | range_ = round(mean - ci[0], 8) 16 | mean = round(mean, 8) 17 | return mean, range_ 18 | 19 | 20 | node_counts = [] 21 | mcs = [] 22 | with open('decision_tree2.pickle', 'rb') as f: 23 | # conf_matrix, report, clf = pickle.load(f) 24 | results = pickle.load(f) 25 | for (conf_matrix, report, clf) in results: 26 | # print(conf_matrix) 27 | # print(report) 28 | # print(clf.get_depth()) 29 | # print(clf.tree_.node_count) 30 | 31 | mc = (np.sum(conf_matrix) - np.trace(conf_matrix)) / np.trace(conf_matrix) 32 | node_counts.append(clf.tree_.node_count) 33 | mcs.append(mc) 34 | 35 | print(calc_ci(node_counts)) 36 | print(calc_ci(mcs)) 37 | -------------------------------------------------------------------------------- /qubo_nn/filling_level_diag.py: -------------------------------------------------------------------------------- 1 | import pyxis as px 2 | import numpy as np 3 | 4 | from qubo_nn.config import Config 5 | from qubo_nn.data import LMDBDataLoader 6 | 7 | 8 | problems_short = ["np", "mc", "mvc", "sp", "m2sat", "spp", "gc", "qa", "qk", "m3sat", "tsp", "gi", "sgi", "mcq"] 9 | QUBO_SIZE = 64 10 | 11 | 12 | for problem in problems_short: 13 | cfg = Config().get_cfg('red_%s_1' % problem) 14 | cfg["use_big"] = False 15 | lmdb_loader = LMDBDataLoader(cfg) 16 | loader = lmdb_loader.train_data_loader 17 | data = list(loader) 18 | is_diag_same = True 19 | for batch in data: 20 | batch = batch[0] 21 | last_diag = None 22 | for qubo in batch: 23 | if last_diag is not None and not np.allclose(np.diag(qubo), last_diag): 24 | is_diag_same = False 25 | last_diag = np.diag(qubo) 26 | # print(total) 27 | # print(zeros) 28 | print(problem, is_diag_same) 29 | -------------------------------------------------------------------------------- /qubo_nn/filling_level_zeros.py: -------------------------------------------------------------------------------- 1 | import pyxis as px 2 | import numpy as np 3 | 4 | from qubo_nn.config import Config 5 | from qubo_nn.data import LMDBDataLoader 6 | 7 | 8 | problems_short = ["np", "mc", "mvc", "sp", "m2sat", "spp", "gc", "qa", "qk", "m3sat", "tsp", "gi", "sgi", "mcq"] 9 | QUBO_SIZE = 64 10 | 11 | 12 | for problem in problems_short: 13 | cfg = Config().get_cfg('red_%s_1' % problem) 14 | cfg["use_big"] = False 15 | lmdb_loader = LMDBDataLoader(cfg) 16 | loader = lmdb_loader.train_data_loader 17 | data = list(loader) 18 | total = 0. 19 | zeros = 0. 20 | for batch in data: 21 | batch = batch[0] 22 | batch = batch.reshape(100 * 4096) 23 | total += 100 * 4096 24 | zeros += np.where(batch == 0.)[0].shape[0] 25 | # print(total) 26 | # print(zeros) 27 | print(problem, zeros / total) 28 | -------------------------------------------------------------------------------- /qubo_nn/gen_red_cfg.py: -------------------------------------------------------------------------------- 1 | import copy 2 | import json 3 | 4 | 5 | problems = ["NP", "MC", "MVC", "SP", "M2SAT", "SPP", "GC", "QA", "QK", "M3SAT", "TSP", "GI", "SGI", "MCQ"] 6 | 7 | 8 | cfg = { 9 | "red2": { 10 | "dataset_id": "red2", 11 | "base_cfg": "red_base", 12 | "problems": { 13 | "n_problems": 100000, 14 | "problems": ["NP"] 15 | }, 16 | "model": { 17 | # "n_epochs": 100, 18 | "lr": 10.0, 19 | "fc_sizes": [[4096], [4096]] 20 | } 21 | } 22 | } 23 | 24 | 25 | with open("simulations.json", "a+") as f: 26 | for problem in problems: 27 | dataset_cfg_id = "red_" + problem.lower() + "_1" 28 | for n in range(1, 20): 29 | size = 4096 * (n / 20) 30 | cfg_ = copy.deepcopy(cfg) 31 | cfg_["red2"]["model"]["fc_sizes"][0] = [int(size)] 32 | cfg_["red2"]["problems"]["problems"] = [problem] 33 | cfg_id = "red_" + problem.lower() + "_" + str(n) 34 | cfg_[cfg_id] = cfg_["red2"] 35 | cfg_[cfg_id]["dataset_id"] = dataset_cfg_id 36 | del cfg_["red2"] 37 | f.write(" " + json.dumps(cfg_)[1:-1] + ",\n") 38 | -------------------------------------------------------------------------------- /qubo_nn/models/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/models/.gitkeep -------------------------------------------------------------------------------- /qubo_nn/nn/__init__.py: -------------------------------------------------------------------------------- 1 | from qubo_nn.nn.models import Optimizer 2 | from qubo_nn.nn.models import ReverseOptimizer 3 | from qubo_nn.nn.models import AutoEncoderOptimizer 4 | from qubo_nn.nn.models import RNNOptimizer 5 | from qubo_nn.nn.models import A3Optimizer 6 | from qubo_nn.nn.models import Resistance1 7 | from qubo_nn.nn.models import Resistance2 8 | from qubo_nn.nn.models import QbsolvOptimizer 9 | from qubo_nn.nn.models import RedAEOptimizer 10 | -------------------------------------------------------------------------------- /qubo_nn/plots/README.md: -------------------------------------------------------------------------------- 1 | All the files here depend on `../runs/` or `../models/`. 2 | -------------------------------------------------------------------------------- /qubo_nn/plots/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/__init__.py -------------------------------------------------------------------------------- /qubo_nn/plots/architecture.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/architecture.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/architecture.png -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_generalized.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_generalized.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_generalized_gc.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_generalized_gc.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_generalized_gc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_generalized_gc.png -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_gi_sgi_mcq.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_gi_sgi_mcq.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_gi_sgi_mcq_gi.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_gi_sgi_mcq_gi.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_gi_sgi_mcq_gi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_gi_sgi_mcq_gi.png -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_gi_sgi_mcq_mcq.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_gi_sgi_mcq_mcq.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_gi_sgi_mcq_mcq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_gi_sgi_mcq_mcq.png -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_gi_sgi_mcq_sgi.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_gi_sgi_mcq_sgi.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_gi_sgi_mcq_sgi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_gi_sgi_mcq_sgi.png -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat_m2sat.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat_m2sat.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat_m2sat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat_m2sat.png -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat_np.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat_np.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat_np.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat_np.png -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat_qa.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat_qa.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat_qa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat_qa.png -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat_sp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat_sp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/big_arch_qa_np_sp_m2sat_sp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/big_arch_qa_np_sp_m2sat_sp.png -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_100_genX_100_genX.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_100_genX_100_genX.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_100_genX_100_genX.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_100_genX_100_genX.png -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_27_noscramble_100k.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_27_noscramble_100k.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_27_noscramble_100k.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_27_noscramble_100k.png -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_27_scramble_100k.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_27_scramble_100k.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_27_scramble_100k.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_27_scramble_100k.png -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_30_gen4_30_gen4.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_30_gen4_30_gen4.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_30_gen4_30_gen4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_30_gen4_30_gen4.png -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_30_gen4_30_gen4_scramble.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_30_gen4_30_gen4_scramble.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_30_gen4_30_gen4_scramble.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_30_gen4_30_gen4_scramble.png -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_gen4_27_gen4.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_gen4_27_gen4.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_gen4_27_gen4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_gen4_27_gen4.png -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_gen4_27_gen4_scramble.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_gen4_27_gen4_scramble.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/confusion_gen4_27_gen4_scramble.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/confusion_gen4_27_gen4_scramble.png -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3_a3_1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3_a3_1.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3_a3_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3_a3_1.png -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3_a3_3.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3_a3_3.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3_a3_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3_a3_3.png -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3_a3ng.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3_a3ng.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3_a3ng.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3_a3ng.png -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3_a3ng_v2_e1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3_a3ng_v2_e1.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/def_a3_a3ng_v2_e1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/def_a3_a3ng_v2_e1.png -------------------------------------------------------------------------------- /qubo_nn/plots/gc_matrix_large.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gc_matrix_large.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/gc_matrix_large.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gc_matrix_large.png -------------------------------------------------------------------------------- /qubo_nn/plots/gc_matrix_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gc_matrix_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/gc_matrix_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gc_matrix_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/gen_big_arch_generalized.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 30 17 | base_paths = ['../runs/', '../runs3/', '../runs5/', '../runs7/'] 18 | problems = [ 19 | ('gc1_r2', 20000), 20 | ('gc1_generalized_gen2_big_arch_2', 20000), 21 | ('gc1_generalized_gen3_big_arch_2', 20000), 22 | ('gc1_generalized_gen4_big_arch_2', 20000) 23 | ] 24 | kv = {} 25 | for problem in problems: 26 | print(problem) 27 | paths = [] 28 | for base_path in base_paths: 29 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 30 | print(len(paths)) 31 | print(paths) 32 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 33 | kv[problem[0]] = data 34 | 35 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 36 | print("Saving in", fname) 37 | with open(fname, 'wb+') as f: 38 | pickle.dump(kv, f) 39 | 40 | 41 | if __name__ == '__main__': 42 | run() 43 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_big_arch_gi_sgi_mcq.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 30 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('mcq_gen1_big_arch', 20000), 20 | ('mcq_gen2_big_arch', 20000), 21 | ('mcq_gen3_big_arch', 20000), 22 | ('mcq_gen4_big_arch', 20000), 23 | ('mcq_gen1_big_arch_2', 20000), 24 | ('mcq_gen2_big_arch_2', 20000), 25 | ('mcq_gen3_big_arch_2', 20000), 26 | ('mcq_gen4_big_arch_2', 20000), 27 | ('sgi_gen1_3_big_arch', 20000), 28 | ('sgi_gen2_3_big_arch', 20000), 29 | ('sgi_gen3_3_big_arch', 20000), 30 | ('sgi_gen4_3_big_arch', 20000), 31 | ('sgi_gen1_3_big_arch_2', 20000), 32 | ('sgi_gen2_3_big_arch_2', 20000), 33 | ('sgi_gen3_3_big_arch_2', 20000), 34 | ('sgi_gen4_3_big_arch_2', 20000), 35 | ('gi_gen1_big_arch', 20000), 36 | ('gi_gen2_big_arch', 20000), 37 | ('gi_gen3_big_arch', 20000), 38 | ('gi_gen4_big_arch', 20000) 39 | ] 40 | kv = {} 41 | for problem in problems: 42 | print(problem) 43 | paths = [] 44 | for base_path in base_paths: 45 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 46 | print(len(paths)) 47 | print(paths) 48 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 49 | kv[problem[0]] = data 50 | 51 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 52 | print("Saving in", fname) 53 | with open(fname, 'wb+') as f: 54 | pickle.dump(kv, f) 55 | 56 | 57 | if __name__ == '__main__': 58 | run() 59 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_def_a3.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | # r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | # eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | train_loss = aggregate_single(paths, 'Loss/Train', min_len, req_len=req_len, cutoff=max_len) 12 | return [], train_loss 13 | 14 | 15 | def run(): 16 | min_len = 1000 17 | base_paths = ['../runs/', '../runs9/'] 18 | problems = [ 19 | ('a3_1', 5), 20 | ('a3_2', 5000), 21 | ('a3_3', 5000), 22 | ('a3ng', 1000), 23 | ('a3ng_1', 1000), 24 | ('a3ng_2', 1000), 25 | ('a3ng_3', 1000), 26 | ('a3ng_v2', 1000), 27 | ('a3ng_v2_e1', 100), 28 | ('a3ng_v3_e1', 100) 29 | ] 30 | kv = {} 31 | for problem in problems: 32 | print(problem) 33 | paths = [] 34 | for base_path in base_paths: 35 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 36 | print(len(paths)) 37 | print(paths) 38 | data = aggregate(paths, min_len, 10000000, req_len=problem[1]) 39 | kv[problem[0]] = data 40 | 41 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 42 | print("Saving in", fname) 43 | with open(fname, 'wb+') as f: 44 | pickle.dump(kv, f) 45 | 46 | 47 | if __name__ == '__main__': 48 | run() 49 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_gi_sgi_same.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Total_Misclassifications', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 30 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('30_sgi_gi_same', 20000), 20 | ('30_sgi_gi_same_but_diff_edges', 20000) 21 | ] 22 | kv = {} 23 | for problem in problems: 24 | print(problem) 25 | paths = [] 26 | for base_path in base_paths: 27 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 28 | print(len(paths)) 29 | print(paths) 30 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 31 | kv[problem[0]] = data 32 | 33 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 34 | print("Saving in", fname) 35 | with open(fname, 'wb+') as f: 36 | pickle.dump(kv, f) 37 | 38 | 39 | if __name__ == '__main__': 40 | run() 41 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_large_arch_generalized.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, len_, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 200 16 | req_len = 1000 17 | base_paths = ['../runs/', '../runs7/'] 18 | problems = [ 19 | ('a19_2_generalized_gen4_big_arch', 10), 20 | ('mvc3_generalized_gen4_big_arch', 10), 21 | ('gc1_generalized_gen4_big_arch', 10) 22 | # TODO!! 23 | ] 24 | kv = {} 25 | for problem in problems: 26 | print(problem) 27 | paths = [] 28 | for base_path in base_paths: 29 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 30 | print(len(paths)) 31 | print(paths) 32 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 33 | kv[problem[0]] = data 34 | 35 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 36 | print("Saving in", fname) 37 | with open(fname, 'wb+') as f: 38 | pickle.dump(kv, f) 39 | 40 | 41 | if __name__ == '__main__': 42 | run() 43 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_m23sat.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, req_len): 8 | arr_eval = aggregate_single(paths, 'Loss/Eval', min_len) 9 | arr_train = aggregate_single(paths, 'Loss/Train', min_len) 10 | arr_r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len) 11 | return arr_eval, arr_train, arr_r2 12 | 13 | 14 | def run(): 15 | min_len = 100 16 | base_paths = ['../runs/', '../runs5/'] 17 | problems = [ 18 | 'm3sat_5_F', 19 | 'm3sat_10_F', 20 | 'm3sat_15V_5_F', 21 | 'm3sat_15V_10_F', 22 | 'm3sat_20V_10_F', 23 | 'm3sat_5V_5_F', 24 | 'm3sat_5V_3_F', 25 | 'm3sat_5V_2_F', 26 | 27 | 'm3sat_10V_5_A', 28 | 'm3sat_10V_10_A', 29 | 'm3sat_15V_5_A', 30 | 'm3sat_15V_10_A', 31 | 'm3sat_5V_5_A', 32 | 'm3sat_5V_3_A', 33 | 'm3sat_5V_2_A', 34 | 'm3sat_5V_5_A_2', 35 | 36 | 'm2sat_16x16_10_F_v2_1M', 37 | 'm2sat_16x16_5_F_v2_1M', 38 | 'm2sat_16x16_15_F_v2_1M', 39 | 'm2sat_16x16_20_F_v2_1M', 40 | 'm2sat_16x16_25_F_v2_1M', 41 | 'm2sat_16x16_30_F_v2_1M', 42 | 43 | 'm2sat_8x8_10_F_v2_1M', 44 | 'm2sat_8x8_5_F_v2_1M', 45 | 'm2sat_8x8_15_F_v2_1M', 46 | 'm2sat_8x8_20_F_v2_1M', 47 | 'm2sat_8x8_25_F_v2_1M', 48 | 'm2sat_8x8_30_F_v2_1M' 49 | ] 50 | 51 | req_len = 10 52 | 53 | kv = {} 54 | for problem in problems: 55 | paths = [] 56 | for base_path in base_paths: 57 | print(problem) 58 | paths.extend(glob.glob(base_path + '*-' + problem)) 59 | 60 | print(paths) 61 | data = aggregate(paths, min_len, req_len) 62 | kv[problem] = data 63 | 64 | with open('m23sat.pickle', 'wb+') as f: 65 | pickle.dump(kv, f) 66 | 67 | 68 | if __name__ == '__main__': 69 | run() 70 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_m2sat_comp_pickle.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, len_): 8 | fpfn_tot_ratio = aggregate_single(paths, 'Custom/FPFN_TOT_Ratio', min_len, len_) 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, len_) 10 | return fpfn_tot_ratio, r2 11 | 12 | 13 | def run(): 14 | min_len = 201 15 | base_paths = ['../runs3/', '../runs/'] 16 | problems = [ 17 | ('m2sat_16x16_5_F_v2', 201), 18 | ('m2sat_16x16_10_F_v2', 61), 19 | ('m2sat_16x16_15_F_v2', 51), 20 | ('m2sat_16x16_20_F_v2', 51), 21 | ('m2sat_16x16_25_F_v2', 31), 22 | ('m2sat_16x16_30_F_v2', 31) 23 | ] 24 | kv = {} 25 | for problem in problems: 26 | print(problem) 27 | paths = [] 28 | for base_path in base_paths: 29 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 30 | print(len(paths)) 31 | print(paths) 32 | data = aggregate(paths, min_len, problem[1]) 33 | kv[problem[0]] = data 34 | 35 | with open('m2sat_comp.pickle', 'wb+') as f: 36 | pickle.dump(kv, f) 37 | 38 | 39 | if __name__ == '__main__': 40 | run() 41 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_m2sat_three_case.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, cutoff=False): 8 | arr_eval = aggregate_single(paths, 'Loss/Eval', min_len) 9 | arr_train = aggregate_single(paths, 'Loss/Train', min_len) 10 | if cutoff: 11 | arr_r2 = aggregate_single(paths, 'Custom/R2', min_len, cutoff=6) 12 | else: 13 | arr_r2 = aggregate_single(paths, 'Custom/R2', min_len) 14 | return arr_eval, arr_train, arr_r2 15 | 16 | 17 | def run(): 18 | min_len = 500 19 | base_path = '../runs3/' 20 | problems = ['m2sat_16x16_5_F_v2', 'm2sat_16x16_5_F_v2_no_dupl_chk'] 21 | kv = {} 22 | for problem in problems: 23 | print(problem) 24 | paths = glob.glob('../runs3/*-' + problem) 25 | 26 | paths = [path for path in paths if path not in [ 27 | # '../runs/21-04-03_13:01:10-8112457-datolith.cip.ifi.lmu.de-m2sat_16x16_5_F_v2', 28 | '../runs3/21-04-02_07:40:21-3067619-feueropal.cip.ifi.lmu.de-m2sat_16x16_5_F_v2' 29 | ]] 30 | 31 | print(paths) 32 | if problem == 'm2sat_16x16_5_F_v2_no_dupl_chk': 33 | data = aggregate(paths, min_len, True) 34 | else: 35 | data = aggregate(paths, min_len, False) 36 | kv[problem] = data 37 | 38 | with open('m2sat_three_case.pickle', 'wb+') as f: 39 | pickle.dump(kv, f) 40 | 41 | 42 | if __name__ == '__main__': 43 | run() 44 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_maxpool_comp.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, len_, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 200 16 | req_len = 200 17 | base_paths = ['../runs/', '../runs7/'] 18 | problems = [ 19 | ('gc1_cnn_test1', 10), 20 | ('gc1_cnn_test11', 10), 21 | ('gc1_cnn_test12', 10), 22 | ('gc1_generalized_6', 10) 23 | ] 24 | kv = {} 25 | for problem in problems: 26 | print(problem) 27 | paths = [] 28 | for base_path in base_paths: 29 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 30 | print(len(paths)) 31 | print(paths) 32 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 33 | kv[problem[0]] = data 34 | 35 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 36 | print("Saving in", fname) 37 | with open(fname, 'wb+') as f: 38 | pickle.dump(kv, f) 39 | 40 | 41 | if __name__ == '__main__': 42 | run() 43 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_mc_comp_edges.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len): 8 | arr_eval = aggregate_single(paths, 'Loss/Eval', min_len) 9 | arr_train = aggregate_single(paths, 'Loss/Train', min_len) 10 | arr_r2 = aggregate_single(paths, 'Custom/R2', min_len) 11 | return arr_eval, arr_train, arr_r2 12 | 13 | 14 | def run(): 15 | min_len = 500 16 | base_path = '../runs/' 17 | problems = ['a19_2_r2', 'a19_2_r2_gen_edges2'] 18 | kv = {} 19 | for problem in problems: 20 | print(problem) 21 | paths = glob.glob('../runs/*-' + problem) 22 | data = aggregate(paths, min_len) 23 | kv[problem] = data 24 | 25 | with open('mc_comp_edges.pickle', 'wb+') as f: 26 | pickle.dump(kv, f) 27 | 28 | 29 | if __name__ == '__main__': 30 | run() 31 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_np.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, len_, req_len=None): 8 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len) 9 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len) 10 | return r2, eval_loss 11 | 12 | 13 | def run(): 14 | min_len = 200 15 | req_len = 1000 16 | base_paths = ['../runs/', '../runs3/'] 17 | problems = [ 18 | ('np19_LONG_r2_5x5', 10), 19 | ('np19_LONG_r2_5x5_empty', 10), 20 | ('np19_LONG_r2', 10), 21 | ('np19_LONG_r2_64x64_2k', 10), 22 | ('np19_LONG_r2_64x64_5k', 10) 23 | ] 24 | kv = {} 25 | for problem in problems: 26 | print(problem) 27 | paths = [] 28 | for base_path in base_paths: 29 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 30 | print(len(paths)) 31 | print(paths) 32 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 33 | kv[problem[0]] = data 34 | 35 | with open('np_comp.pickle', 'wb+') as f: 36 | pickle.dump(kv, f) 37 | 38 | 39 | if __name__ == '__main__': 40 | run() 41 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_qa_comp.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, len_, req_len=None): 8 | fpfn_tot_ratio = aggregate_single(paths, 'Custom/FPFN_TOT_Ratio', min_len, req_len=req_len) 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len) 11 | return fpfn_tot_ratio, r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 200 16 | req_len = 22 17 | base_paths = ['../runs/', '../runs5/'] 18 | problems = [ 19 | ('qa_N_9_norm2_1M', 10), 20 | ('qa_N_16_norm1', 10), 21 | ('qa_N_16_norm2', 10), 22 | ('qa_N_16_norm3', 10), 23 | ('qa_N_64_norm1', 10), 24 | ('qa_N_64_norm2', 10), 25 | ('qa_N_64_norm3', 10), 26 | ('qa_N_100_norm1', 10), 27 | ('qa_N_100_norm2', 10), 28 | ('qa_N_100_norm3', 10), 29 | ('qa_N_144_norm3', 10), 30 | 31 | ('qa_N_16_norm2_1M', 10), 32 | ('qa_N_16_norm2_4M', 10), 33 | 34 | ('qa_special_loss1', 10), 35 | 36 | ('qa_N_9_norm2_1M_2', 10) 37 | ] 38 | kv = {} 39 | for problem in problems: 40 | print(problem) 41 | paths = [] 42 | for base_path in base_paths: 43 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 44 | print(len(paths)) 45 | print(paths) 46 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 47 | kv[problem[0]] = data 48 | 49 | with open('qa_comp.pickle', 'wb+') as f: 50 | pickle.dump(kv, f) 51 | 52 | 53 | if __name__ == '__main__': 54 | run() 55 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_qa_ones.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, cutoff=False): 8 | arr_eval = aggregate_single(paths, 'Loss/Eval', min_len) 9 | arr_train = aggregate_single(paths, 'Loss/Train', min_len) 10 | if cutoff: 11 | arr_r2 = aggregate_single(paths, 'Custom/R2', min_len, cutoff=6) 12 | else: 13 | arr_r2 = aggregate_single(paths, 'Custom/R2', min_len) 14 | return arr_eval, arr_train, arr_r2 15 | 16 | 17 | def run(): 18 | min_len = 100 19 | base_path = '../runs/' 20 | problems = ['qa_N_16_norm3', 'qa_N_16_norm3_goddamn'] 21 | kv = {} 22 | for problem in problems: 23 | print(problem) 24 | paths = glob.glob(base_path + '*-' + problem) 25 | 26 | print(paths) 27 | data = aggregate(paths, min_len, False) 28 | kv[problem] = data 29 | 30 | with open('qa_ones.pickle', 'wb+') as f: 31 | pickle.dump(kv, f) 32 | 33 | 34 | if __name__ == '__main__': 35 | run() 36 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_qa_zeros.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, len_, req_len=None): 8 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len) 9 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len) 10 | return r2, eval_loss 11 | 12 | 13 | def run(): 14 | min_len = 200 15 | req_len = 200 16 | base_paths = ['../runs/'] 17 | problems = [ 18 | ('qa_N_64_norm3_5p', 10), 19 | ('qa_N_64_norm3_10p', 10), 20 | ('qa_N_64_norm3_15p', 10), 21 | ('qa_N_64_norm3_20p', 10), 22 | ('qa_N_64_norm3_25p', 10), 23 | ('qa_N_64_norm3_30p', 10), 24 | ('qa_N_64_norm3_35p', 10), 25 | ('qa_N_64_norm3_40p', 10), 26 | ('qa_N_64_norm3_45p', 10), 27 | ('qa_N_64_norm3_50p', 10), 28 | ('qa_N_64_norm3_55p', 10), 29 | ('qa_N_64_norm3_60p', 10), 30 | ('qa_N_64_norm3_65p', 10), 31 | ('qa_N_64_norm3_70p', 10), 32 | ('qa_N_64_norm3_75p', 10), 33 | ('qa_N_64_norm3_80p', 10), 34 | ('qa_N_64_norm3_85p', 10), 35 | ('qa_N_64_norm3_90p', 10) 36 | ] 37 | kv = {} 38 | for problem in problems: 39 | print(problem) 40 | paths = [] 41 | for base_path in base_paths: 42 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 43 | print(len(paths)) 44 | print(paths) 45 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 46 | kv[problem[0]] = data 47 | 48 | with open('qa_zeros.pickle', 'wb+') as f: 49 | pickle.dump(kv, f) 50 | 51 | 52 | if __name__ == '__main__': 53 | run() 54 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_qb.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 10 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('qb1_100k', 20000), 20 | ('qb1_1M', 20000), 21 | ('qb1_5M', 20000), 22 | ('qb2_100k', 20000), 23 | ('qb2_1M', 20000), 24 | ('qb2_5M', 20000), 25 | ('qb1_100k_1', 20000), 26 | ('qb1_1M_1', 20000), 27 | ('qb1_5M_1', 20000), 28 | ('qb2_100k_1', 20000), 29 | ('qb2_1M_1', 20000), 30 | ('qb2_5M_1', 20000) 31 | ] 32 | kv = {} 33 | for problem in problems: 34 | print(problem) 35 | paths = [] 36 | for base_path in base_paths: 37 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 38 | print(len(paths)) 39 | print(paths) 40 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 41 | kv[problem[0]] = data 42 | 43 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 44 | print("Saving in", fname) 45 | with open(fname, 'wb+') as f: 46 | pickle.dump(kv, f) 47 | 48 | 49 | if __name__ == '__main__': 50 | run() 51 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_qk.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, len_, req_len=None): 8 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len) 9 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len) 10 | return r2, eval_loss 11 | 12 | 13 | def run(): 14 | min_len = 200 15 | req_len = 10 16 | base_paths = ['../runs/'] 17 | problems = [ 18 | ('qk7_6x6_high30_1M', 10), 19 | ('qk7_6x6_high10_1M', 10), 20 | ('qk7_6x6_high30_1M_multiply', 10), 21 | ('qk8_16x16_high30_1M', 10), 22 | ('qk8_16x16_high30_1M_multiply', 10), 23 | ('qk8_6x6_high10_1M', 10) 24 | ] 25 | kv = {} 26 | for problem in problems: 27 | print(problem) 28 | paths = [] 29 | for base_path in base_paths: 30 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 31 | print(len(paths)) 32 | print(paths) 33 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 34 | kv[problem[0]] = data 35 | 36 | problems = [ 37 | ('qk10', 10), 38 | ('qk10_norm', 10), 39 | ('qk10_high10', 10), 40 | ('qk10_high10_1', 10), 41 | ('qk10_norm_random_P', 10) 42 | ] 43 | req_len = 200 44 | for problem in problems: 45 | print(problem) 46 | paths = [] 47 | for base_path in base_paths: 48 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 49 | print(len(paths)) 50 | print(paths) 51 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 52 | kv[problem[0]] = data 53 | 54 | with open('qk.pickle', 'wb+') as f: 55 | pickle.dump(kv, f) 56 | 57 | 58 | if __name__ == '__main__': 59 | run() 60 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_qubo_map_pickle.py: -------------------------------------------------------------------------------- 1 | import gzip 2 | import pickle 3 | import numpy as np 4 | 5 | 6 | with gzip.open('../datasets/1.pickle.gz', 'rb') as f: 7 | data, labels = pickle.load(f) 8 | 9 | 10 | # Calc percentiles. 11 | singles = [] 12 | medians = [] 13 | for i in range(9): 14 | p = np.percentile(data[int(1e5 * i):int(1e5 * (i + 1))], 90, axis=0) 15 | medians.append(p) 16 | p = data[int(1e5 * i) + 100] 17 | singles.append(p) 18 | 19 | 20 | with open('qubo_map.pickle', 'wb+') as f: 21 | pickle.dump((medians, singles), f) 22 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_red_ae.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | problems_short = ["np", "mc", "mvc", "sp", "m2sat", "spp", "gc", "qa", "qk", "m3sat", "tsp", "gi", "sgi", "mcq"] 9 | 10 | 11 | def aggregate(paths, min_len, max_len, req_len=None): 12 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 13 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 14 | return r2, eval_loss 15 | 16 | 17 | def run(): 18 | min_len = 1000 19 | base_paths = ['../runs/'] 20 | problems = [] 21 | for short in problems_short: 22 | for i in range(1, 20): 23 | problems.append( 24 | ("red_" + short + "_" + str(i), 20000) 25 | ) 26 | kv = {} 27 | for problem in problems: 28 | print(problem) 29 | paths = [] 30 | for base_path in base_paths: 31 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 32 | print(len(paths)) 33 | print(paths) 34 | req_len = 150 35 | if "gc" in problem[0] or "qa" in problem[0] or "mcq" in problem[0]: 36 | req_len = 10 37 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 38 | kv[problem[0]] = data 39 | 40 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 41 | print("Saving in", fname) 42 | with open(fname, 'wb+') as f: 43 | pickle.dump(kv, f) 44 | 45 | 46 | if __name__ == '__main__': 47 | run() 48 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_sim.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | mc = aggregate_single(paths, 'Total_Misclassifications', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return mc, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 30 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('sim_6_4', 20000), 20 | ('sim_6_3', 20000), 21 | ('sim_5_4', 20000), 22 | ('sim_4_4', 20000), 23 | ('sim_4_3', 20000), 24 | ('sim_3_3', 20000), 25 | ('sim_2_2', 20000), 26 | ('sim_1_1', 20000), 27 | ('sim_0_0', 20000) 28 | ] 29 | kv = {} 30 | for problem in problems: 31 | print(problem) 32 | paths = [] 33 | for base_path in base_paths: 34 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 35 | print(len(paths)) 36 | print(paths) 37 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 38 | kv[problem[0]] = data 39 | 40 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 41 | print("Saving in", fname) 42 | with open(fname, 'wb+') as f: 43 | pickle.dump(kv, f) 44 | 45 | 46 | if __name__ == '__main__': 47 | run() 48 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_sim_pair.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | mc = aggregate_single(paths, 'Total_Misclassifications', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return mc, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 50 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('sim_pair_60_40', 20000), 20 | ('sim_pair_50_50', 20000), 21 | ('sim_pair_50_40', 20000), 22 | ('sim_pair_40_40', 20000), 23 | ('sim_pair_40_30', 20000), 24 | ('sim_pair_30_30', 20000), 25 | ('sim_pair_20_20', 20000), 26 | ('sim_pair_10_10', 20000), 27 | ('sim_pair_5_5', 20000), 28 | ('sim_pair_0_0', 20000) 29 | ] 30 | kv = {} 31 | for problem in problems: 32 | print(problem) 33 | paths = [] 34 | for base_path in base_paths: 35 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 36 | print(len(paths)) 37 | print(paths) 38 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 39 | kv[problem[0]] = data 40 | 41 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 42 | print("Saving in", fname) 43 | with open(fname, 'wb+') as f: 44 | pickle.dump(kv, f) 45 | 46 | 47 | if __name__ == '__main__': 48 | run() 49 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_sim_pair2.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | mc = aggregate_single(paths, 'Total_Misclassifications', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return mc, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 100 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('sim_pair2_50_50', 20000), 20 | ('sim_pair2_50_40', 20000), 21 | ('sim_pair2_40_40', 20000), 22 | ('sim_pair2_40_30', 20000), 23 | ('sim_pair2_30_30', 20000), 24 | ('sim_pair2_20_20', 20000), 25 | ('sim_pair2_10_10', 20000), 26 | ('sim_pair2_5_5', 20000), 27 | ('sim_pair2_0_0', 20000) 28 | ] 29 | kv = {} 30 | for problem in problems: 31 | print(problem) 32 | paths = [] 33 | for base_path in base_paths: 34 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 35 | print(len(paths)) 36 | print(paths) 37 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 38 | kv[problem[0]] = data 39 | 40 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 41 | print("Saving in", fname) 42 | with open(fname, 'wb+') as f: 43 | pickle.dump(kv, f) 44 | 45 | 46 | if __name__ == '__main__': 47 | run() 48 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_small_arch_gi_sgi_mcq.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 30 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('mcq_gen1', 20000), 20 | ('mcq_gen2', 20000), 21 | ('mcq_gen3', 20000), 22 | ('mcq_gen4', 20000), 23 | ('sgi_gen1_3', 20000), 24 | ('sgi_gen2_3', 20000), 25 | ('sgi_gen3_3', 20000), 26 | ('sgi_gen4_3', 20000), 27 | ('gi_gen1', 20000), 28 | ('gi_gen2', 20000), 29 | ('gi_gen3', 20000), 30 | ('gi_gen4', 20000) 31 | ] 32 | kv = {} 33 | for problem in problems: 34 | print(problem) 35 | paths = [] 36 | for base_path in base_paths: 37 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 38 | print(len(paths)) 39 | print(paths) 40 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 41 | kv[problem[0]] = data 42 | 43 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 44 | print("Saving in", fname) 45 | with open(fname, 'wb+') as f: 46 | pickle.dump(kv, f) 47 | 48 | 49 | if __name__ == '__main__': 50 | run() 51 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_small_arch_m2sat.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 30 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('m2sat_8x8_10_gen1_3', 20000), 20 | ('m2sat_8x8_10_gen2_3', 20000), 21 | ('m2sat_8x8_10_gen3_3', 20000), 22 | ('m2sat_8x8_10_gen4_3', 20000), 23 | ] 24 | kv = {} 25 | for problem in problems: 26 | print(problem) 27 | paths = [] 28 | for base_path in base_paths: 29 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 30 | print(len(paths)) 31 | print(paths) 32 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 33 | kv[problem[0]] = data 34 | 35 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 36 | print("Saving in", fname) 37 | with open(fname, 'wb+') as f: 38 | pickle.dump(kv, f) 39 | 40 | 41 | if __name__ == '__main__': 42 | run() 43 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_small_arch_sp.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 30 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('sp_gen1', 20000), 20 | ('sp_gen2', 20000), 21 | ('sp_gen3', 20000), 22 | ('sp_gen4', 20000), 23 | ] 24 | kv = {} 25 | for problem in problems: 26 | print(problem) 27 | paths = [] 28 | for base_path in base_paths: 29 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 30 | print(len(paths)) 31 | print(paths) 32 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 33 | kv[problem[0]] = data 34 | 35 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 36 | print("Saving in", fname) 37 | with open(fname, 'wb+') as f: 38 | pickle.dump(kv, f) 39 | 40 | 41 | if __name__ == '__main__': 42 | run() 43 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_sp_vars.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import pickle 3 | 4 | from lib import aggregate_single 5 | 6 | 7 | def aggregate(paths, min_len, cutoff=False): 8 | arr_eval = aggregate_single(paths, 'Loss/Eval', min_len, req_len=10) 9 | arr_train = aggregate_single(paths, 'Loss/Train', min_len, req_len=10) 10 | if cutoff: 11 | arr_r2 = aggregate_single(paths, 'Custom/R2', min_len, cutoff=6, req_len=10) 12 | else: 13 | arr_r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=10) 14 | return arr_eval, arr_train, arr_r2 15 | 16 | 17 | def run(): 18 | min_len = 100 19 | base_path = '../runs/' 20 | problems = [ 21 | 'sp4', 'sp5', 'sp6', 'sp4_sort', 'sp5_sort', 'sp6_sort', 22 | 'sp4_100k', 'sp5_100k', 'sp6_100k', 'sp4_sort_100k', 'sp5_sort_100k', 'sp6_sort_100k', 23 | 'sp4_1M' 24 | ] 25 | kv = {} 26 | for problem in problems: 27 | print(problem) 28 | paths = glob.glob(base_path + '*-' + problem) 29 | 30 | print(paths) 31 | data = aggregate(paths, min_len, False) 32 | kv[problem] = data 33 | 34 | with open('sp_vars.pickle', 'wb+') as f: 35 | pickle.dump(kv, f) 36 | 37 | 38 | if __name__ == '__main__': 39 | run() 40 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_tsne.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import numpy as np 3 | from MulticoreTSNE import MulticoreTSNE as TSNE 4 | from qubo_nn.data import LMDBDataLoader 5 | from qubo_nn.config import Config 6 | 7 | 8 | cfg_id = '27_scramble_10k_mini' 9 | cfg = Config('../').get_cfg(cfg_id) 10 | cfg["use_big"] = False 11 | lmdb_loader = LMDBDataLoader(cfg, reverse=False, base_path='../') 12 | 13 | X = [] 14 | y = [] 15 | for i, data in enumerate(lmdb_loader.train_data_loader): 16 | # if i > 100: 17 | if i > 20: 18 | break 19 | X.extend(data[0].tolist()) 20 | y.extend(data[1].tolist()) 21 | 22 | X = np.array(X) 23 | X = X.reshape(-1, 64**2) 24 | print(X.shape) 25 | 26 | for i in [10, 20, 30, 50, 70, 100, 200, 500, 1000]: 27 | tsne = TSNE( 28 | n_jobs=10, 29 | n_iter=5000, 30 | perplexity=i, 31 | # perplexity=500., # Best. 32 | verbose=1 33 | ) 34 | Y = tsne.fit_transform(X) 35 | 36 | with open('tsne_data%d.pickle' % i, 'wb+') as f: 37 | pickle.dump((Y, y), f) 38 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_tsne_100_genX.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import numpy as np 3 | from MulticoreTSNE import MulticoreTSNE as TSNE 4 | from qubo_nn.data import LMDBDataLoader 5 | from qubo_nn.config import Config 6 | 7 | 8 | cfg_id = '100_genX' 9 | cfg = Config('../').get_cfg(cfg_id) 10 | cfg["use_big"] = False 11 | lmdb_loader = LMDBDataLoader(cfg, reverse=False, base_path='../') 12 | 13 | X = [] 14 | y = [] 15 | for i, data in enumerate(lmdb_loader.train_data_loader): 16 | if i > 87: # 88 batches á 500 = 44k (from total of 560k), so ~8% 17 | break 18 | X.extend(data[0].tolist()) 19 | y.extend(data[1].tolist()) 20 | 21 | X = np.array(X) 22 | X = X.reshape(-1, 64**2) 23 | print(X.shape) 24 | 25 | for i in [10, 20, 30, 50, 70, 100, 200, 500, 1000]: 26 | tsne = TSNE( 27 | n_jobs=10, 28 | n_iter=5000, 29 | perplexity=i, 30 | # perplexity=500., # Best. 31 | verbose=1 32 | ) 33 | Y = tsne.fit_transform(X) 34 | 35 | with open('tsne_100_genX_data%d.pickle' % i, 'wb+') as f: 36 | pickle.dump((Y, y), f) 37 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_tsne_30_gen4.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import numpy as np 3 | from MulticoreTSNE import MulticoreTSNE as TSNE 4 | from qubo_nn.data import LMDBDataLoader 5 | from qubo_nn.config import Config 6 | 7 | 8 | cfg_id = '30_gen4' 9 | cfg = Config('../').get_cfg(cfg_id) 10 | cfg["use_big"] = False 11 | lmdb_loader = LMDBDataLoader(cfg, reverse=False, base_path='../') 12 | 13 | X = [] 14 | y = [] 15 | for i, data in enumerate(lmdb_loader.train_data_loader): 16 | if i > 87: # 88 batches á 500 = 44k (from total of 560k), so ~8% 17 | break 18 | X.extend(data[0].tolist()) 19 | y.extend(data[1].tolist()) 20 | 21 | X = np.array(X) 22 | X = X.reshape(-1, 64**2) 23 | print(X.shape) 24 | 25 | for i in [10, 20, 30, 50, 70, 100, 200, 500, 1000]: 26 | tsne = TSNE( 27 | n_jobs=10, 28 | n_iter=5000, 29 | perplexity=i, 30 | # perplexity=500., # Best. 31 | verbose=1 32 | ) 33 | Y = tsne.fit_transform(X) 34 | 35 | with open('tsne_30_gen4_data%d.pickle' % i, 'wb+') as f: 36 | pickle.dump((Y, y), f) 37 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_tsne_gen4.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import numpy as np 3 | from MulticoreTSNE import MulticoreTSNE as TSNE 4 | from qubo_nn.data import LMDBDataLoader 5 | from qubo_nn.config import Config 6 | 7 | 8 | cfg_id = '27_gen4' 9 | cfg = Config('../').get_cfg(cfg_id) 10 | cfg["use_big"] = False 11 | lmdb_loader = LMDBDataLoader(cfg, reverse=False, base_path='../') 12 | 13 | X = [] 14 | y = [] 15 | for i, data in enumerate(lmdb_loader.train_data_loader): 16 | if i > 43: # 44 batches á 500 = 22k (from total of 440k), so 5% 17 | break 18 | X.extend(data[0].tolist()) 19 | y.extend(data[1].tolist()) 20 | 21 | X = np.array(X) 22 | X = X.reshape(-1, 64**2) 23 | print(X.shape) 24 | 25 | for i in [10, 20, 30, 50, 70, 100, 200, 500, 1000]: 26 | tsne = TSNE( 27 | n_jobs=10, 28 | n_iter=5000, 29 | perplexity=i, 30 | # perplexity=500., # Best. 31 | verbose=1 32 | ) 33 | Y = tsne.fit_transform(X) 34 | 35 | with open('tsne_gen4_data%d.pickle' % i, 'wb+') as f: 36 | pickle.dump((Y, y), f) 37 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_tsp_comp.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 20 17 | base_paths = ['../runs/', '../runs3/', '../runs5/', '../runs7/', '../runs8/'] 18 | problems = [ 19 | ('tsp2_r2', 150), 20 | ('tsp_gen1', 150), 21 | ('tsp_gen1_81', 150), 22 | ('tsp_gen1_81_2', 150) 23 | ] 24 | kv = {} 25 | for problem in problems: 26 | print(problem) 27 | paths = [] 28 | for base_path in base_paths: 29 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 30 | print(len(paths)) 31 | print(paths) 32 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 33 | kv[problem[0]] = data 34 | 35 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 36 | print("Saving in", fname) 37 | with open(fname, 'wb+') as f: 38 | pickle.dump(kv, f) 39 | 40 | 41 | if __name__ == '__main__': 42 | run() 43 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_tt1.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/A3_MC', min_len, req_len=req_len, cutoff=max_len) 10 | return r2, [] 11 | 12 | 13 | def run(): 14 | min_len = 1000 15 | base_paths = ['../runs/'] 16 | problems = ["TT1"] 17 | kv = {} 18 | for problem in problems: 19 | paths = [] 20 | for base_path in base_paths: 21 | paths.extend(glob.glob(base_path + '*-' + problem)) 22 | print(len(paths)) 23 | print(paths) 24 | data = aggregate(paths, min_len, int(1e8), req_len=0) 25 | kv[problem[0]] = data 26 | 27 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 28 | print("Saving in", fname) 29 | with open(fname, 'wb+') as f: 30 | pickle.dump(kv, f) 31 | 32 | 33 | if __name__ == '__main__': 34 | run() 35 | -------------------------------------------------------------------------------- /qubo_nn/plots/gen_v4.py: -------------------------------------------------------------------------------- 1 | import os 2 | import glob 3 | import pickle 4 | 5 | from lib import aggregate_single 6 | 7 | 8 | def aggregate(paths, min_len, max_len, req_len=None): 9 | r2 = aggregate_single(paths, 'Custom/R2', min_len, req_len=req_len, cutoff=max_len) 10 | eval_loss = aggregate_single(paths, 'Loss/Eval', min_len, req_len=req_len, cutoff=max_len) 11 | return r2, eval_loss 12 | 13 | 14 | def run(): 15 | min_len = 1000 16 | req_len = 80 17 | base_paths = ['../runs/'] 18 | problems = [ 19 | ('v_mvc_gen1', 20000), 20 | ('v_mvc_gen2', 20000), 21 | ('v_mvc_gen3', 20000), 22 | ('v_mvc_gen4', 20000), 23 | ('v_gc_gen1', 20000), 24 | ('v_gc_gen2', 20000), 25 | ('v_gc_gen3', 20000), 26 | ('v_gc_gen4', 20000), 27 | ('v_np_gen1', 20000), 28 | ('v_np_gen2', 20000), 29 | ('v_np_gen3', 20000), 30 | ('v_np_gen4', 20000), 31 | ('v_sp_gen1', 20000), 32 | ('v_sp_gen2', 20000), 33 | ('v_sp_gen3', 20000), 34 | ('v_sp_gen4', 20000) 35 | ] 36 | kv = {} 37 | for problem in problems: 38 | print(problem) 39 | paths = [] 40 | for base_path in base_paths: 41 | paths.extend(glob.glob(base_path + '*-' + problem[0])) 42 | print(len(paths)) 43 | print(paths) 44 | data = aggregate(paths, min_len, problem[1], req_len=req_len) 45 | kv[problem[0]] = data 46 | 47 | fname = os.path.splitext(__file__)[0][4:] + '.pickle' 48 | print("Saving in", fname) 49 | with open(fname, 'wb+') as f: 50 | pickle.dump(kv, f) 51 | 52 | 53 | if __name__ == '__main__': 54 | run() 55 | -------------------------------------------------------------------------------- /qubo_nn/plots/gi_sgi_same.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gi_sgi_same.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/gi_sgi_same_gi_sgi_same.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gi_sgi_same_gi_sgi_same.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/gi_sgi_same_gi_sgi_same.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gi_sgi_same_gi_sgi_same.png -------------------------------------------------------------------------------- /qubo_nn/plots/gi_sgi_same_sgi_gi_same.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gi_sgi_same_sgi_gi_same.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/gi_sgi_same_sgi_gi_same.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/gi_sgi_same_sgi_gi_same.png -------------------------------------------------------------------------------- /qubo_nn/plots/m23sat.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m23sat.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp.png -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp_16x16_1M.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp_16x16_1M.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp_16x16_1M.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp_16x16_1M.png -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp_16x16_300k.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp_16x16_300k.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp_16x16_300k.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp_16x16_300k.png -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp_8x8_1M.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp_8x8_1M.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_comp_8x8_1M.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_comp_8x8_1M.png -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_three_case.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_three_case.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_three_case_loss.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_three_case_loss.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_three_case_loss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_three_case_loss.png -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_three_case_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_three_case_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/m2sat_three_case_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m2sat_three_case_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/m3sat_comp_A_F.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m3sat_comp_A_F.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/m3sat_comp_A_F.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m3sat_comp_A_F.png -------------------------------------------------------------------------------- /qubo_nn/plots/m3sat_comp_A_F_vars_c10.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m3sat_comp_A_F_vars_c10.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/m3sat_comp_A_F_vars_c10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/m3sat_comp_A_F_vars_c10.png -------------------------------------------------------------------------------- /qubo_nn/plots/maxpool_comp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/maxpool_comp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/maxpool_comp.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/maxpool_comp.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/maxpool_comp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/maxpool_comp.png -------------------------------------------------------------------------------- /qubo_nn/plots/mc_comp_edges.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/mc_comp_edges.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/mc_comp_edges_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/mc_comp_edges_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/mc_comp_edges_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/mc_comp_edges_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/mc_comp_loss.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/mc_comp_loss.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/mc_comp_loss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/mc_comp_loss.png -------------------------------------------------------------------------------- /qubo_nn/plots/np_comp.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/np_comp.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/np_comp_nodes.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/np_comp_nodes.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/np_comp_nodes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/np_comp_nodes.png -------------------------------------------------------------------------------- /qubo_nn/plots/np_comp_nodes5x5.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/np_comp_nodes5x5.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/np_comp_nodes5x5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/np_comp_nodes5x5.png -------------------------------------------------------------------------------- /qubo_nn/plots/np_comp_nodes64x64.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/np_comp_nodes64x64.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/np_comp_nodes64x64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/np_comp_nodes64x64.png -------------------------------------------------------------------------------- /qubo_nn/plots/plot_qa_debug.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | 3 | import numpy as np 4 | import matplotlib.pyplot as plt 5 | 6 | 7 | with open("qa_debug.pickle", "rb") as f: 8 | data = pickle.load(f) 9 | 10 | 11 | losses = [d[0] for d in data] 12 | loss90 = np.percentile(losses, 97.5) 13 | loss10 = np.percentile(losses, 2.5) 14 | 15 | avg_diff_x = 0 16 | avg_diff_y = 0 17 | x = [] # good ones 18 | y = [] # bad ones 19 | for d in data: 20 | if d[0] > loss90: 21 | y.append((d[3][0], d[2][0], d[1][0])) 22 | avg_diff_y += abs(np.average(d[3][0][:16]) - np.average(d[3][0][16:])) 23 | elif d[0] < loss10: 24 | x.append((d[3][0], d[2][0], d[1][0])) 25 | avg_diff_x += abs(np.average(d[3][0][:16]) - np.average(d[3][0][16:])) 26 | 27 | print(avg_diff_x / 1000., avg_diff_y / 1000.) 28 | 29 | idx = np.arange(len(y[0][0])) 30 | width = np.min(np.diff(idx)) / 3 31 | 32 | print(len(x), len(y)) 33 | 34 | for i in range(20): 35 | print(y[i][2]) 36 | 37 | fig, axs = plt.subplots(1, 2, figsize=(12, 4)) 38 | 39 | ax = axs[0] 40 | ax.bar(idx - width + .25, x[i][0], width, label="Want") 41 | ax.bar(idx + .25, x[i][0], width, label="Predicted") 42 | ax.set_title("Good loss") 43 | ax.axhline(y=np.average(x[i][0][:16]), xmin=0, xmax=.5) 44 | ax.axhline(y=np.average(x[i][0][16:]), xmin=.5, xmax=1.) 45 | 46 | ax = axs[1] 47 | ax.bar(idx - width + .25, y[i][0], width, label="Want") 48 | ax.bar(idx + .25, y[i][1], width, label="Predicted") 49 | ax.set_title("Bad loss") 50 | ax.axhline(y=np.average(y[i][0][:16]), xmin=0, xmax=.5, c='orange') 51 | ax.axhline(y=np.average(y[i][0][16:]), xmin=.5, xmax=1., c='orange') 52 | 53 | plt.legend() 54 | plt.ylabel("Value") 55 | plt.xlabel("QA Parameter (QUBO size 16x16)") 56 | plt.tight_layout() 57 | plt.show() 58 | -------------------------------------------------------------------------------- /qubo_nn/plots/plot_qubo_map.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import numpy as np 3 | import matplotlib 4 | import matplotlib.pyplot as plt 5 | import matplotlib.colors as colors 6 | import matplotlib as mpl 7 | 8 | 9 | mpl.font_manager._rebuild() 10 | plt.rc('font', family='Raleway') 11 | 12 | 13 | def truncate_colormap(cmapIn='jet', minval=0.0, maxval=1.0, n=100): 14 | '''truncate_colormap(cmapIn='jet', minval=0.0, maxval=1.0, n=100)''' 15 | cmapIn = plt.get_cmap(cmapIn) 16 | 17 | new_cmap = colors.LinearSegmentedColormap.from_list( 18 | 'trunc({n},{a:.2f},{b:.2f})'.format(n=cmapIn.name, a=minval, b=maxval), 19 | cmapIn(np.linspace(minval, maxval, n))) 20 | 21 | return new_cmap 22 | 23 | 24 | with open('qubo_map.pickle', 'rb') as f: 25 | medians, singles = pickle.load(f) 26 | 27 | # Total length is 900k 28 | problems = ["NP", "MC", "MVC", "SP", "M2SAT", "SPP", "GC", "QA", "QK"] 29 | 30 | # Plot. 31 | cmap_mod = truncate_colormap('Greens', minval=.3, maxval=.99) 32 | 33 | 34 | def plot(data, fname): 35 | fig, axs = plt.subplots(3, 3, figsize=(9, 8), constrained_layout=True) 36 | for i in range(3): 37 | for j in range(3): 38 | idx = i * 3 + j 39 | print(idx) 40 | im = axs[i][j].imshow(data[idx], cmap=cmap_mod, vmin=-1, vmax=1) 41 | cbar = axs[i][j].figure.colorbar(im, ax=axs, aspect=60) 42 | axs[i][j].set_title(problems[idx]) 43 | axs[i][j].set_xticks([]) 44 | axs[i][j].set_yticks([]) 45 | fig.savefig(fname + ".png", bbox_inches='tight') 46 | plt.show() 47 | 48 | 49 | plot(medians, "qubo_map_medians") 50 | plot(singles, "qubo_map_singles") 51 | -------------------------------------------------------------------------------- /qubo_nn/plots/plot_tsne.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import matplotlib as mpl 3 | import matplotlib.pyplot as plt 4 | 5 | 6 | mpl.font_manager._rebuild() 7 | plt.rc('font', family='Raleway') 8 | 9 | 10 | problems = ["NP", "MC", "MVC", "SP", "M2SAT", "SPP", "GC", "QA", "QK", "M3SAT", "TSP"] # noqa 11 | 12 | 13 | def plot(small_size=False): 14 | for i in [10, 20, 30, 50, 70, 100, 200, 500, 1000]: 15 | with open('tsne_data%d.pickle' % i, 'rb') as f: 16 | (Y, y) = pickle.load(f) 17 | 18 | vis_x = Y[:, 0] 19 | vis_y = Y[:, 1] 20 | plt.scatter( 21 | vis_x, 22 | vis_y, 23 | c=y, 24 | # cmap=plt.cm.get_cmap("jet", 11), 25 | cmap=plt.cm.get_cmap("Spectral", 11), 26 | marker='.', 27 | s=6 if small_size else 9 28 | ) 29 | plt.clim(-0.5, 10.5) 30 | # plt.title("Perplexity %d" % i) 31 | cbar = plt.colorbar(ticks=list(range(11))) 32 | cbar.ax.set_yticklabels(problems) 33 | plt.tight_layout() 34 | fname = "tsne%d" % i 35 | if small_size: 36 | fname += '_small' 37 | plt.savefig(fname + ".png") 38 | plt.savefig(fname + ".pdf") 39 | plt.show() 40 | 41 | 42 | # plot(True) 43 | plot(False) 44 | -------------------------------------------------------------------------------- /qubo_nn/plots/plot_tsne_100_genX.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import matplotlib as mpl 3 | import matplotlib.pyplot as plt 4 | 5 | 6 | mpl.font_manager._rebuild() 7 | plt.rc('font', family='Raleway') 8 | mpl.rcParams['figure.dpi'] = 200 9 | 10 | 11 | problems = ["NP", "MC", "MVC", "SP", "M2SAT", "SPP", "GC", "QA", "QK", "M3SAT", "TSP", "GI", "SGI", "MCQ"] # noqa 12 | 13 | 14 | def plot(small_size=False): 15 | for i in [10, 20, 30, 50, 70, 100, 200, 500, 1000]: 16 | with open('tsne_100_genX_data%d.pickle' % i, 'rb') as f: 17 | (Y, y) = pickle.load(f) 18 | 19 | vis_x = Y[:, 0] 20 | vis_y = Y[:, 1] 21 | plt.scatter( 22 | vis_x, 23 | vis_y, 24 | c=y, 25 | # cmap=plt.cm.get_cmap("jet", 11), 26 | cmap=plt.cm.get_cmap("Spectral", 14), 27 | marker='.', 28 | s=6 if small_size else 8 # 9 29 | ) 30 | plt.clim(-0.5, 13.5) 31 | ax = plt.gca() 32 | ax.axes.xaxis.set_ticks([]) 33 | ax.axes.yaxis.set_ticks([]) 34 | # plt.title("Perplexity %d" % i) 35 | cbar = plt.colorbar(ticks=list(range(14))) 36 | cbar.ax.set_yticklabels(problems) 37 | plt.tight_layout() 38 | fname = "tsne_100_genX_%d" % i 39 | if small_size: 40 | fname += '_small' 41 | plt.axis('equal') 42 | plt.savefig(fname + ".png") 43 | plt.savefig(fname + ".pdf") 44 | plt.show() 45 | 46 | 47 | # plot(True) 48 | plot(False) 49 | -------------------------------------------------------------------------------- /qubo_nn/plots/plot_tsne_30_gen4.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import matplotlib as mpl 3 | import matplotlib.pyplot as plt 4 | 5 | 6 | mpl.font_manager._rebuild() 7 | plt.rc('font', family='Raleway') 8 | mpl.rcParams['figure.dpi'] = 200 9 | 10 | 11 | problems = ["NP", "MC", "MVC", "SP", "M2SAT", "SPP", "GC", "QA", "QK", "M3SAT", "TSP", "GI", "SGI", "MCQ"] # noqa 12 | 13 | 14 | def plot(small_size=False): 15 | for i in [10, 20, 30, 50, 70, 100, 200, 500, 1000]: 16 | with open('tsne_30_gen4_data%d.pickle' % i, 'rb') as f: 17 | (Y, y) = pickle.load(f) 18 | 19 | vis_x = Y[:, 0] 20 | vis_y = Y[:, 1] 21 | plt.scatter( 22 | vis_x, 23 | vis_y, 24 | c=y, 25 | # cmap=plt.cm.get_cmap("jet", 11), 26 | cmap=plt.cm.get_cmap("Spectral", 14), 27 | marker='.', 28 | s=6 if small_size else 8 # 9 29 | ) 30 | plt.clim(-0.5, 13.5) 31 | # plt.title("Perplexity %d" % i) 32 | cbar = plt.colorbar(ticks=list(range(14))) 33 | cbar.ax.set_yticklabels(problems) 34 | plt.tight_layout() 35 | fname = "tsne_30_gen4_%d" % i 36 | if small_size: 37 | fname += '_small' 38 | plt.axis('equal') 39 | plt.savefig(fname + ".png") 40 | plt.savefig(fname + ".pdf") 41 | plt.show() 42 | 43 | 44 | # plot(True) 45 | plot(False) 46 | -------------------------------------------------------------------------------- /qubo_nn/plots/plot_tsne_gen4.py: -------------------------------------------------------------------------------- 1 | import pickle 2 | import matplotlib as mpl 3 | import matplotlib.pyplot as plt 4 | 5 | 6 | mpl.font_manager._rebuild() 7 | plt.rc('font', family='Raleway') 8 | mpl.rcParams['figure.dpi'] = 200 9 | 10 | 11 | problems = ["NP", "MC", "MVC", "SP", "M2SAT", "SPP", "GC", "QA", "QK", "M3SAT", "TSP"] # noqa 12 | 13 | 14 | def plot(small_size=False): 15 | for i in [10, 20, 30, 50, 70, 100, 200, 500, 1000]: 16 | with open('tsne_gen4_data%d.pickle' % i, 'rb') as f: 17 | (Y, y) = pickle.load(f) 18 | 19 | vis_x = Y[:, 0] 20 | vis_y = Y[:, 1] 21 | plt.scatter( 22 | vis_x, 23 | vis_y, 24 | c=y, 25 | # cmap=plt.cm.get_cmap("jet", 11), 26 | cmap=plt.cm.get_cmap("Spectral", 11), 27 | marker='.', 28 | s=6 if small_size else 8 29 | ) 30 | plt.clim(-0.5, 10.5) 31 | # plt.title("Perplexity %d" % i) 32 | cbar = plt.colorbar(ticks=list(range(11))) 33 | cbar.ax.set_yticklabels(problems) 34 | plt.tight_layout() 35 | fname = "tsne_gen4_%d" % i 36 | if small_size: 37 | fname += '_small' 38 | plt.axis('equal') 39 | plt.savefig(fname + ".png") 40 | plt.savefig(fname + ".pdf") 41 | plt.show() 42 | 43 | 44 | # plot(True) 45 | plot(False) 46 | -------------------------------------------------------------------------------- /qubo_nn/plots/qa_avg_residuals1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_avg_residuals1.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_avg_residuals1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_avg_residuals1.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_avg_residuals2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_avg_residuals2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_avg_residuals2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_avg_residuals2.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_best_99_residual.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_best_99_residual.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_best_99_residual.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_best_99_residual.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_best_99_value.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_best_99_value.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_best_99_value.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_best_99_value.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_comp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_comp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_comp.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_comp.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/qa_comp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_comp.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_comp_datasize.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_comp_datasize.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_comp_datasize.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_comp_datasize.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_comp_special_loss.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_comp_special_loss.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_comp_special_loss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_comp_special_loss.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_debug.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_debug.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/qa_ones.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_ones.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/qa_ones_loss.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_ones_loss.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_ones_loss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_ones_loss.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_ones_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_ones_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_ones_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_ones_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/qa_zeros.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_zeros.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qa_zeros.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_zeros.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/qa_zeros.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qa_zeros.png -------------------------------------------------------------------------------- /qubo_nn/plots/qb.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/qb_qb1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb_qb1.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qb_qb1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb_qb1.png -------------------------------------------------------------------------------- /qubo_nn/plots/qb_qb1_1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb_qb1_1.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qb_qb1_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb_qb1_1.png -------------------------------------------------------------------------------- /qubo_nn/plots/qb_qb2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb_qb2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qb_qb2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb_qb2.png -------------------------------------------------------------------------------- /qubo_nn/plots/qb_qb2_1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb_qb2_1.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qb_qb2_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qb_qb2_1.png -------------------------------------------------------------------------------- /qubo_nn/plots/qk.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qk.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/qk_high.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qk_high.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qk_high.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qk_high.png -------------------------------------------------------------------------------- /qubo_nn/plots/qk_norm.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qk_norm.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/qk_norm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qk_norm.png -------------------------------------------------------------------------------- /qubo_nn/plots/qubo_map.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qubo_map.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/qubo_map_medians.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qubo_map_medians.png -------------------------------------------------------------------------------- /qubo_nn/plots/qubo_map_singles.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/qubo_map_singles.png -------------------------------------------------------------------------------- /qubo_nn/plots/red_ae.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/red_ae.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/red_ae_all.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/red_ae_all.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/red_ae_all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/red_ae_all.png -------------------------------------------------------------------------------- /qubo_nn/plots/red_ae_all_matrix.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/red_ae_all_matrix.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/red_ae_all_matrix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/red_ae_all_matrix.png -------------------------------------------------------------------------------- /qubo_nn/plots/red_ae_np.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/red_ae_np.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/red_ae_np.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/red_ae_np.png -------------------------------------------------------------------------------- /qubo_nn/plots/reverse_loss.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/reverse_loss.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/reverse_loss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/reverse_loss.png -------------------------------------------------------------------------------- /qubo_nn/plots/reverse_losses.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/reverse_losses.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/reverse_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/reverse_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/reverse_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/reverse_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/sim.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/sim_pair.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_pair.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/sim_pair2.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_pair2.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/sim_pair2_sim2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_pair2_sim2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/sim_pair2_sim2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_pair2_sim2.png -------------------------------------------------------------------------------- /qubo_nn/plots/sim_pair_all_matrix.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_pair_all_matrix.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/sim_pair_all_matrix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_pair_all_matrix.png -------------------------------------------------------------------------------- /qubo_nn/plots/sim_pair_sim.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_pair_sim.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/sim_pair_sim.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_pair_sim.png -------------------------------------------------------------------------------- /qubo_nn/plots/sim_sim.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_sim.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/sim_sim.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sim_sim.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_gc.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_gc.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_gc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_gc.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_mc.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_mc.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_mc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_mc.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_mvc.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_mvc.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_mvc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_mvc.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_np.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_np.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_np.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_np.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_qa.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_qa.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_qa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_qa.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_tsp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_tsp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_generalized_tsp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_generalized_tsp.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_gi_sgi_mcq.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_gi_sgi_mcq.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_gi_sgi_mcq_gi.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_gi_sgi_mcq_gi.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_gi_sgi_mcq_gi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_gi_sgi_mcq_gi.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_gi_sgi_mcq_mcq.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_gi_sgi_mcq_mcq.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_gi_sgi_mcq_mcq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_gi_sgi_mcq_mcq.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_gi_sgi_mcq_sgi.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_gi_sgi_mcq_sgi.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_gi_sgi_mcq_sgi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_gi_sgi_mcq_sgi.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_m2sat.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_m2sat.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_m2sat_m2sat.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_m2sat_m2sat.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_m2sat_m2sat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_m2sat_m2sat.png -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_sp.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_sp.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_sp_sp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_sp_sp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/small_arch_sp_sp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/small_arch_sp_sp.png -------------------------------------------------------------------------------- /qubo_nn/plots/sp_loss.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sp_loss.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/sp_loss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sp_loss.png -------------------------------------------------------------------------------- /qubo_nn/plots/sp_sorted.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sp_sorted.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/sp_sorted.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sp_sorted.png -------------------------------------------------------------------------------- /qubo_nn/plots/sp_vars.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sp_vars.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/sp_vars.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sp_vars.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/sp_vars.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/sp_vars.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_100_genX_100_genX.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_100_genX_100_genX.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_100_genX_100_genX.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_100_genX_100_genX.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_100_genX_100_genX.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_100_genX_100_genX.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_100_genX_100_genX_2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_100_genX_100_genX_2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_100_genX_100_genX_2.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_100_genX_100_genX_2.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_100_genX_100_genX_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_100_genX_100_genX_2.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_18_lr2_leaky.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_18_lr2_leaky.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_18_lr2_leaky.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_18_lr2_leaky.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_23.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_23.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_23.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_23.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_27_noscramble_100k.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_27_noscramble_100k.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_27_noscramble_100k.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_27_noscramble_100k.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_27_scramble_100k.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_27_scramble_100k.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_27_scramble_100k.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_27_scramble_100k.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_30_gen4_30_gen4.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_30_gen4_30_gen4.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_30_gen4_30_gen4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_30_gen4_30_gen4.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_30_gen4_30_gen4_scramble.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_30_gen4_30_gen4_scramble.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_30_gen4_30_gen4_scramble.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_30_gen4_30_gen4_scramble.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_gen4_27_gen4.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_gen4_27_gen4.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_gen4_27_gen4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_gen4_27_gen4.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_gen4_27_gen4_scramble.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_gen4_27_gen4_scramble.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tot_mc_gen4_27_gen4_scramble.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_mc_gen4_27_gen4_scramble.png -------------------------------------------------------------------------------- /qubo_nn/plots/tot_misclassifications_18_lr2_leaky.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_misclassifications_18_lr2_leaky.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_misclassifications_23.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_misclassifications_23.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_misclassifications_27_noscramble_100k.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_misclassifications_27_noscramble_100k.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_misclassifications_27_scramble_100k.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_misclassifications_27_scramble_100k.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_misclassifications_30_gen4_30_gen4.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_misclassifications_30_gen4_30_gen4.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_misclassifications_30_gen4_30_gen4_scramble.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_misclassifications_30_gen4_30_gen4_scramble.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_misclassifications_gen4_27_gen4.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_misclassifications_gen4_27_gen4.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tot_misclassifications_gen4_27_gen4_scramble.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tot_misclassifications_gen4_27_gen4_scramble.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne10.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne10.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne10.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne100.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne100.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne100.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne1000.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne1000.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne1000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne1000.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne1000_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne1000_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne1000_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne1000_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne100_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne100_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne100_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne100_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne10_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne10_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne10_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne10_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne20.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne20.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne20.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne200.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne200.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne200.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne200_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne200_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne200_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne200_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne20_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne20_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne20_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne20_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne30.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne30.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne30.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne30_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne30_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne30_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne30_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne50.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne50.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne50.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne50.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne500.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne500.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne500.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne500.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne500_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne500_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne500_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne500_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne50_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne50_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne50_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne50_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne70.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne70.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne70.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne70_small.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne70_small.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne70_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne70_small.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_10.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_10.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_10.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_100.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_100.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_100.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_1000.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_1000.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_1000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_1000.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_20.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_20.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_20.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_200.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_200.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_200.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_30.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_30.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_30.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_50.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_50.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_50.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_50.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_500.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_500.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_500.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_500.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_70.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_70.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_70.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data10.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data10.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data100.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data100.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data1000.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data1000.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data20.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data20.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data200.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data200.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data30.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data30.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data50.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data50.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data500.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data500.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_100_genX_data70.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_100_genX_data70.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_10.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_10.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_10.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_100.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_100.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_100.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_1000.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_1000.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_1000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_1000.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_20.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_20.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_20.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_200.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_200.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_200.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_30.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_30.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_30.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_50.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_50.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_50.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_50.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_500.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_500.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_500.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_500.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_70.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_70.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_70.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data10.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data10.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data100.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data100.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data1000.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data1000.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data20.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data20.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data200.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data200.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data30.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data30.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data50.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data50.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data500.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data500.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_30_gen4_data70.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_30_gen4_data70.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data10.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data10.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data100.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data100.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data1000.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data1000.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data20.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data20.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data200.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data200.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data30.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data30.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data50.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data50.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data500.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data500.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_data70.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_data70.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_10.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_10.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_10.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_100.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_100.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_100.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_1000.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_1000.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_1000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_1000.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_20.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_20.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_20.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_200.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_200.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_200.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_200.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_30.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_30.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_30.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_50.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_50.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_50.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_50.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_500.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_500.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_500.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_500.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_70.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_70.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_70.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data10.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data10.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data100.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data100.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data1000.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data1000.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data20.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data20.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data200.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data200.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data30.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data30.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data50.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data50.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data500.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data500.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsne_gen4_data70.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsne_gen4_data70.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsp_comp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsp_comp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsp_comp.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsp_comp.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tsp_comp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsp_comp.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsp_comp_81.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsp_comp_81.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsp_comp_81.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsp_comp_81.png -------------------------------------------------------------------------------- /qubo_nn/plots/tsp_comp_comp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsp_comp_comp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tsp_comp_comp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tsp_comp_comp.png -------------------------------------------------------------------------------- /qubo_nn/plots/tt1.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tt1.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/tt1_tt1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tt1_tt1.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/tt1_tt1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/tt1_tt1.png -------------------------------------------------------------------------------- /qubo_nn/plots/v4.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4.pickle -------------------------------------------------------------------------------- /qubo_nn/plots/v4_gc.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4_gc.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/v4_gc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4_gc.png -------------------------------------------------------------------------------- /qubo_nn/plots/v4_mvc.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4_mvc.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/v4_mvc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4_mvc.png -------------------------------------------------------------------------------- /qubo_nn/plots/v4_np.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4_np.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/v4_np.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4_np.png -------------------------------------------------------------------------------- /qubo_nn/plots/v4_sp.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4_sp.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/v4_sp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/v4_sp.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_a19_2_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_a19_2_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_a19_2_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_a19_2_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_all.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_all.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_all.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_gc1_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_gc1_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_gc1_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_gc1_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_a19_2_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_a19_2_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_a19_2_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_a19_2_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_a19_2_r22.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_a19_2_r22.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_a19_2_r22.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_a19_2_r22.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_gc1_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_gc1_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_gc1_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_gc1_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_gc1_r22.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_gc1_r22.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_gc1_r22.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_gc1_r22.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_m2sat_16x16_5_F_v2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_m2sat_16x16_5_F_v2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_m2sat_16x16_5_F_v2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_m2sat_16x16_5_F_v2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_m2sat_16x16_5_F_v22.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_m2sat_16x16_5_F_v22.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_m2sat_16x16_5_F_v22.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_m2sat_16x16_5_F_v22.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_mvc3_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_mvc3_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_mvc3_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_mvc3_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_mvc3_r22.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_mvc3_r22.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_mvc3_r22.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_mvc3_r22.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_np19_LONG_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_np19_LONG_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_np19_LONG_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_np19_LONG_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_np19_LONG_r22.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_np19_LONG_r22.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_np19_LONG_r22.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_np19_LONG_r22.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_qa_N_100_norm3.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_qa_N_100_norm3.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_qa_N_100_norm3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_qa_N_100_norm3.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_qa_N_100_norm32.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_qa_N_100_norm32.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_qa_N_100_norm32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_qa_N_100_norm32.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_sp4.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_sp4.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_sp4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_sp4.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_sp42.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_sp42.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_sp42.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_sp42.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_tsp2_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_tsp2_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_tsp2_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_tsp2_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_tsp2_r22.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_tsp2_r22.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_hist_tsp2_r22.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_hist_tsp2_r22.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_m2sat_16x16_5_F_v2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_m2sat_16x16_5_F_v2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_m2sat_16x16_5_F_v2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_m2sat_16x16_5_F_v2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_mvc3_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_mvc3_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_mvc3_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_mvc3_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_np19_LONG_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_np19_LONG_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_np19_LONG_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_np19_LONG_r2.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_qa_N_100_norm3.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_qa_N_100_norm3.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_qa_N_100_norm3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_qa_N_100_norm3.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_sp4.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_sp4.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_sp4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_sp4.png -------------------------------------------------------------------------------- /qubo_nn/plots/weights_tsp2_r2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_tsp2_r2.pdf -------------------------------------------------------------------------------- /qubo_nn/plots/weights_tsp2_r2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/plots/weights_tsp2_r2.png -------------------------------------------------------------------------------- /qubo_nn/problems/__init__.py: -------------------------------------------------------------------------------- 1 | from qubo_nn.problems.number_partitioning import NumberPartitioning 2 | from qubo_nn.problems.max_cut import MaxCut 3 | from qubo_nn.problems.minimum_vertex_cover import MinimumVertexCover 4 | from qubo_nn.problems.set_packing import SetPacking 5 | from qubo_nn.problems.max2sat import Max2SAT 6 | from qubo_nn.problems.set_partitioning import SetPartitioning 7 | from qubo_nn.problems.graph_coloring import GraphColoring 8 | from qubo_nn.problems.quadratic_assignment import QuadraticAssignment 9 | from qubo_nn.problems.quadratic_knapsack import QuadraticKnapsack 10 | from qubo_nn.problems.max3sat import Max3SAT 11 | from qubo_nn.problems.tsp import TSP 12 | from qubo_nn.problems.graph_isomorphism import GraphIsomorphism 13 | from qubo_nn.problems.subgraph_isomorphism import SubGraphIsomorphism 14 | from qubo_nn.problems.max_clique import MaxClique 15 | from qubo_nn.problems.exact_cover import ExactCover 16 | from qubo_nn.problems.binary_integer_linear_programming import BinaryIntegerLinearProgramming # noqa 17 | from qubo_nn.problems.max_independent_set import MaxIndependentSet 18 | from qubo_nn.problems.minimum_maximum_matching import MinimumMaximumMatching 19 | from qubo_nn.problems.set_cover import SetCover 20 | from qubo_nn.problems.knapsack_integer_weights import KnapsackIntegerWeights 21 | 22 | 23 | PROBLEM_REGISTRY = { 24 | "NP": NumberPartitioning, 25 | "MC": MaxCut, 26 | "MVC": MinimumVertexCover, 27 | "SP": SetPacking, 28 | "M2SAT": Max2SAT, 29 | "SPP": SetPartitioning, 30 | "GC": GraphColoring, 31 | "QA": QuadraticAssignment, 32 | "QK": QuadraticKnapsack, 33 | "M3SAT": Max3SAT, 34 | "TSP": TSP, 35 | "GI": GraphIsomorphism, 36 | "SGI": SubGraphIsomorphism, 37 | "MCQ": MaxClique, 38 | "EC": ExactCover, 39 | "BIP": BinaryIntegerLinearProgramming, 40 | "MIS": MaxIndependentSet, 41 | "MMM": MinimumMaximumMatching, 42 | "SC": SetCover, 43 | "KIW": KnapsackIntegerWeights 44 | } 45 | -------------------------------------------------------------------------------- /qubo_nn/problems/graph_coloring.py: -------------------------------------------------------------------------------- 1 | import itertools 2 | import numpy as np 3 | from qubo_nn.problems.problem import Problem 4 | from qubo_nn.problems.util import gen_graph 5 | 6 | 7 | class GraphColoring(Problem): 8 | def __init__(self, cfg, graph, n_colors, P=4): 9 | self.graph = graph 10 | self.n_colors = n_colors 11 | self.P = P 12 | 13 | def gen_qubo_matrix(self): 14 | n = self.graph.order() * self.n_colors 15 | nodes = list(self.graph.nodes) 16 | 17 | Q = np.zeros((n, n)) 18 | 19 | for i in range(n): 20 | Q[i][i] -= self.P 21 | 22 | for i, x in enumerate(nodes): 23 | cols = [i * self.n_colors + c for c in range(self.n_colors)] 24 | tuples = itertools.combinations(cols, 2) 25 | for j, k in tuples: 26 | Q[j][k] += self.P 27 | Q[k][j] += self.P 28 | 29 | for edge in self.graph.edges: 30 | idx1 = nodes.index(edge[0]) 31 | idx2 = nodes.index(edge[1]) 32 | for c in range(self.n_colors): 33 | idx1c = idx1 * self.n_colors + c 34 | idx2c = idx2 * self.n_colors + c 35 | Q[idx1c][idx2c] += self.P / 2. 36 | Q[idx2c][idx1c] += self.P / 2. 37 | return Q 38 | 39 | @classmethod 40 | def gen_problems(self, cfg, n_problems, size, n_colors, seed=None, **kwargs): 41 | graphs = gen_graph(n_problems, size, seed) 42 | return [ 43 | {"graph": graph, "n_colors": n_colors} 44 | for graph in graphs 45 | ] 46 | -------------------------------------------------------------------------------- /qubo_nn/problems/graph_isomorphism.py: -------------------------------------------------------------------------------- 1 | import itertools 2 | import numpy as np 3 | from qubo_nn.problems.subgraph_isomorphism import SubGraphIsomorphism 4 | from qubo_nn.problems.util import gen_graph 5 | 6 | 7 | class GraphIsomorphism(SubGraphIsomorphism): 8 | def __init__(self, cfg, graph1, graph2): 9 | super(GraphIsomorphism, self).__init__(cfg, graph1, graph2, a=1, b=2) 10 | 11 | @classmethod 12 | def gen_problems(self, cfg, n_problems, size, seed=None, **kwargs): 13 | graphs1 = gen_graph(n_problems, size, seed) 14 | graphs2 = gen_graph(n_problems, size, seed) 15 | return [ 16 | {"graph1": graph1, "graph2": graph2} 17 | for graph1, graph2 in zip(graphs1, graphs2) 18 | ] 19 | -------------------------------------------------------------------------------- /qubo_nn/problems/max_clique.py: -------------------------------------------------------------------------------- 1 | import numpy as np 2 | from qubo_nn.problems.problem import Problem 3 | from qubo_nn.problems.util import gen_graph 4 | 5 | 6 | class MaxClique(Problem): 7 | def __init__(self, cfg, graph): 8 | self.graph = graph 9 | 10 | def gen_qubo_matrix(self): 11 | n = self.graph.order() 12 | 13 | Q = np.zeros((n, n)) 14 | 15 | for i in range(n): 16 | for j in range(n): 17 | if i == j: 18 | Q[i][i] = -1 19 | if i < j and (i, j) not in self.graph.edges: 20 | Q[i][j] = 2 21 | Q[j][i] = 2 22 | 23 | return Q 24 | 25 | @classmethod 26 | def gen_problems(self, cfg, n_problems, size, seed=None, **kwargs): 27 | graphs = gen_graph(n_problems, size, seed) 28 | return [{"graph": graph} for graph in graphs] 29 | -------------------------------------------------------------------------------- /qubo_nn/problems/max_cut.py: -------------------------------------------------------------------------------- 1 | import numpy as np 2 | from qubo_nn.problems.problem import Problem 3 | from qubo_nn.problems.util import gen_graph 4 | 5 | 6 | class MaxCut(Problem): 7 | def __init__(self, cfg, graph): 8 | self.graph = graph 9 | 10 | def gen_qubo_matrix(self): 11 | n = self.graph.order() 12 | nodes = list(self.graph.nodes) 13 | 14 | # dtype 'b' would be nice here.. 15 | Q = np.zeros((n, n), dtype=np.dtype(np.int32)) 16 | for edge in self.graph.edges: 17 | idx1 = nodes.index(edge[0]) 18 | idx2 = nodes.index(edge[1]) 19 | Q[idx1][idx1] += 1 20 | Q[idx2][idx2] += 1 21 | Q[idx1][idx2] -= 1 22 | Q[idx2][idx1] -= 1 23 | return -Q 24 | 25 | @classmethod 26 | def gen_problems(self, cfg, n_problems, size, seed=None, **kwargs): 27 | graphs = gen_graph(n_problems, size, seed) 28 | return [{"graph": graph} for graph in graphs] 29 | 30 | 31 | class MaxCutMemoryEfficient(Problem): 32 | def __init__(self, cfg, edge_list, n): 33 | self.edge_list = edge_list 34 | self.n = n 35 | 36 | def gen_qubo_matrix(self): 37 | Q = np.zeros((self.n, self.n), dtype=np.dtype('b')) 38 | for edge in self.edge_list: 39 | idx1 = edge[0] 40 | idx2 = edge[1] 41 | Q[idx1][idx1] += 1 42 | Q[idx2][idx2] += 1 43 | Q[idx1][idx2] -= 1 44 | Q[idx2][idx1] -= 1 45 | return -Q 46 | 47 | @classmethod 48 | def gen_problems(self, cfg, n_problems, size, seed=None, **kwargs): 49 | data = [] 50 | for i in range(n_problems): 51 | if i % 100000 == 0: 52 | print(i) 53 | data.append(list(gen_graph(1, size, seed)[0].edges)) 54 | return [{"edge_list": graph, "n": size[0]} for graph in data] 55 | -------------------------------------------------------------------------------- /qubo_nn/problems/max_independent_set.py: -------------------------------------------------------------------------------- 1 | import numpy as np 2 | from qubo_nn.problems.problem import Problem 3 | from qubo_nn.problems.util import gen_graph 4 | 5 | 6 | class MaxIndependentSet(Problem): 7 | def __init__(self, cfg, graph): 8 | self.graph = graph 9 | 10 | def gen_qubo_matrix(self): 11 | n = self.graph.order() 12 | 13 | Q = np.zeros((n, n)) 14 | 15 | for i in range(n): 16 | for j in range(n): 17 | if i == j: 18 | Q[i][i] = -1 19 | # NOTE: Only difference to MaxClique is in the lines below: 20 | if i < j and (i, j) in self.graph.edges: 21 | Q[i][j] = 1 22 | Q[j][i] = 1 23 | 24 | return Q 25 | 26 | @classmethod 27 | def gen_problems(self, cfg, n_problems, size, seed=None, **kwargs): 28 | graphs = gen_graph(n_problems, size, seed) 29 | return [{"graph": graph} for graph in graphs] 30 | -------------------------------------------------------------------------------- /qubo_nn/problems/minimum_vertex_cover.py: -------------------------------------------------------------------------------- 1 | import numpy as np 2 | from qubo_nn.problems.problem import Problem 3 | from qubo_nn.problems.util import gen_graph 4 | 5 | 6 | class MinimumVertexCover(Problem): 7 | def __init__(self, cfg, graph, P=8): 8 | self.graph = graph 9 | self.P = P 10 | 11 | def gen_qubo_matrix(self): 12 | n = self.graph.order() 13 | nodes = list(self.graph.nodes) 14 | 15 | Q = np.zeros((n, n)) 16 | for i in range(n): 17 | Q[i][i] += 1 18 | 19 | for edge in self.graph.edges: 20 | idx1 = nodes.index(edge[0]) 21 | idx2 = nodes.index(edge[1]) 22 | Q[idx1][idx1] -= self.P 23 | Q[idx2][idx2] -= self.P 24 | Q[idx1][idx2] += self.P / 2. 25 | Q[idx2][idx1] += self.P / 2. 26 | return Q 27 | 28 | @classmethod 29 | def gen_problems(self, cfg, n_problems, size=(20, 25), seed=None, **kwargs): 30 | graphs = gen_graph(n_problems, size, seed) 31 | return [{"graph": graph} for graph in graphs] 32 | -------------------------------------------------------------------------------- /qubo_nn/problems/number_partitioning.py: -------------------------------------------------------------------------------- 1 | import numpy as np 2 | from qubo_nn.problems.problem import Problem 3 | 4 | 5 | class NumberPartitioning(Problem): 6 | def __init__(self, cfg, numbers): 7 | self.numbers = numbers 8 | 9 | def gen_qubo_matrix(self): 10 | n = len(self.numbers) 11 | c = sum(self.numbers) 12 | 13 | Q = np.zeros((n, n)) 14 | for i in range(n): 15 | for j in range(n): 16 | if i == j: 17 | Q[i][j] = self.numbers[i] * (self.numbers[i] - c) 18 | else: 19 | Q[i][j] = self.numbers[i] * self.numbers[j] 20 | return Q 21 | 22 | @classmethod 23 | def gen_problems(self, cfg, n_problems, size=20, **kwargs): 24 | problems = np.random.randint(0, 100, (n_problems, size)) 25 | return [{"numbers": problem} for problem in problems] 26 | -------------------------------------------------------------------------------- /qubo_nn/problems/problem.py: -------------------------------------------------------------------------------- 1 | # TODO: I probably won't use abc here due to a possibility of using Cython. 2 | 3 | class Problem: 4 | def gen_qubo_matrix(self): 5 | pass 6 | 7 | # TODO Make sure overriding this works. 8 | @classmethod 9 | def gen_problems(self, cfg, n_problems, size=20, **kwargs): 10 | pass 11 | -------------------------------------------------------------------------------- /qubo_nn/problems/set_partitioning.py: -------------------------------------------------------------------------------- 1 | import random 2 | import itertools 3 | import numpy as np 4 | from qubo_nn.problems.problem import Problem 5 | 6 | 7 | class SetPartitioning(Problem): 8 | def __init__(self, cfg, set_, subsets, costs, P=10): 9 | self.set_ = set_ 10 | self.subsets = subsets 11 | self.costs = costs 12 | self.P = P 13 | 14 | def gen_qubo_matrix(self): 15 | n = len(self.subsets) 16 | Q = np.zeros((n, n)) 17 | 18 | for i in range(n): 19 | Q[i][i] += self.costs[i] 20 | 21 | for x in self.set_: 22 | curr_binary_rule = [] 23 | for i, subset in enumerate(self.subsets): 24 | if x in subset: 25 | curr_binary_rule.append(i) 26 | 27 | for i in curr_binary_rule: 28 | Q[i][i] -= self.P * 2 29 | 30 | tuples = itertools.product(curr_binary_rule, repeat=2) 31 | for j, k in tuples: 32 | if j == k: 33 | Q[j][j] += self.P 34 | else: 35 | Q[j][k] += self.P / 2. 36 | Q[k][j] += self.P / 2. 37 | 38 | return Q 39 | 40 | @classmethod 41 | def gen_problems(self, cfg, n_problems, size=(20, 25), max_cost=10, **kwargs): 42 | problems = [] 43 | set_ = list(range(size[0])) 44 | for _ in range(n_problems): 45 | subsets = [] 46 | costs = [] 47 | for _ in range(size[1]): 48 | x = list(filter(lambda x: random.random() < 0.5, set_)) 49 | subsets.append(x) 50 | costs.append(int(random.random() * max_cost)) 51 | problems.append((set_, subsets, costs)) 52 | return [ 53 | {"set_": set_, "subsets": subsets, "costs": costs} 54 | for (set_, subsets, costs) in problems 55 | ] 56 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/instance01/qubo-nn/6f8058565f4b6ab4a8300501fc2f67cdaeed482f/qubo_nn/problems/test/__init__.py -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_exact_cover.py: -------------------------------------------------------------------------------- 1 | import random 2 | import unittest 3 | from qubo_nn.problems import ExactCover 4 | 5 | 6 | class TestExactCover(unittest.TestCase): 7 | def test_gen_qubo_matrix(self): 8 | """Test whether a correct QUBO is generated. 9 | 10 | Test case from: My brain. 11 | """ 12 | set_ = [0, 1, 2, 3, 4] 13 | subsets = [[0, 1], [2], [3, 4], [4]] 14 | problem = ExactCover( 15 | {"problems": {"EC": {}}}, 16 | ExactCover.gen_matrix(set_, subsets) 17 | ) 18 | matrix = problem.gen_qubo_matrix() 19 | want = [ 20 | [-4., 0., 0., 0.], 21 | [0., -2., 0., 0.], 22 | [0., 0., -2., 1.], 23 | [0., 0., 1., 0.] 24 | ] 25 | self.assertCountEqual(matrix.tolist(), want) 26 | 27 | def test_gen_problems(self): 28 | st0 = random.getstate() 29 | random.seed(1) 30 | data = ExactCover.gen_problems( 31 | {"problems": {"EC": {}}}, 32 | 1, 33 | size=(10, 10) 34 | ) 35 | random.setstate(st0) 36 | subset_matrix_want = [ 37 | [1., 1., 1., 1., 1., 1., 0., 0., 0., 0.], 38 | [1., 1., 0., 0., 0., 0., 1., 1., 0., 0.], 39 | [1., 1., 0., 0., 0., 0., 0., 0., 1., 0.], 40 | [1., 0., 1., 1., 0., 0., 1., 0., 1., 1.], 41 | [1., 0., 1., 1., 1., 0., 1., 0., 0., 0.], 42 | [1., 0., 1., 1., 1., 0., 0., 0., 0., 0.], 43 | [0., 1., 1., 0., 0., 1., 1., 0., 0., 0.], 44 | [0., 1., 1., 0., 0., 1., 0., 0., 1., 1.], 45 | [0., 0., 1., 1., 0., 0., 0., 0., 0., 1.], 46 | [1., 0., 1., 1., 1., 1., 1., 1., 0., 0.] 47 | ] 48 | 49 | self.assertCountEqual( 50 | data[0]["subset_matrix"].tolist(), 51 | subset_matrix_want 52 | ) 53 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_graph_coloring.py: -------------------------------------------------------------------------------- 1 | import unittest 2 | import networkx 3 | from qubo_nn.problems import GraphColoring 4 | 5 | 6 | class TestGraphColoring(unittest.TestCase): 7 | def test_gen_qubo_matrix(self): 8 | """Test whether a correct QUBO is generated. 9 | 10 | Test case from: https://arxiv.org/pdf/1811.11538.pdf 11 | """ 12 | graph = networkx.Graph( 13 | [(1, 2), (2, 3), (3, 4), (2, 5), (1, 5), (4, 5), (4, 2)] 14 | ) 15 | problem = GraphColoring({}, graph, 3) 16 | matrix = problem.gen_qubo_matrix() 17 | want = [ 18 | [-4., 4., 4., 2., 0., 0., 0., 0., 0., 0., 0., 0., 2., 0., 0.], 19 | [ 4.,-4., 4., 0., 2., 0., 0., 0., 0., 0., 0., 0., 0., 2., 0.], 20 | [ 4., 4.,-4., 0., 0., 2., 0., 0., 0., 0., 0., 0., 0., 0., 2.], 21 | [ 2., 0., 0.,-4., 4., 4., 2., 0., 0., 2., 0., 0., 2., 0., 0.], 22 | [ 0., 2., 0., 4.,-4., 4., 0., 2., 0., 0., 2., 0., 0., 2., 0.], 23 | [ 0., 0., 2., 4., 4.,-4., 0., 0., 2., 0., 0., 2., 0., 0., 2.], 24 | [ 0., 0., 0., 2., 0., 0.,-4., 4., 4., 2., 0., 0., 0., 0., 0.], 25 | [ 0., 0., 0., 0., 2., 0., 4.,-4., 4., 0., 2., 0., 0., 0., 0.], 26 | [ 0., 0., 0., 0., 0., 2., 4., 4.,-4., 0., 0., 2., 0., 0., 0.], 27 | [ 0., 0., 0., 2., 0., 0., 2., 0., 0.,-4., 4., 4., 2., 0., 0.], 28 | [ 0., 0., 0., 0., 2., 0., 0., 2., 0., 4.,-4., 4., 0., 2., 0.], 29 | [ 0., 0., 0., 0., 0., 2., 0., 0., 2., 4., 4.,-4., 0., 0., 2.], 30 | [ 2., 0., 0., 2., 0., 0., 0., 0., 0., 2., 0., 0.,-4., 4., 4.], 31 | [ 0., 2., 0., 0., 2., 0., 0., 0., 0., 0., 2., 0., 4.,-4., 4.], 32 | [ 0., 0., 2., 0., 0., 2., 0., 0., 0., 0., 0., 2., 4., 4.,-4.] 33 | ] 34 | self.assertCountEqual(matrix.tolist(), want) 35 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_graph_isomorphism.py: -------------------------------------------------------------------------------- 1 | import unittest 2 | 3 | import networkx 4 | import numpy as np 5 | 6 | from qubo_nn.problems import GraphIsomorphism 7 | 8 | 9 | class TestGraphIsomorphism(unittest.TestCase): 10 | def test_gen_qubo_matrix(self): 11 | """Test whether a correct QUBO is generated. 12 | 13 | Test case from: https://researchspace.auckland.ac.nz/bitstream/handle/2292/31756/CDMTCS499.pdf?sequence=1 14 | """ 15 | graph1 = networkx.Graph( 16 | [(0, 1), (1, 2)] 17 | ) 18 | graph2 = networkx.Graph( 19 | [(0, 1), (0, 2)] 20 | ) 21 | problem = GraphIsomorphism({}, graph1, graph2) 22 | matrix = problem.gen_qubo_matrix() 23 | want = [ 24 | [ 25 | [-2.0, 2.0, 2.0, 4.0, 0.0, 0.0, 2.0, 0.0, 0.0], 26 | [2.0, -2.0, 2.0, 0.0, 4.0, 2.0, 0.0, 2.0, 0.0], 27 | [2.0, 2.0, -2.0, 0.0, 2.0, 4.0, 0.0, 0.0, 2.0], 28 | [4.0, 0.0, 0.0, -2.0, 2.0, 2.0, 4.0, 0.0, 0.0], 29 | [0.0, 4.0, 2.0, 2.0, -2.0, 2.0, 0.0, 4.0, 2.0], 30 | [0.0, 2.0, 4.0, 2.0, 2.0, -2.0, 0.0, 2.0, 4.0], 31 | [2.0, 0.0, 0.0, 4.0, 0.0, 0.0, -2.0, 2.0, 2.0], 32 | [0.0, 2.0, 0.0, 0.0, 4.0, 2.0, 2.0, -2.0, 2.0], 33 | [0.0, 0.0, 2.0, 0.0, 2.0, 4.0, 2.0, 2.0, -2.0] 34 | ] 35 | ] 36 | self.assertTrue(np.allclose(matrix, want)) 37 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_max_clique.py: -------------------------------------------------------------------------------- 1 | import unittest 2 | import networkx 3 | from qubo_nn.problems import MaxClique 4 | 5 | 6 | class TestMaxClique(unittest.TestCase): 7 | def test_gen_qubo_matrix(self): 8 | """Test whether a correct QUBO is generated. 9 | 10 | Test case from: My brain. 11 | """ 12 | graph = networkx.Graph( 13 | [(0, 1), (1, 2), (2, 3), (3, 4), (4, 5)] 14 | ) 15 | problem = MaxClique({}, graph) 16 | matrix = problem.gen_qubo_matrix() 17 | want = [ 18 | [-1., 0., 2., 2., 2., 2.], 19 | [ 0., -1., 0., 2., 2., 2.], 20 | [ 2., 0., -1., 0., 2., 2.], 21 | [ 2., 2., 0., -1., 0., 2.], 22 | [ 2., 2., 2., 0., -1., 0.], 23 | [ 2., 2., 2., 2., 0., -1.] 24 | ] 25 | self.assertCountEqual(matrix.tolist(), want) 26 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_max_independent_set.py: -------------------------------------------------------------------------------- 1 | import unittest 2 | import networkx 3 | from qubo_nn.problems import MaxIndependentSet 4 | 5 | 6 | class TestMaxIndependentSet(unittest.TestCase): 7 | def test_gen_qubo_matrix(self): 8 | """Test whether a correct QUBO is generated. 9 | 10 | Test case from: My brain. 11 | """ 12 | graph = networkx.Graph( 13 | [(0, 1), (1, 2), (2, 3), (3, 4), (4, 5)] 14 | ) 15 | problem = MaxIndependentSet({}, graph) 16 | matrix = problem.gen_qubo_matrix() 17 | want = [ 18 | [-1.0, 1.0, 0.0, 0.0, 0.0, 0.0], 19 | [1.0, -1.0, 1.0, 0.0, 0.0, 0.0], 20 | [0.0, 1.0, -1.0, 1.0, 0.0, 0.0], 21 | [0.0, 0.0, 1.0, -1.0, 1.0, 0.0], 22 | [0.0, 0.0, 0.0, 1.0, -1.0, 1.0], 23 | [0.0, 0.0, 0.0, 0.0, 1.0, -1.0] 24 | ] 25 | self.assertCountEqual(matrix.tolist(), want) 26 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_minimum_maximum_matching.py: -------------------------------------------------------------------------------- 1 | import copy 2 | import unittest 3 | import networkx 4 | from qubo_nn.problems import MinimumMaximumMatching 5 | 6 | 7 | class TestMaxCut(unittest.TestCase): 8 | def test_gen_qubo_matrix(self): 9 | """Test whether a correct QUBO is generated. 10 | 11 | Test case from: https://arxiv.org/pdf/1811.11538.pdf 12 | """ 13 | graph = networkx.Graph( 14 | [(0, 1), (0, 2), (0, 3), (1, 3), (2, 3)] 15 | ) 16 | want = [ 17 | [-15, 9, 11, 11, 6], 18 | [9, -15, 11, 6, 11], 19 | [11, 11, -19, 11, 11], 20 | [11, 6, 11, -15, 9], 21 | [6, 11, 11, 9, -15] 22 | ] 23 | 24 | problem = MinimumMaximumMatching({}, copy.deepcopy(graph)) 25 | matrix = problem.gen_qubo_matrix() 26 | self.assertCountEqual(matrix.tolist(), want) 27 | 28 | def test_gen_problems(self): 29 | data = MinimumMaximumMatching.gen_problems( 30 | {}, 1, size=(20, 25), seed=1 31 | ) 32 | self.assertCountEqual(data[0]["graph"].edges, [ 33 | (0, 12), (0, 14), (0, 10), (0, 17), (0, 13), (0, 9), (2, 8), 34 | (3, 15), (3, 18), (3, 5), (3, 9), (4, 18), (6, 12), (6, 9), (7, 8), 35 | (7, 16), (7, 17), (7, 11), (7, 14), (9, 18), (10, 16), (13, 19), 36 | (13, 17), (13, 16), (14, 15) 37 | ]) 38 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_minimum_vertex_cover.py: -------------------------------------------------------------------------------- 1 | import unittest 2 | import networkx 3 | from qubo_nn.problems import MinimumVertexCover 4 | 5 | 6 | class TestMinimumVertexCover(unittest.TestCase): 7 | def test_gen_qubo_matrix(self): 8 | """Test whether a correct QUBO is generated. 9 | 10 | Test case from: https://arxiv.org/pdf/1811.11538.pdf 11 | """ 12 | graph = networkx.Graph( 13 | [(1, 2), (1, 3), (2, 4), (3, 4), (4, 5), (3, 5)] 14 | ) 15 | problem = MinimumVertexCover({}, graph) 16 | matrix = problem.gen_qubo_matrix() 17 | want = [ 18 | [-15, 4, 4, 0, 0], 19 | [4, -15, 0, 4, 0], 20 | [4, 0, -23, 4, 4], 21 | [0, 4, 4, -23, 4], 22 | [0, 0, 4, 4, -15] 23 | ] 24 | self.assertCountEqual(matrix.tolist(), want) 25 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_number_partitioning.py: -------------------------------------------------------------------------------- 1 | import unittest 2 | import numpy as np 3 | from qubo_nn.problems import NumberPartitioning 4 | 5 | 6 | class TestNumberPartitioning(unittest.TestCase): 7 | def test_gen_qubo_matrix(self): 8 | """Test whether a correct QUBO is generated. 9 | 10 | Test case from: https://arxiv.org/pdf/1811.11538.pdf 11 | """ 12 | problem = NumberPartitioning({}, [25, 7, 13, 31, 42, 17, 21, 10]) 13 | matrix = problem.gen_qubo_matrix() 14 | want = [ 15 | [-3525, 175, 325, 775, 1050, 425, 525, 250], 16 | [175, -1113, 91, 217, 294, 119, 147, 70], 17 | [325, 91, -1989, 403, 546, 221, 273, 130], 18 | [775, 217, 403, -4185, 1302, 527, 651, 310], 19 | [1050, 294, 546, 1302, -5208, 714, 882, 420], 20 | [425, 119, 221, 527, 714, -2533, 357, 170], 21 | [525, 147, 273, 651, 882, 357, -3045, 210], 22 | [250, 70, 130, 310, 420, 170, 210, -1560], 23 | ] 24 | self.assertCountEqual(matrix.tolist(), want) 25 | 26 | def test_gen_problems(self): 27 | st0 = np.random.get_state() 28 | np.random.seed(1) 29 | data = NumberPartitioning.gen_problems({}, 1, size=20) 30 | np.random.set_state(st0) 31 | self.assertCountEqual( 32 | data[0]["numbers"].tolist(), 33 | [ 34 | 37, 12, 72, 9, 75, 5, 79, 64, 16, 1, 76, 71, 6, 25, 50, 20, 18, 35 | 84, 11, 28 36 | ] 37 | ) 38 | -------------------------------------------------------------------------------- /qubo_nn/problems/test/test_subgraph_isomorphism.py: -------------------------------------------------------------------------------- 1 | import unittest 2 | 3 | import networkx 4 | 5 | from qubo_nn.problems import SubGraphIsomorphism 6 | 7 | 8 | class TestSubGraphIsomorphism(unittest.TestCase): 9 | def test_gen_qubo_matrix(self): 10 | """Test whether a correct QUBO is generated. 11 | 12 | Test case from: My brain. Tested whether solution is sensible with 13 | qbsolv. 14 | """ 15 | graph1 = networkx.Graph( 16 | [(0, 1), (1, 2)] 17 | ) 18 | graph2 = networkx.Graph( 19 | [(0, 1), (0, 2), (2, 3)] 20 | ) 21 | problem = SubGraphIsomorphism({}, graph1, graph2) 22 | matrix = problem.gen_qubo_matrix() 23 | want = [ 24 | [-2., 2., 2., 2., 4., 0., 0., 2., 2., 0., 0., 0.], 25 | [ 2., -2., 2., 2., 0., 4., 2., 2., 0., 2., 0., 0.], 26 | [ 2., 2., -2., 2., 0., 2., 4., 0., 0., 0., 2., 0.], 27 | [ 2., 2., 2., -2., 2., 2., 0., 4., 0., 0., 0., 2.], 28 | [ 4., 0., 0., 2., -2., 2., 2., 2., 4., 0., 0., 2.], 29 | [ 0., 4., 2., 2., 2., -2., 2., 2., 0., 4., 2., 2.], 30 | [ 0., 2., 4., 0., 2., 2., -2., 2., 0., 2., 4., 0.], 31 | [ 2., 2., 0., 4., 2., 2., 2., -2., 2., 2., 0., 4.], 32 | [ 2., 0., 0., 0., 4., 0., 0., 2., -2., 2., 2., 2.], 33 | [ 0., 2., 0., 0., 0., 4., 2., 2., 2., -2., 2., 2.], 34 | [ 0., 0., 2., 0., 0., 2., 4., 0., 2., 2., -2., 2.], 35 | [ 0., 0., 0., 2., 2., 2., 0., 4., 2., 2., 2., -2.] 36 | ] 37 | self.assertCountEqual(matrix.tolist(), want) 38 | -------------------------------------------------------------------------------- /qubo_nn/problems/util.py: -------------------------------------------------------------------------------- 1 | from networkx.generators.random_graphs import gnm_random_graph 2 | 3 | 4 | def gen_graph(n_problems, size, seed=None): 5 | if seed is not None: 6 | return [ 7 | gnm_random_graph(*size, seed=seed) 8 | for _ in range(n_problems) 9 | ] 10 | return [gnm_random_graph(*size) for _ in range(n_problems)] 11 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | https://github.com/vicolab/ml-pyxis/archive/master.zip 2 | numpy 3 | networkx 4 | torchvision 5 | torch 6 | dwave-qbsolv 7 | tensorboard 8 | -------------------------------------------------------------------------------- /setup.cfg: -------------------------------------------------------------------------------- 1 | [metadata] 2 | description-file = README.md 3 | -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | from setuptools import setup 2 | from setuptools import find_packages 3 | 4 | setup( 5 | name='qubo-nn', 6 | version='0.2.5', 7 | install_requires=[ 8 | 'numpy', 'networkx', 'torchvision', 'torch', 'dwave-qbsolv', 9 | 'qubovert', 'matplotlib', 'scipy', 'tensorflow', 'sklearn', 10 | 'tensorboard', 'ml-pyxis', 11 | ], 12 | long_description_content_type='text/markdown', 13 | description='QUBO translations for 14 problems. Also: Reverse-engeering ' 14 | 'and AutoEncoders for QUBOs.', 15 | url='https://github.com/instance01/qubo-nn', 16 | author='Instance01', 17 | author_email='whodis@instancedev.com', 18 | license='MIT', 19 | packages=find_packages(), 20 | classifiers=[ 21 | 'Development Status :: 3 - Alpha', 22 | 'License :: OSI Approved :: MIT License', 23 | 'Programming Language :: Python :: 3', 24 | 'Topic :: Utilities', 25 | 'Topic :: Scientific/Engineering :: Physics', 26 | 'Topic :: Software Development :: Libraries', 27 | 'Topic :: Scientific/Engineering :: Artificial Intelligence', 28 | 'Intended Audience :: Science/Research' 29 | ], 30 | long_description=open('README.md').read(), 31 | zip_safe=False) 32 | -------------------------------------------------------------------------------- /test.sh: -------------------------------------------------------------------------------- 1 | python3 -m unittest 2 | --------------------------------------------------------------------------------