eqc-models 0.15.0__tar.gz → 0.15.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (194) hide show
  1. {eqc_models-0.15.0 → eqc_models-0.15.1}/.gitignore +1 -1
  2. {eqc_models-0.15.0 → eqc_models-0.15.1}/PKG-INFO +1 -1
  3. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/source/dependencies.rst +1 -1
  4. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/algorithms/alm.py +189 -23
  5. eqc_models-0.15.1/eqc_models/ml/utils.py +132 -0
  6. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models.egg-info/PKG-INFO +1 -1
  7. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models.egg-info/SOURCES.txt +2 -0
  8. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/qboost_iris_dirac3.py +22 -32
  9. eqc_models-0.15.1/scripts/test_reservoir.py +48 -0
  10. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testalm.py +78 -59
  11. {eqc_models-0.15.0 → eqc_models-0.15.1}/.gitlab-ci.yml +0 -0
  12. {eqc_models-0.15.0 → eqc_models-0.15.1}/LICENSE.txt +0 -0
  13. {eqc_models-0.15.0 → eqc_models-0.15.1}/MANIFEST.in +0 -0
  14. {eqc_models-0.15.0 → eqc_models-0.15.1}/README.md +0 -0
  15. {eqc_models-0.15.0 → eqc_models-0.15.1}/compile_extensions.py +0 -0
  16. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/Makefile +0 -0
  17. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/basic.css +0 -0
  18. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/css/badge_only.css +0 -0
  19. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/css/theme.css +0 -0
  20. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/custom.css +0 -0
  21. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/file.png +0 -0
  22. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/minus.png +0 -0
  23. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/plus.png +0 -0
  24. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/pygments.css +0 -0
  25. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/build/html/_static/white_logo.png +0 -0
  26. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/make.bat +0 -0
  27. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/source/_static/custom.css +0 -0
  28. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/source/_static/white_logo.png +0 -0
  29. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/source/conf.py +0 -0
  30. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/source/eqc_models.rst +0 -0
  31. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/source/index.rst +0 -0
  32. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/source/modules.rst +0 -0
  33. {eqc_models-0.15.0 → eqc_models-0.15.1}/docs/source/usage.rst +0 -0
  34. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/__init__.py +0 -0
  35. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/algorithms/__init__.py +0 -0
  36. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/algorithms/base.py +0 -0
  37. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/algorithms/penaltymultiplier.py +0 -0
  38. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/allocation/__init__.py +0 -0
  39. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/allocation/allocation.py +0 -0
  40. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/allocation/portbase.py +0 -0
  41. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/allocation/portmomentum.py +0 -0
  42. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/assignment/__init__.py +0 -0
  43. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/assignment/qap.py +0 -0
  44. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/assignment/resource.py +0 -0
  45. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/assignment/setpartition.py +0 -0
  46. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/__init__.py +0 -0
  47. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/base.py +0 -0
  48. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/binaries.py +0 -0
  49. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/constraints.py +0 -0
  50. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/operators.py +0 -0
  51. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/polyeval.pyx +0 -0
  52. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/polynomial.py +0 -0
  53. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/quadratic.py +0 -0
  54. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/base/results.py +0 -0
  55. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/combinatorics/__init__.py +0 -0
  56. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/combinatorics/setcover.py +0 -0
  57. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/combinatorics/setpartition.py +0 -0
  58. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/decoding.py +0 -0
  59. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/graph/__init__.py +0 -0
  60. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/graph/base.py +0 -0
  61. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/graph/hypergraph.py +0 -0
  62. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/graph/maxcut.py +0 -0
  63. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/graph/maxkcut.py +0 -0
  64. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/graph/partition.py +0 -0
  65. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/graph/rcshortestpath.py +0 -0
  66. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/graph/shortestpath.py +0 -0
  67. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/__init__.py +0 -0
  68. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/classifierbase.py +0 -0
  69. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/classifierqboost.py +0 -0
  70. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/classifierqsvm.py +0 -0
  71. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/clustering.py +0 -0
  72. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/clusteringbase.py +0 -0
  73. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/cvqboost_hamiltonian.pyx +0 -0
  74. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/cvqboost_hamiltonian_c_func.c +0 -0
  75. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/cvqboost_hamiltonian_c_func.h +0 -0
  76. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/decomposition.py +0 -0
  77. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/forecast.py +0 -0
  78. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/forecastbase.py +0 -0
  79. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/regressor.py +0 -0
  80. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/regressorbase.py +0 -0
  81. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/ml/reservoir.py +0 -0
  82. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/process/base.py +0 -0
  83. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/process/mpc.py +0 -0
  84. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/sequence/__init__.py +0 -0
  85. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/sequence/tsp.py +0 -0
  86. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/solvers/__init__.py +0 -0
  87. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/solvers/eqcdirect.py +0 -0
  88. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/solvers/mip.py +0 -0
  89. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/solvers/qciclient.py +0 -0
  90. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/solvers/responselog.py +0 -0
  91. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/utilities/__init__.py +0 -0
  92. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/utilities/fileio.py +0 -0
  93. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/utilities/general.py +0 -0
  94. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/utilities/polynomial.py +0 -0
  95. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models/utilities/qplib.py +0 -0
  96. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models.egg-info/dependency_links.txt +0 -0
  97. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models.egg-info/requires.txt +0 -0
  98. {eqc_models-0.15.0 → eqc_models-0.15.1}/eqc_models.egg-info/top_level.txt +0 -0
  99. {eqc_models-0.15.0 → eqc_models-0.15.1}/pyproject.toml +0 -0
  100. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/ALM_pipeline.ipynb +0 -0
  101. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/binary_job_example.py +0 -0
  102. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/binary_w_continuous_solver_example.py +0 -0
  103. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/c6h6_graph_clustering.py +0 -0
  104. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/clustering.py +0 -0
  105. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/continuous_job_example.py +0 -0
  106. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/convert_to_json_problem.py +0 -0
  107. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/crew_assignment_example.py +0 -0
  108. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/graph_clustering.py +0 -0
  109. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/graph_partitioning.py +0 -0
  110. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/hamiltonian_to_polynomial.py +0 -0
  111. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/hypergraph.py +0 -0
  112. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/integer_job_example.py +0 -0
  113. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/karate_graph_clustering.py +0 -0
  114. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/lin_reg_dirac3.py +0 -0
  115. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/mackey_glass_cell_production_series.csv +0 -0
  116. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/mip_example.py +0 -0
  117. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/pca_iris_dirac3.py +0 -0
  118. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/port_opt_dirac3.py +0 -0
  119. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/qboost_iris_dirac3_weak_cls.py +0 -0
  120. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/qplib_benchmark_config.py +0 -0
  121. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/qplib_reader.py +0 -0
  122. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/qplib_runner.py +0 -0
  123. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/qsvm_dual_iris_dirac3.py +0 -0
  124. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/qsvm_iris_dirac3.py +0 -0
  125. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/reservoir_forecast.py +0 -0
  126. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/results_example.py +0 -0
  127. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/rundoctests.py +0 -0
  128. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/test_shortestpath.py +0 -0
  129. {eqc_models-0.15.0 → eqc_models-0.15.1}/scripts/utils.py +0 -0
  130. {eqc_models-0.15.0 → eqc_models-0.15.1}/setup.cfg +0 -0
  131. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/doctest_base.py +0 -0
  132. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testallocationmodel.py +0 -0
  133. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testconstraint.py +0 -0
  134. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testcvqboost.py +0 -0
  135. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testeqcdirectsolver.py +0 -0
  136. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testgraphpartitionmodel.py +0 -0
  137. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testhypergraphmodel.py +0 -0
  138. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testmaxcutmodel.py +0 -0
  139. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testpolynomialmodel.py +0 -0
  140. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testqapmodel.py +0 -0
  141. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testqciclientsolver.py +0 -0
  142. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testquadraticmodel.py +0 -0
  143. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testsetcovermodel.py +0 -0
  144. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testsetpartitionmodel.py +0 -0
  145. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testshortestpath.py +0 -0
  146. {eqc_models-0.15.0 → eqc_models-0.15.1}/test/testtsp.py +0 -0
  147. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/README.txt +0 -0
  148. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/run_tests.py +0 -0
  149. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/c6h6_graph_clustering/c6h6_graph_clustering.py +0 -0
  150. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/clustering/clustering.py +0 -0
  151. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/clustering/data/X.npy +0 -0
  152. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/cvqboost_iris/cvqboost_iris.py +0 -0
  153. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/cvqboost_iris/data/X_test.npy +0 -0
  154. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/cvqboost_iris/data/X_train.npy +0 -0
  155. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/cvqboost_iris/data/y_test.npy +0 -0
  156. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/cvqboost_iris/data/y_train.npy +0 -0
  157. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/karate_graph_clustering/karate_graph_clustering.py +0 -0
  158. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/pca_iris/pca_iris.py +0 -0
  159. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1MJC/data/C_1MJC.npy +0 -0
  160. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1MJC/data/J_1MJC.npy +0 -0
  161. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1MJC/protein_design_1MJC.py +0 -0
  162. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1NXB/data/C_1NXB.npy +0 -0
  163. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1NXB/data/J_1NXB.npy +0 -0
  164. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1NXB/protein_design_1NXB.py +0 -0
  165. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1POH/data/C_1POH.npy +0 -0
  166. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1POH/data/J_1POH.npy +0 -0
  167. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/protein_design_1POH/protein_design_1POH.py +0 -0
  168. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_dual_iris/data/X_test.npy +0 -0
  169. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_dual_iris/data/X_train.npy +0 -0
  170. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_dual_iris/data/y_test.npy +0 -0
  171. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_dual_iris/data/y_train.npy +0 -0
  172. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_dual_iris/qsvm_dual_iris.py +0 -0
  173. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_primal_iris/data/X_test.npy +0 -0
  174. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_primal_iris/data/X_train.npy +0 -0
  175. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_primal_iris/data/y_test.npy +0 -0
  176. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_primal_iris/data/y_train.npy +0 -0
  177. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/qsvm_primal_iris/qsvm_primal_iris.py +0 -0
  178. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_100/data/C_8000000_100.npy +0 -0
  179. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_100/data/J_8000000_100.npy +0 -0
  180. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_100/synthetic_cls_100.py +0 -0
  181. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_300/data/C_8000000_300.npy +0 -0
  182. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_300/data/J_8000000_300.npy +0 -0
  183. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_300/synthetic_cls_300.py +0 -0
  184. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_500/data/C_8000000_500.npy +0 -0
  185. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_500/data/J_8000000_500.npy +0 -0
  186. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_500/synthetic_cls_500.py +0 -0
  187. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_700/data/C_8000000_700.npy +0 -0
  188. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_700/data/J_8000000_700.npy +0 -0
  189. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_700/synthetic_cls_700.py +0 -0
  190. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_900/data/C_8000000_900.npy +0 -0
  191. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_900/data/J_8000000_900.npy +0 -0
  192. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_cases/synthetic_cls_900/synthetic_cls_900.py +0 -0
  193. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_suite_config.json +0 -0
  194. {eqc_models-0.15.0 → eqc_models-0.15.1}/test_suite/test_utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  __pycache__
2
2
  build
3
3
  eqc_models.egg-info
4
-
4
+ scripts/test_reservoir.py
5
5
  *.c
6
6
  *.so
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: eqc-models
3
- Version: 0.15.0
3
+ Version: 0.15.1
4
4
  Summary: Optimization and ML modeling package targeting EQC devices
5
5
  Author-email: "Quantum Computing Inc." <support@quantumcomputinginc.com>
6
6
  Project-URL: Homepage, https://quantumcomputinginc.com
@@ -13,5 +13,5 @@ Packages
13
13
  - ``pandas >=2.1.0, <3``
14
14
  - ``scikit-learn >=1.2.1, <2``
15
15
  - ``lightgbm >= 4.6.0, <5``
16
- - ``xgboost >= 1.7.4, <2``
16
+ - ``xgboost >= 1.7.4, <4``
17
17
  - ``qci-client>=5, <6``
@@ -2,6 +2,7 @@
2
2
  from dataclasses import dataclass
3
3
  from typing import Callable, Dict, List, Tuple, Optional, Sequence, Union
4
4
  import numpy as np
5
+ from collections import defaultdict
5
6
  from eqc_models.base.polynomial import PolynomialModel
6
7
 
7
8
  Array = np.ndarray
@@ -176,10 +177,90 @@ class ALMAlgorithm:
176
177
  merged.append(((0, i + 1), float(ci)))
177
178
  return merged
178
179
 
180
+ @staticmethod
181
+ def _block_offsets(blocks: List[ALMBlock]) -> List[int]:
182
+ """
183
+ Return starting offsets (0-based) for each lifted block in the
184
+ concatenated s-vector.
185
+ """
186
+ offs, pos = [], 0
187
+ for blk in blocks:
188
+ offs.append(pos)
189
+ pos += len(blk.levels) # each block contributes k lifted coordinates
190
+ return offs
191
+
192
+ @staticmethod
193
+ def lift_Qc_to_poly_terms(
194
+ Q_native: np.ndarray, # shape (m, m) over original discrete vars (one block per var)
195
+ c_native: np.ndarray, # shape (m,)
196
+ blocks: List[ALMBlock], # ALM blocks (in the same order as the rows/cols of Q_native, c_native)
197
+ ) -> Tuple[List[Tuple[int, ...]], List[float]]:
198
+ """
199
+ Expand a quadratic/linear objective over m native discrete variables into the lifted
200
+ (one-hot) s-space.
201
+
202
+ Given `Q_native` and `c_native` over original m discrete vars (one block per var), and
203
+ `blocks` (`list[ALMBlock]` in the same order as original vars), we enforce:
204
+ - For variable i with level values b_i (length k_i), we create k_i lifted coords s_{i,a}.
205
+ - Quadratic term: J_ij = Q_native[i,j] * (b_i b_j^T) contributes to pairs (s_{i,a}, s_{j,b})
206
+ - Linear term: C_i = c_native[i] * b_i contributes to s_{i,a}
207
+
208
+ Returns polynomial (indices, coeffs) over concatenated s variables.
209
+ """
210
+ m = len(blocks)
211
+ assert Q_native.shape == (m, m), "Q_native must match number of blocks"
212
+ assert c_native.shape == (m,), "c_native must match number of blocks"
213
+
214
+ offs = ALMAlgorithm._block_offsets(blocks)
215
+ terms_acc = defaultdict(float)
216
+
217
+ # Quadratic lift: J = kron-expansion
218
+ for i in range(m):
219
+ bi = blocks[i].levels[:, None] # (k_i, 1)
220
+ oi = offs[i]
221
+ for j in range(m):
222
+ bj = blocks[j].levels[:, None] # (k_j, 1)
223
+ oj = offs[j]
224
+ J_ij = Q_native[i, j] * (bi @ bj.T) # (k_i, k_j)
225
+ if np.allclose(J_ij, 0.0):
226
+ continue
227
+ ki, kj = bi.shape[0], bj.shape[0]
228
+ for a in range(ki):
229
+ ia = oi + a + 1
230
+ for b in range(kj):
231
+ jb = oj + b + 1
232
+ w = float(J_ij[a, b])
233
+ if w == 0.0:
234
+ continue
235
+ if ia == jb:
236
+ terms_acc[(ia, ia)] += w
237
+ else:
238
+ # NOTE: we store each cross monomial once (i < j); for i==j block pairs,
239
+ # double to represent J_ab + J_ba
240
+ if i == j: # intra-block off-diagonal needs 2x
241
+ w *= 2.0
242
+ i1, i2 = (ia, jb) if ia < jb else (jb, ia)
243
+ terms_acc[(i1, i2)] += w
244
+
245
+ # Linear lift: C_i = L_i * b_i
246
+ for i in range(m):
247
+ b = blocks[i].levels
248
+ oi = offs[i]
249
+ for a, val in enumerate(b):
250
+ ia = oi + a + 1
251
+ w = float(c_native[i] * val)
252
+ if w != 0.0:
253
+ terms_acc[(0, ia)] += w
254
+
255
+ # Pack to PolynomialModel format
256
+ indices = [tuple(k) for k in terms_acc.keys()]
257
+ coeffs = [float(v) for v in terms_acc.values()]
258
+ return indices, coeffs
259
+
179
260
  # ---- main entrypoint ----
180
261
  @staticmethod
181
262
  def run(
182
- model: PolynomialModel,
263
+ base_model: PolynomialModel,
183
264
  registry: ConstraintRegistry,
184
265
  solver,
185
266
  cfg: ALMConfig = ALMConfig(),
@@ -191,19 +272,92 @@ class ALMAlgorithm:
191
272
  ) -> Dict[str, Union[Array, Dict[int, float], Dict]]:
192
273
  """
193
274
  Solve with ALM. Keep all ALM state local to this call (no global side-effects).
275
+ Handles three modes:
276
+ (A) No blocks -> continuous; use base_model as-is
277
+ (B) Blocks + native base_model -> lift to s-space
278
+ (C) Blocks + already-lifted base_model -> use as-is (compat)
194
279
 
195
280
  Returns:
196
281
  {
197
282
  "x": final iterate,
198
283
  "decoded": {start_idx_of_block: level_value, ...} for lifted blocks,
284
+ "decoded_debug": {start_idx_of_block: native_device_value, ...},
199
285
  "hist": { "eq_inf": [...], "ineq_inf": [...], "obj": [...], "x": [...] }
200
286
  }
201
287
  """
202
- n = int(getattr(model, "n", len(getattr(model, "upper_bound", [])) or 0))
203
- x = (np.asarray(x0, float).copy() if x0 is not None else
204
- np.zeros(n, float))
288
+ blocks = registry.blocks
289
+ has_blocks = len(blocks) > 0
290
+
291
+ # ---- choose working model + dimension n ----
292
+ if not has_blocks:
293
+ # (A) continuous case: use the provided model directly
294
+ model = base_model
295
+ # Prefer model.n, fall back to bounds; else infer from polynomial indices
296
+ n = getattr(model, "n", None)
297
+ if n is None:
298
+ ub = getattr(model, "upper_bound", None)
299
+ lb = getattr(model, "lower_bound", None)
300
+ if ub is not None:
301
+ n = len(ub)
302
+ elif lb is not None:
303
+ n = len(lb)
304
+ else:
305
+ # infer from polynomial terms
306
+ n = 0
307
+ for inds in getattr(model, "indices", getattr(model.polynomial, "indices", [])):
308
+ for j in inds:
309
+ if max(j) > 0:
310
+ n = max(n, j)
311
+ lifted_slices: List[List[int]] = []
312
+
313
+ else:
314
+ # (B/C) lifted (discrete) case
315
+ target_lifted_n = sum(len(blk.levels) for blk in blocks)
316
+ base_n = getattr(base_model, "n", None)
317
+
318
+ # detect "already-lifted" native input (compat path)
319
+ already_lifted = (base_n == target_lifted_n)
320
+
321
+ if already_lifted:
322
+ # (C) use provided model directly; assume bounds already sensible
323
+ model = base_model
324
+ n = target_lifted_n
325
+ else:
326
+ # (B) lift from native space
327
+ # base_model must expose coefficients/indices compatible with this call
328
+ c_base, Q_base = base_model._quadratic_polynomial_to_qubo_coefficients(
329
+ getattr(base_model, "coefficients", getattr(base_model.polynomial, "coefficients", [])),
330
+ getattr(base_model, "indices", getattr(base_model.polynomial, "indices", [])),
331
+ getattr(base_model, "n")
332
+ )
333
+ assert Q_base.shape[0] == Q_base.shape[1]
334
+ assert c_base.shape[0] == Q_base.shape[0]
335
+ indices_lifted, coeffs_lifted = ALMAlgorithm.lift_Qc_to_poly_terms(Q_base, c_base, blocks)
336
+ model = PolynomialModel(coeffs_lifted, indices_lifted)
337
+ n = target_lifted_n
338
+ # set canonical [0,1] bounds for lifted s
339
+ setattr(model, "lower_bound", np.zeros(n, float))
340
+ setattr(model, "upper_bound", np.ones(n, float))
341
+
342
+ # ---- n and lifted_slices ----
343
+ lifted_slices = []
344
+ pos = 0
345
+ for blk in blocks:
346
+ k = len(blk.levels) # number of lifted coords for this block
347
+ lifted_slices.append(list(range(pos, pos + k))) # 0-based in lifted x
348
+ pos += k
349
+
350
+ # Algorithm initial solution and bounds
205
351
  lb = getattr(model, "lower_bound", None)
206
352
  ub = getattr(model, "upper_bound", None)
353
+ if x0 is not None:
354
+ x = np.asarray(x0, float).copy()
355
+ else:
356
+ # default init
357
+ if (lb is not None) and (ub is not None) and np.all(np.isfinite(lb)) and np.all(np.isfinite(ub)):
358
+ x = 0.5 * (np.asarray(lb, float) + np.asarray(ub, float))
359
+ else:
360
+ x = np.zeros(n, float)
207
361
 
208
362
  # ---- collect constraints ----
209
363
  problem_eqs = [c for c in registry.constraints if c.kind == "eq"]
@@ -212,24 +366,26 @@ class ALMAlgorithm:
212
366
  # auto-install sum-to-one and one-hot as equalities
213
367
  # (One-hot: s^T (11^T - I) s = 0))
214
368
  def _install_block_equalities() -> List[ALMConstraint]:
369
+ if not has_blocks:
370
+ return []
215
371
  eqs: List[ALMConstraint] = []
216
- for blk in registry.blocks:
372
+ for blk, lift_idx in zip(registry.blocks, lifted_slices):
217
373
  if blk.enforce_sum_to_one:
218
- S = ALMAlgorithm._sum_to_one_selector(n, blk.idx)
374
+ S = ALMAlgorithm._sum_to_one_selector(n, lift_idx)
219
375
  eqs.append(ALMConstraint(
220
376
  "eq",
221
377
  fun=ALMAlgorithm._make_sum1_fun(S),
222
378
  jac=ALMAlgorithm._make_sum1_jac(S),
223
- name=f"sum_to_one_block_{blk.idx[0]}",
379
+ name=f"sum_to_one_block_{lift_idx[0]}",
224
380
  ))
225
381
  if blk.enforce_one_hot:
226
- k = len(blk.idx)
382
+ k = len(lift_idx)
227
383
  M = ALMAlgorithm._pairwise_M(k)
228
384
  eqs.append(ALMConstraint(
229
385
  "eq",
230
- fun=ALMAlgorithm._make_onehot_fun(blk.idx, M),
231
- jac=ALMAlgorithm._make_onehot_jac(blk.idx, M, n),
232
- name=f"onehot_block_{blk.idx[0]}",
386
+ fun=ALMAlgorithm._make_onehot_fun(lift_idx, M),
387
+ jac=ALMAlgorithm._make_onehot_jac(lift_idx, M, n),
388
+ name=f"onehot_block_{lift_idx[0]}",
233
389
  ))
234
390
  return eqs
235
391
 
@@ -274,7 +430,6 @@ class ALMAlgorithm:
274
430
 
275
431
  for it in range(cfg.max_outer):
276
432
  # -------- base polynomial (does not include fixed penalties here) --------
277
- # base_terms: List[PolyTerm] = list(getattr(model, "polynomial"))
278
433
  base_terms: List[PolyTerm] = list(zip(model.polynomial.indices, model.polynomial.coefficients))
279
434
 
280
435
  # -------- ALM quadratic/linear pieces (assembled here, kept separate) --------
@@ -451,14 +606,25 @@ class ALMAlgorithm:
451
606
  prev_eq_inf = max(eq_inf_smooth, eps)
452
607
  prev_ineq_inf = max(ineq_inf_smooth, eps)
453
608
 
454
- # optional decoding for lifted blocks
455
- decoded: Dict[int, Union[int, float]] = {}
456
- for blk in registry.blocks:
457
- sl = np.array(blk.idx, int)
458
- if len(sl) == 0:
459
- continue
460
- s = x[sl]
461
- j = int(np.argmax(s))
462
- decoded[sl[0]] = float(blk.levels[j])
463
-
464
- return {"x": x, "decoded": decoded, "hist": hist}
609
+ # ---- decoding back to native levels (only if blocks) ----
610
+ decoded_native: Dict[int, float] = {} # maps original var anchor -> chosen level value
611
+ decoded_lifted: Dict[int, int] = {} # maps lifted start index -> argmax position (optional)
612
+ if has_blocks:
613
+ for blk, lift_idx in zip(registry.blocks, lifted_slices):
614
+ if not lift_idx:
615
+ continue
616
+ sl = np.array(lift_idx, int)
617
+ if len(sl) == 0:
618
+ continue
619
+ sblk = x[sl]
620
+ j = int(np.argmax(sblk)) # which level got selected in the block
621
+ orig_anchor = int(blk.idx[0]) # anchor original var id for this block
622
+ decoded_native[orig_anchor] = float(blk.levels[j])
623
+ decoded_lifted[sl[0]] = j # optional: lifted index -> chosen slot
624
+
625
+ return {
626
+ "x": x,
627
+ "decoded": decoded_native if has_blocks else {},
628
+ "decoded_debug": decoded_lifted if has_blocks else {},
629
+ "hist": hist,
630
+ }
@@ -0,0 +1,132 @@
1
+ import numpy as np
2
+ from sklearn.metrics import (
3
+ auc,
4
+ precision_recall_curve,
5
+ roc_auc_score,
6
+ precision_score,
7
+ recall_score,
8
+ accuracy_score,
9
+ f1_score,
10
+ confusion_matrix,
11
+ )
12
+
13
+
14
+ def get_binary_classification_metrics(
15
+ y_true, y_pred, positive_label=1, negative_label=-1, threshold=0
16
+ ):
17
+ """Compute classifier merits.
18
+
19
+ Parameters
20
+ ----------
21
+ y_true: Actual labels (array-like of shape (n_samples,)).
22
+
23
+ y_pred: Predicted scores between negative and positive labels
24
+ (array-like of shape (n_samples,)).
25
+
26
+ positive_label: The positive label (integer; default: 1).
27
+
28
+ negative_label: The negative label (integer; default: -1).
29
+
30
+ threshold: Threshold for converting y_pred scores to predicted
31
+ labels, float; default: 0.
32
+
33
+ Returns
34
+ -------
35
+ Dict.
36
+
37
+ """
38
+
39
+ # Convert to numpy arrays
40
+ y_true = np.asarray(y_true).ravel()
41
+ y_pred = np.asarray(y_pred).ravel()
42
+
43
+ # Some sanity checks
44
+ if y_true.ndim != 1 or y_pred.ndim != 1:
45
+ raise ValueError(
46
+ "y_true and y_pred must be 1D arrays (or array-like)."
47
+ )
48
+ if y_true.shape[0] != y_pred.shape[0]:
49
+ raise ValueError(
50
+ f"Size mismatch: y_true has {y_true.shape[0]} elements, "
51
+ f"y_pred has {y_pred.shape[0]} elements."
52
+ )
53
+ if y_true.shape[0] == 0:
54
+ raise ValueError(
55
+ "Empty inputs: y_true/y_pred must have at least 1 element."
56
+ )
57
+
58
+ try:
59
+ positive_label = int(positive_label)
60
+ except Exception as e:
61
+ raise TypeError("positive_label must be an integer.") from e
62
+
63
+ try:
64
+ negative_label = int(negative_label)
65
+ except Exception as e:
66
+ raise TypeError("negative_label must be an integer.") from e
67
+
68
+ try:
69
+ threshold = float(threshold)
70
+ except Exception as e:
71
+ raise TypeError("threshold must be a float.") from e
72
+
73
+ assert (
74
+ positive_label != negative_label
75
+ ), "Positive and negative labels should not be equal!"
76
+
77
+ y_true = y_true.astype(int)
78
+ assert set(y_true) == {
79
+ positive_label,
80
+ negative_label,
81
+ }, "Incorrect labels!"
82
+
83
+ # Convert predicted scores to labels
84
+ dist_pos = np.abs(y_pred - positive_label)
85
+ dist_neg = np.abs(y_pred - negative_label)
86
+ y_pred_label = np.where(
87
+ dist_pos <= dist_neg, positive_label, negative_label
88
+ )
89
+
90
+ assert set(y_pred_label) == {
91
+ positive_label,
92
+ negative_label,
93
+ }, "Incorrect labels!"
94
+
95
+ # Calculate the metrics
96
+ precision, recall, _ = precision_recall_curve(y_true, y_pred)
97
+ pr_auc = auc(recall, precision)
98
+
99
+ out_hash = {
100
+ "positive_label": positive_label,
101
+ "negative_label": negative_label,
102
+ "threshold": threshold,
103
+ "pr_auc": pr_auc,
104
+ "roc_auc": roc_auc_score(y_true, y_pred),
105
+ "precision": precision_score(
106
+ y_true,
107
+ y_pred_label,
108
+ zero_division=0,
109
+ labels=[negative_label, positive_label],
110
+ pos_label=positive_label,
111
+ ),
112
+ "recall": recall_score(
113
+ y_true,
114
+ y_pred_label,
115
+ zero_division=0,
116
+ labels=[negative_label, positive_label],
117
+ pos_label=positive_label,
118
+ ),
119
+ "accuracy": accuracy_score(y_true, y_pred_label),
120
+ "f1_score": f1_score(
121
+ y_true,
122
+ y_pred_label,
123
+ zero_division=0,
124
+ labels=[negative_label, positive_label],
125
+ pos_label=positive_label,
126
+ ),
127
+ "confusion_matrix": confusion_matrix(
128
+ y_true, y_pred_label, labels=[negative_label, positive_label]
129
+ ),
130
+ }
131
+
132
+ return out_hash
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: eqc-models
3
- Version: 0.15.0
3
+ Version: 0.15.1
4
4
  Summary: Optimization and ML modeling package targeting EQC devices
5
5
  Author-email: "Quantum Computing Inc." <support@quantumcomputinginc.com>
6
6
  Project-URL: Homepage, https://quantumcomputinginc.com
@@ -78,6 +78,7 @@ eqc_models/ml/forecastbase.py
78
78
  eqc_models/ml/regressor.py
79
79
  eqc_models/ml/regressorbase.py
80
80
  eqc_models/ml/reservoir.py
81
+ eqc_models/ml/utils.py
81
82
  eqc_models/process/base.py
82
83
  eqc_models/process/mpc.py
83
84
  eqc_models/sequence/__init__.py
@@ -121,6 +122,7 @@ scripts/qsvm_iris_dirac3.py
121
122
  scripts/reservoir_forecast.py
122
123
  scripts/results_example.py
123
124
  scripts/rundoctests.py
125
+ scripts/test_reservoir.py
124
126
  scripts/test_shortestpath.py
125
127
  scripts/utils.py
126
128
  test/doctest_base.py
@@ -15,6 +15,8 @@ from sklearn.metrics import (
15
15
  )
16
16
 
17
17
  from eqc_models.ml.classifierqboost import QBoostClassifier
18
+ from eqc_models.ml.utils import get_binary_classification_metrics
19
+
18
20
 
19
21
  # Set parameters
20
22
  TEST_SIZE = 0.2
@@ -61,51 +63,39 @@ obj = QBoostClassifier(
61
63
  api_url=API_URL,
62
64
  api_token=API_TOKEN,
63
65
  ip_addr=IP_ADDR,
64
- port=PORT,
66
+ port=PORT,
65
67
  lambda_coef=0.0,
66
68
  weak_cls_schedule=1,
67
- weak_cls_pair_count=None,
69
+ weak_cls_pair_count=None,
68
70
  )
69
71
 
70
72
  # Train
71
73
  obj.fit(X_train, y_train)
72
74
 
73
- y_train_prd = obj.predict(X_train)
74
- y_test_prd = obj.predict(X_test)
75
+ y_train_prd = obj.predict_raw(X_train)
76
+ y_test_prd = obj.predict_raw(X_test)
75
77
 
76
78
  print(Counter(y_train_prd))
77
79
  print(Counter(y_test_prd))
78
80
 
79
81
  print(
80
- "Train precision:",
81
- precision_score(y_train, y_train_prd, labels=[-1, 1], pos_label=1),
82
- )
83
- print(
84
- "Train recall:",
85
- recall_score(y_train, y_train_prd, labels=[-1, 1], pos_label=1),
86
- )
87
- print(
88
- "Train accuracy:",
89
- accuracy_score(y_train, y_train_prd),
90
- )
91
- print(
92
- "Train confusion matrix:",
93
- confusion_matrix(y_train, y_train_prd, labels=[-1, 1]),
82
+ "Train data metrics:",
83
+ get_binary_classification_metrics(
84
+ y_train,
85
+ y_train_prd,
86
+ positive_label=1,
87
+ negative_label=-1,
88
+ threshold=0,
89
+ ),
94
90
  )
95
91
 
96
92
  print(
97
- "Test precision:",
98
- precision_score(y_test, y_test_prd, labels=[-1, 1], pos_label=1),
99
- )
100
- print(
101
- "Test recall:",
102
- recall_score(y_test, y_test_prd, labels=[-1, 1], pos_label=1),
103
- )
104
- print(
105
- "Test accuracy:",
106
- accuracy_score(y_test, y_test_prd),
107
- )
108
- print(
109
- "Test confusion matrix:",
110
- confusion_matrix(y_test, y_test_prd, labels=[-1, 1]),
93
+ "Test data metrics:",
94
+ get_binary_classification_metrics(
95
+ y_test,
96
+ y_test_prd,
97
+ positive_label=1,
98
+ negative_label=-1,
99
+ threshold=0,
100
+ ),
111
101
  )
@@ -0,0 +1,48 @@
1
+ import os
2
+ import pandas as pd
3
+ from eqc_models.ml import ReservoirForecastModel
4
+
5
+ # Deine parameters
6
+ INP_FILE = "mackey_glass_cell_production_series.csv"
7
+
8
+ MAX_TRAIN_DAY = 800
9
+ IP_ADDR = os.environ["EMUCORE_IP_ADDR"]
10
+ FEATURE_SCALING = 0.1
11
+ NUM_NODES = 1000
12
+ NUM_PADS = 100
13
+ LAGS = 2
14
+
15
+ # Prepare input time series
16
+ df = pd.read_csv(INP_FILE)
17
+
18
+ train_df = df[df["days"] <= MAX_TRAIN_DAY]
19
+ test_df = df[df["days"] > MAX_TRAIN_DAY]
20
+
21
+ # Train a forecast model
22
+ model = ReservoirForecastModel(
23
+ ip_addr=IP_ADDR,
24
+ num_nodes=NUM_NODES,
25
+ feature_scaling=FEATURE_SCALING,
26
+ num_pads=NUM_PADS,
27
+ device="EmuCore",
28
+ )
29
+
30
+ model.fit(
31
+ data=train_df,
32
+ feature_fields=["norm_cell_prod"],
33
+ target_fields=["norm_cell_prod"],
34
+ lags=LAGS,
35
+ horizon_size=1,
36
+ )
37
+
38
+ y_train_pred = model.predict(train_df, mode="in_sample")
39
+
40
+ print(y_train_pred)
41
+ print(y_train_pred.shape)
42
+
43
+ y_test_pred = model.predict(test_df, mode="in_sample")
44
+
45
+ print(y_test_pred)
46
+ print(y_test_pred.shape)
47
+
48
+ model.close()