jijmodeling 0.10.18__cp310-cp310-win_amd64.whl → 1.11.0__cp310-cp310-win_amd64.whl

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.

Potentially problematic release.


This version of jijmodeling might be problematic. Click here for more details.

Files changed (273) hide show
  1. jijmodeling/__init__.py +1 -148
  2. jijmodeling/__init__.pyi +5152 -0
  3. jijmodeling/_jijmodeling.cp310-win_amd64.pyd +0 -0
  4. jijmodeling/dataset.py +5 -0
  5. jijmodeling/dataset.pyi +106 -0
  6. jijmodeling/experimental.py +13 -0
  7. jijmodeling/experimental.pyi +302 -0
  8. jijmodeling/py.typed +0 -0
  9. jijmodeling/range/__init__.py +14 -0
  10. jijmodeling/range/__init__.pyi +56 -0
  11. jijmodeling/range/size.py +14 -0
  12. jijmodeling/range/size.pyi +54 -0
  13. jijmodeling/range/value.py +14 -0
  14. jijmodeling/range/value.pyi +54 -0
  15. jijmodeling-1.11.0.dist-info/METADATA +235 -0
  16. jijmodeling-1.11.0.dist-info/RECORD +18 -0
  17. {jijmodeling-0.10.18.dist-info → jijmodeling-1.11.0.dist-info}/WHEEL +1 -2
  18. {jijmodeling-0.10.18.dist-info → jijmodeling-1.11.0.dist-info/licenses}/LICENSE.txt +1 -1
  19. jijmodeling/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  20. jijmodeling/__pycache__/__init__.cpython-310.pyc +0 -0
  21. jijmodeling/__pycache__/_version.cpython-310.opt-1.pyc +0 -0
  22. jijmodeling/__pycache__/_version.cpython-310.pyc +0 -0
  23. jijmodeling/_version.py +0 -4
  24. jijmodeling/exceptions/__init__.py +0 -26
  25. jijmodeling/exceptions/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  26. jijmodeling/exceptions/__pycache__/__init__.cpython-310.pyc +0 -0
  27. jijmodeling/exceptions/__pycache__/exceptions.cpython-310.opt-1.pyc +0 -0
  28. jijmodeling/exceptions/__pycache__/exceptions.cpython-310.pyc +0 -0
  29. jijmodeling/exceptions/exceptions.py +0 -37
  30. jijmodeling/expression/__init__.py +0 -74
  31. jijmodeling/expression/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  32. jijmodeling/expression/__pycache__/__init__.cpython-310.pyc +0 -0
  33. jijmodeling/expression/__pycache__/condition.cpython-310.opt-1.pyc +0 -0
  34. jijmodeling/expression/__pycache__/condition.cpython-310.pyc +0 -0
  35. jijmodeling/expression/__pycache__/constraint.cpython-310.opt-1.pyc +0 -0
  36. jijmodeling/expression/__pycache__/constraint.cpython-310.pyc +0 -0
  37. jijmodeling/expression/__pycache__/expression.cpython-310.opt-1.pyc +0 -0
  38. jijmodeling/expression/__pycache__/expression.cpython-310.pyc +0 -0
  39. jijmodeling/expression/__pycache__/extract.cpython-310.opt-1.pyc +0 -0
  40. jijmodeling/expression/__pycache__/extract.cpython-310.pyc +0 -0
  41. jijmodeling/expression/__pycache__/from_old_serializable.cpython-310.opt-1.pyc +0 -0
  42. jijmodeling/expression/__pycache__/from_old_serializable.cpython-310.pyc +0 -0
  43. jijmodeling/expression/__pycache__/mathfunc.cpython-310.opt-1.pyc +0 -0
  44. jijmodeling/expression/__pycache__/mathfunc.cpython-310.pyc +0 -0
  45. jijmodeling/expression/__pycache__/prod.cpython-310.opt-1.pyc +0 -0
  46. jijmodeling/expression/__pycache__/prod.cpython-310.pyc +0 -0
  47. jijmodeling/expression/__pycache__/serializable.cpython-310.opt-1.pyc +0 -0
  48. jijmodeling/expression/__pycache__/serializable.cpython-310.pyc +0 -0
  49. jijmodeling/expression/__pycache__/sum.cpython-310.opt-1.pyc +0 -0
  50. jijmodeling/expression/__pycache__/sum.cpython-310.pyc +0 -0
  51. jijmodeling/expression/__pycache__/type_annotations.cpython-310.opt-1.pyc +0 -0
  52. jijmodeling/expression/__pycache__/type_annotations.cpython-310.pyc +0 -0
  53. jijmodeling/expression/__pycache__/utils.cpython-310.opt-1.pyc +0 -0
  54. jijmodeling/expression/__pycache__/utils.cpython-310.pyc +0 -0
  55. jijmodeling/expression/condition.py +0 -362
  56. jijmodeling/expression/constraint.py +0 -340
  57. jijmodeling/expression/expression.py +0 -706
  58. jijmodeling/expression/extract.py +0 -139
  59. jijmodeling/expression/from_old_serializable.py +0 -133
  60. jijmodeling/expression/mathfunc.py +0 -269
  61. jijmodeling/expression/prod.py +0 -117
  62. jijmodeling/expression/serializable.py +0 -132
  63. jijmodeling/expression/sum.py +0 -197
  64. jijmodeling/expression/type_annotations.py +0 -50
  65. jijmodeling/expression/utils.py +0 -201
  66. jijmodeling/expression/variables/__init__.py +0 -35
  67. jijmodeling/expression/variables/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  68. jijmodeling/expression/variables/__pycache__/__init__.cpython-310.pyc +0 -0
  69. jijmodeling/expression/variables/__pycache__/deci_vars.cpython-310.opt-1.pyc +0 -0
  70. jijmodeling/expression/variables/__pycache__/deci_vars.cpython-310.pyc +0 -0
  71. jijmodeling/expression/variables/__pycache__/jagged_array.cpython-310.opt-1.pyc +0 -0
  72. jijmodeling/expression/variables/__pycache__/jagged_array.cpython-310.pyc +0 -0
  73. jijmodeling/expression/variables/__pycache__/placeholders.cpython-310.opt-1.pyc +0 -0
  74. jijmodeling/expression/variables/__pycache__/placeholders.cpython-310.pyc +0 -0
  75. jijmodeling/expression/variables/__pycache__/variable.cpython-310.opt-1.pyc +0 -0
  76. jijmodeling/expression/variables/__pycache__/variable.cpython-310.pyc +0 -0
  77. jijmodeling/expression/variables/deci_vars.py +0 -136
  78. jijmodeling/expression/variables/jagged_array.py +0 -73
  79. jijmodeling/expression/variables/placeholders.py +0 -107
  80. jijmodeling/expression/variables/variable.py +0 -485
  81. jijmodeling/latex_repr/__init__.py +0 -11
  82. jijmodeling/latex_repr/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  83. jijmodeling/latex_repr/__pycache__/__init__.cpython-310.pyc +0 -0
  84. jijmodeling/latex_repr/__pycache__/latex_repr.cpython-310.opt-1.pyc +0 -0
  85. jijmodeling/latex_repr/__pycache__/latex_repr.cpython-310.pyc +0 -0
  86. jijmodeling/latex_repr/__pycache__/problem_latex_repr.cpython-310.opt-1.pyc +0 -0
  87. jijmodeling/latex_repr/__pycache__/problem_latex_repr.cpython-310.pyc +0 -0
  88. jijmodeling/latex_repr/latex_repr.py +0 -243
  89. jijmodeling/latex_repr/problem_latex_repr.py +0 -209
  90. jijmodeling/marker/__marker__.cp310-win_amd64.pyd +0 -0
  91. jijmodeling/match/__init__.py +0 -19
  92. jijmodeling/match/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  93. jijmodeling/match/__pycache__/__init__.cpython-310.pyc +0 -0
  94. jijmodeling/match/__pycache__/condition_same.cpython-310.opt-1.pyc +0 -0
  95. jijmodeling/match/__pycache__/condition_same.cpython-310.pyc +0 -0
  96. jijmodeling/match/__pycache__/constraint_same.cpython-310.opt-1.pyc +0 -0
  97. jijmodeling/match/__pycache__/constraint_same.cpython-310.pyc +0 -0
  98. jijmodeling/match/__pycache__/expr_same.cpython-310.opt-1.pyc +0 -0
  99. jijmodeling/match/__pycache__/expr_same.cpython-310.pyc +0 -0
  100. jijmodeling/match/__pycache__/is_same_expr.cpython-310.opt-1.pyc +0 -0
  101. jijmodeling/match/__pycache__/is_same_expr.cpython-310.pyc +0 -0
  102. jijmodeling/match/__pycache__/penalty_same.cpython-310.opt-1.pyc +0 -0
  103. jijmodeling/match/__pycache__/penalty_same.cpython-310.pyc +0 -0
  104. jijmodeling/match/__pycache__/problem_same.cpython-310.opt-1.pyc +0 -0
  105. jijmodeling/match/__pycache__/problem_same.cpython-310.pyc +0 -0
  106. jijmodeling/match/__pycache__/replace.cpython-310.opt-1.pyc +0 -0
  107. jijmodeling/match/__pycache__/replace.cpython-310.pyc +0 -0
  108. jijmodeling/match/condition_same.py +0 -44
  109. jijmodeling/match/constraint_same.py +0 -53
  110. jijmodeling/match/expr_same.py +0 -32
  111. jijmodeling/match/is_same_expr.py +0 -304
  112. jijmodeling/match/penalty_same.py +0 -31
  113. jijmodeling/match/problem_same.py +0 -44
  114. jijmodeling/match/replace.py +0 -210
  115. jijmodeling/problem/__init__.py +0 -9
  116. jijmodeling/problem/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  117. jijmodeling/problem/__pycache__/__init__.cpython-310.pyc +0 -0
  118. jijmodeling/problem/__pycache__/problem.cpython-310.opt-1.pyc +0 -0
  119. jijmodeling/problem/__pycache__/problem.cpython-310.pyc +0 -0
  120. jijmodeling/problem/problem.py +0 -166
  121. jijmodeling/protobuf/__init__.py +0 -8
  122. jijmodeling/protobuf/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  123. jijmodeling/protobuf/__pycache__/__init__.cpython-310.pyc +0 -0
  124. jijmodeling/protobuf/from_protobuf/__init__.py +0 -47
  125. jijmodeling/protobuf/from_protobuf/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  126. jijmodeling/protobuf/from_protobuf/__pycache__/__init__.cpython-310.pyc +0 -0
  127. jijmodeling/protobuf/from_protobuf/__pycache__/extract_attribute_value_from_header.cpython-310.opt-1.pyc +0 -0
  128. jijmodeling/protobuf/from_protobuf/__pycache__/extract_attribute_value_from_header.cpython-310.pyc +0 -0
  129. jijmodeling/protobuf/from_protobuf/__pycache__/from_protobuf.cpython-310.opt-1.pyc +0 -0
  130. jijmodeling/protobuf/from_protobuf/__pycache__/from_protobuf.cpython-310.pyc +0 -0
  131. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_array_shape.cpython-310.opt-1.pyc +0 -0
  132. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_array_shape.cpython-310.pyc +0 -0
  133. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_binary_op.cpython-310.opt-1.pyc +0 -0
  134. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_binary_op.cpython-310.pyc +0 -0
  135. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_binary_var.cpython-310.opt-1.pyc +0 -0
  136. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_binary_var.cpython-310.pyc +0 -0
  137. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_constraint.cpython-310.opt-1.pyc +0 -0
  138. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_constraint.cpython-310.pyc +0 -0
  139. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_element.cpython-310.opt-1.pyc +0 -0
  140. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_element.cpython-310.pyc +0 -0
  141. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_expression.cpython-310.opt-1.pyc +0 -0
  142. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_expression.cpython-310.pyc +0 -0
  143. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_forall.cpython-310.opt-1.pyc +0 -0
  144. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_forall.cpython-310.pyc +0 -0
  145. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_integer_var.cpython-310.opt-1.pyc +0 -0
  146. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_integer_var.cpython-310.pyc +0 -0
  147. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_jagged_array.cpython-310.opt-1.pyc +0 -0
  148. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_jagged_array.cpython-310.pyc +0 -0
  149. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_number_lit.cpython-310.opt-1.pyc +0 -0
  150. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_number_lit.cpython-310.pyc +0 -0
  151. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_penalty.cpython-310.opt-1.pyc +0 -0
  152. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_penalty.cpython-310.pyc +0 -0
  153. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_placeholder.cpython-310.opt-1.pyc +0 -0
  154. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_placeholder.cpython-310.pyc +0 -0
  155. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_problem.cpython-310.opt-1.pyc +0 -0
  156. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_problem.cpython-310.pyc +0 -0
  157. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_reduction_op.cpython-310.opt-1.pyc +0 -0
  158. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_reduction_op.cpython-310.pyc +0 -0
  159. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_subscript_op.cpython-310.opt-1.pyc +0 -0
  160. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_subscript_op.cpython-310.pyc +0 -0
  161. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_unary_op.cpython-310.opt-1.pyc +0 -0
  162. jijmodeling/protobuf/from_protobuf/__pycache__/message_to_unary_op.cpython-310.pyc +0 -0
  163. jijmodeling/protobuf/from_protobuf/extract_attribute_value_from_header.py +0 -26
  164. jijmodeling/protobuf/from_protobuf/from_protobuf.py +0 -38
  165. jijmodeling/protobuf/from_protobuf/message_to_array_shape.py +0 -35
  166. jijmodeling/protobuf/from_protobuf/message_to_binary_op.py +0 -83
  167. jijmodeling/protobuf/from_protobuf/message_to_binary_var.py +0 -46
  168. jijmodeling/protobuf/from_protobuf/message_to_constraint.py +0 -48
  169. jijmodeling/protobuf/from_protobuf/message_to_element.py +0 -30
  170. jijmodeling/protobuf/from_protobuf/message_to_expression.py +0 -92
  171. jijmodeling/protobuf/from_protobuf/message_to_forall.py +0 -33
  172. jijmodeling/protobuf/from_protobuf/message_to_integer_var.py +0 -54
  173. jijmodeling/protobuf/from_protobuf/message_to_jagged_array.py +0 -25
  174. jijmodeling/protobuf/from_protobuf/message_to_number_lit.py +0 -41
  175. jijmodeling/protobuf/from_protobuf/message_to_penalty.py +0 -36
  176. jijmodeling/protobuf/from_protobuf/message_to_placeholder.py +0 -47
  177. jijmodeling/protobuf/from_protobuf/message_to_problem.py +0 -51
  178. jijmodeling/protobuf/from_protobuf/message_to_reduction_op.py +0 -52
  179. jijmodeling/protobuf/from_protobuf/message_to_subscript_op.py +0 -46
  180. jijmodeling/protobuf/from_protobuf/message_to_unary_op.py +0 -47
  181. jijmodeling/protobuf/to_protobuf/__init__.py +0 -43
  182. jijmodeling/protobuf/to_protobuf/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  183. jijmodeling/protobuf/to_protobuf/__pycache__/__init__.cpython-310.pyc +0 -0
  184. jijmodeling/protobuf/to_protobuf/__pycache__/add_header_to_message.cpython-310.opt-1.pyc +0 -0
  185. jijmodeling/protobuf/to_protobuf/__pycache__/add_header_to_message.cpython-310.pyc +0 -0
  186. jijmodeling/protobuf/to_protobuf/__pycache__/array_shape_to_message.cpython-310.opt-1.pyc +0 -0
  187. jijmodeling/protobuf/to_protobuf/__pycache__/array_shape_to_message.cpython-310.pyc +0 -0
  188. jijmodeling/protobuf/to_protobuf/__pycache__/binary_op_to_message.cpython-310.opt-1.pyc +0 -0
  189. jijmodeling/protobuf/to_protobuf/__pycache__/binary_op_to_message.cpython-310.pyc +0 -0
  190. jijmodeling/protobuf/to_protobuf/__pycache__/binary_var_to_message.cpython-310.opt-1.pyc +0 -0
  191. jijmodeling/protobuf/to_protobuf/__pycache__/binary_var_to_message.cpython-310.pyc +0 -0
  192. jijmodeling/protobuf/to_protobuf/__pycache__/constraint_to_message.cpython-310.opt-1.pyc +0 -0
  193. jijmodeling/protobuf/to_protobuf/__pycache__/constraint_to_message.cpython-310.pyc +0 -0
  194. jijmodeling/protobuf/to_protobuf/__pycache__/element_to_message.cpython-310.opt-1.pyc +0 -0
  195. jijmodeling/protobuf/to_protobuf/__pycache__/element_to_message.cpython-310.pyc +0 -0
  196. jijmodeling/protobuf/to_protobuf/__pycache__/expression_to_message.cpython-310.opt-1.pyc +0 -0
  197. jijmodeling/protobuf/to_protobuf/__pycache__/expression_to_message.cpython-310.pyc +0 -0
  198. jijmodeling/protobuf/to_protobuf/__pycache__/forall_to_message.cpython-310.opt-1.pyc +0 -0
  199. jijmodeling/protobuf/to_protobuf/__pycache__/forall_to_message.cpython-310.pyc +0 -0
  200. jijmodeling/protobuf/to_protobuf/__pycache__/integer_var_to_message.cpython-310.opt-1.pyc +0 -0
  201. jijmodeling/protobuf/to_protobuf/__pycache__/integer_var_to_message.cpython-310.pyc +0 -0
  202. jijmodeling/protobuf/to_protobuf/__pycache__/jagged_array_to_message.cpython-310.opt-1.pyc +0 -0
  203. jijmodeling/protobuf/to_protobuf/__pycache__/jagged_array_to_message.cpython-310.pyc +0 -0
  204. jijmodeling/protobuf/to_protobuf/__pycache__/number_lit_to_message.cpython-310.opt-1.pyc +0 -0
  205. jijmodeling/protobuf/to_protobuf/__pycache__/number_lit_to_message.cpython-310.pyc +0 -0
  206. jijmodeling/protobuf/to_protobuf/__pycache__/penalty_to_message.cpython-310.opt-1.pyc +0 -0
  207. jijmodeling/protobuf/to_protobuf/__pycache__/penalty_to_message.cpython-310.pyc +0 -0
  208. jijmodeling/protobuf/to_protobuf/__pycache__/placeholder_to_message.cpython-310.opt-1.pyc +0 -0
  209. jijmodeling/protobuf/to_protobuf/__pycache__/placeholder_to_message.cpython-310.pyc +0 -0
  210. jijmodeling/protobuf/to_protobuf/__pycache__/problem_to_message.cpython-310.opt-1.pyc +0 -0
  211. jijmodeling/protobuf/to_protobuf/__pycache__/problem_to_message.cpython-310.pyc +0 -0
  212. jijmodeling/protobuf/to_protobuf/__pycache__/reduction_op_to_message.cpython-310.opt-1.pyc +0 -0
  213. jijmodeling/protobuf/to_protobuf/__pycache__/reduction_op_to_message.cpython-310.pyc +0 -0
  214. jijmodeling/protobuf/to_protobuf/__pycache__/subscript_op_to_message.cpython-310.opt-1.pyc +0 -0
  215. jijmodeling/protobuf/to_protobuf/__pycache__/subscript_op_to_message.cpython-310.pyc +0 -0
  216. jijmodeling/protobuf/to_protobuf/__pycache__/to_protobuf.cpython-310.opt-1.pyc +0 -0
  217. jijmodeling/protobuf/to_protobuf/__pycache__/to_protobuf.cpython-310.pyc +0 -0
  218. jijmodeling/protobuf/to_protobuf/__pycache__/unary_op_to_message.cpython-310.opt-1.pyc +0 -0
  219. jijmodeling/protobuf/to_protobuf/__pycache__/unary_op_to_message.cpython-310.pyc +0 -0
  220. jijmodeling/protobuf/to_protobuf/add_header_to_message.py +0 -35
  221. jijmodeling/protobuf/to_protobuf/array_shape_to_message.py +0 -43
  222. jijmodeling/protobuf/to_protobuf/binary_op_to_message.py +0 -101
  223. jijmodeling/protobuf/to_protobuf/binary_var_to_message.py +0 -49
  224. jijmodeling/protobuf/to_protobuf/constraint_to_message.py +0 -52
  225. jijmodeling/protobuf/to_protobuf/element_to_message.py +0 -43
  226. jijmodeling/protobuf/to_protobuf/expression_to_message.py +0 -89
  227. jijmodeling/protobuf/to_protobuf/forall_to_message.py +0 -32
  228. jijmodeling/protobuf/to_protobuf/integer_var_to_message.py +0 -54
  229. jijmodeling/protobuf/to_protobuf/jagged_array_to_message.py +0 -37
  230. jijmodeling/protobuf/to_protobuf/number_lit_to_message.py +0 -52
  231. jijmodeling/protobuf/to_protobuf/penalty_to_message.py +0 -42
  232. jijmodeling/protobuf/to_protobuf/placeholder_to_message.py +0 -58
  233. jijmodeling/protobuf/to_protobuf/problem_to_message.py +0 -54
  234. jijmodeling/protobuf/to_protobuf/reduction_op_to_message.py +0 -64
  235. jijmodeling/protobuf/to_protobuf/subscript_op_to_message.py +0 -48
  236. jijmodeling/protobuf/to_protobuf/to_protobuf.py +0 -36
  237. jijmodeling/protobuf/to_protobuf/unary_op_to_message.py +0 -58
  238. jijmodeling/sampleset/__init__.py +0 -33
  239. jijmodeling/sampleset/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  240. jijmodeling/sampleset/__pycache__/__init__.cpython-310.pyc +0 -0
  241. jijmodeling/sampleset/__pycache__/evaluation.cpython-310.opt-1.pyc +0 -0
  242. jijmodeling/sampleset/__pycache__/evaluation.cpython-310.pyc +0 -0
  243. jijmodeling/sampleset/__pycache__/measuring_time.cpython-310.opt-1.pyc +0 -0
  244. jijmodeling/sampleset/__pycache__/measuring_time.cpython-310.pyc +0 -0
  245. jijmodeling/sampleset/__pycache__/record.cpython-310.opt-1.pyc +0 -0
  246. jijmodeling/sampleset/__pycache__/record.cpython-310.pyc +0 -0
  247. jijmodeling/sampleset/__pycache__/sampleset.cpython-310.opt-1.pyc +0 -0
  248. jijmodeling/sampleset/__pycache__/sampleset.cpython-310.pyc +0 -0
  249. jijmodeling/sampleset/__pycache__/solving_time.cpython-310.opt-1.pyc +0 -0
  250. jijmodeling/sampleset/__pycache__/solving_time.cpython-310.pyc +0 -0
  251. jijmodeling/sampleset/__pycache__/system_time.cpython-310.opt-1.pyc +0 -0
  252. jijmodeling/sampleset/__pycache__/system_time.cpython-310.pyc +0 -0
  253. jijmodeling/sampleset/evaluation.py +0 -288
  254. jijmodeling/sampleset/measuring_time.py +0 -59
  255. jijmodeling/sampleset/record.py +0 -158
  256. jijmodeling/sampleset/sampleset.py +0 -379
  257. jijmodeling/sampleset/solving_time.py +0 -38
  258. jijmodeling/sampleset/system_time.py +0 -48
  259. jijmodeling/type_annotations/__init__.py +0 -44
  260. jijmodeling/type_annotations/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  261. jijmodeling/type_annotations/__pycache__/__init__.cpython-310.pyc +0 -0
  262. jijmodeling/type_annotations/__pycache__/type_annotations.cpython-310.opt-1.pyc +0 -0
  263. jijmodeling/type_annotations/__pycache__/type_annotations.cpython-310.pyc +0 -0
  264. jijmodeling/type_annotations/type_annotations.py +0 -54
  265. jijmodeling/utils/__init__.py +0 -28
  266. jijmodeling/utils/__pycache__/__init__.cpython-310.opt-1.pyc +0 -0
  267. jijmodeling/utils/__pycache__/__init__.cpython-310.pyc +0 -0
  268. jijmodeling/utils/__pycache__/utils.cpython-310.opt-1.pyc +0 -0
  269. jijmodeling/utils/__pycache__/utils.cpython-310.pyc +0 -0
  270. jijmodeling/utils/utils.py +0 -146
  271. jijmodeling-0.10.18.dist-info/METADATA +0 -60
  272. jijmodeling-0.10.18.dist-info/RECORD +0 -258
  273. jijmodeling-0.10.18.dist-info/top_level.txt +0 -1
@@ -1,166 +0,0 @@
1
- from __future__ import annotations
2
-
3
- import copy as _copy
4
- import enum as _enum
5
- import typing as tp
6
-
7
- import typeguard as _typeguard
8
-
9
- import jijmodeling.exceptions.exceptions as _exceptions
10
- import jijmodeling.expression.constraint as _constraint
11
- import jijmodeling.expression.expression as _expression
12
- import jijmodeling.expression.serializable as _serializable
13
- import jijmodeling.expression.utils as _utils
14
-
15
-
16
- class ProblemSense(_enum.Enum):
17
- MINIMUM = "MINIMUM"
18
- MAXIMUM = "MAXIMUM"
19
-
20
-
21
- class Problem(metaclass=_serializable.Serializable):
22
- """
23
- Optimization problem.
24
-
25
- Attributes:
26
- name (str): name of problem.
27
- model (Optional[Expression]): total optimization model.
28
- constraints (Dict[str, Constraint]): constraint objects of problem.
29
- penalties (Dict[str, Constraint]): penalty objects of problem.
30
- cost (Expression): cost term of problem. Defaults zero.
31
- """
32
-
33
- def __init__(
34
- self,
35
- name: str,
36
- sense: tp.Union[ProblemSense, str] = ProblemSense.MINIMUM,
37
- objective: _expression.Expression = _expression.Number(0),
38
- constraints: tp.Dict[str, _constraint.Constraint] = {},
39
- penalties: tp.Dict[str, _constraint.Penalty] = {},
40
- ) -> None:
41
- """
42
- Initialize
43
-
44
- Args:
45
- problem_name (str): problem name
46
- kind (ProblemKind): problem kind Minimum or Maximum
47
- objective (Expression): objective
48
- constraints (Dict[str, Constraint]): dict of constraints
49
- penalties (Dict[str, Penalty]): dict of penalties
50
- """
51
- self._name = name
52
- self._sense = ProblemSense(sense)
53
- # deepcopy to avoid having the same reference
54
- self._objective = _copy.deepcopy(objective)
55
- self._constraints: tp.Dict[str, _constraint.Constraint] = _copy.deepcopy(
56
- constraints
57
- )
58
- self._penalties: tp.Dict[str, _constraint.Penalty] = _copy.deepcopy(penalties)
59
-
60
- _typeguard.check_type("self._name", self._name, str)
61
- _typeguard.check_type("self._sense", self._sense, ProblemSense)
62
- _typeguard.check_type(
63
- "self._constraints", self._constraints, tp.Dict[str, _constraint.Constraint]
64
- )
65
- _typeguard.check_type(
66
- "self._penalties", self._penalties, tp.Dict[str, _constraint.Penalty]
67
- )
68
-
69
- @property
70
- def name(self) -> str:
71
- return self._name
72
-
73
- @property
74
- def sense(self) -> ProblemSense:
75
- return self._sense
76
-
77
- @property
78
- def objective(self) -> _expression.Expression:
79
- return self._objective
80
-
81
- @property
82
- def constraints(self) -> tp.Dict[str, _constraint.Constraint]:
83
- return self._constraints
84
-
85
- @property
86
- def penalties(self) -> tp.Dict[str, _constraint.Penalty]:
87
- return self._penalties
88
-
89
- def add(
90
- self,
91
- other: tp.Union[
92
- _expression.Expression, _constraint.Constraint, _constraint.Penalty
93
- ],
94
- ):
95
- """
96
- Add expression, constraint or penalty to problem.
97
-
98
- Args:
99
- other (Expression): expression
100
-
101
- Examples:
102
- ```python
103
- >>> import jijmodeling as jm
104
- >>> d = jm.Placeholder("d", dim=1)
105
- >>> n = d.shape[0]
106
- >>> i = jm.Element("i", n)
107
- >>> x = jm.Binary("x", shape=(n,))
108
- >>> problem = jm.Problem("sample")
109
- >>> problem.add(x[:]) # add cost
110
- >>> problem.add(jm.Constraint("onehot", x[:] == 1)) # add constraint
111
- >>> problem.add(jm.Penalty("penalty", x[0] + x[2])) # add penalty
112
- >>> problem += x[:] # syntax sugar `+=`
113
- >>> problem += jm.Constraint("onehot", jm.Sum(i, d[i]*x[i]) <= 3)
114
- ```
115
- """
116
- if not isinstance(
117
- other,
118
- (
119
- int,
120
- float,
121
- _expression.Expression,
122
- _constraint.Constraint,
123
- _constraint.Penalty,
124
- ),
125
- ):
126
- raise TypeError(f"could not add {type(other)} to Problem.")
127
- # extract constraints
128
- if isinstance(other, _expression.Expression):
129
- # check index dependencies
130
- indices = _utils.expression_indices(other)
131
- if len(indices) > 0:
132
- raise _exceptions.ModelingError(
133
- "{} depends on {}. The dependence on subscripts needs to be eliminated.".format(
134
- other, indices
135
- )
136
- )
137
- self._objective += other
138
- elif isinstance(other, _constraint.Constraint):
139
- # TODO CHECK CONSTRAINT SUBSCRIPTION DEPENDENCES
140
- self._constraints[other.label] = other
141
- elif isinstance(other, _constraint.Penalty):
142
- # check index dependencies
143
- term = other.penalty_term
144
- indices = _utils.expression_indices(term)
145
- if len(indices) > len(other.forall):
146
- raise _exceptions.ModelingError(
147
- "{} depends on {}. The dependence on subscripts needs to be eliminated.".format(
148
- term, indices
149
- )
150
- )
151
- self._penalties[other.label] = other
152
-
153
- def __add__(
154
- self,
155
- other: tp.Union[
156
- _expression.Expression, _constraint.Constraint, _constraint.Penalty
157
- ],
158
- ) -> Problem:
159
- self.add(other)
160
- return self
161
-
162
- def _repr_latex_(self) -> str:
163
- from jijmodeling.latex_repr.problem_latex_repr import problem_latex_repr
164
-
165
- latex_repr = problem_latex_repr(self)
166
- return r"$$\begin{alignat*}{4}" + latex_repr + r"\end{alignat*}$$"
@@ -1,8 +0,0 @@
1
- from pkgutil import extend_path
2
-
3
- __path__ = extend_path(__path__, __name__)
4
-
5
- import jijmodeling.protobuf.from_protobuf as from_protobuf
6
- import jijmodeling.protobuf.to_protobuf as to_protobuf
7
-
8
- __all__ = ["to_protobuf", "from_protobuf"]
@@ -1,47 +0,0 @@
1
- from __future__ import annotations
2
-
3
- from pkgutil import extend_path
4
-
5
- __path__ = extend_path(__path__, __name__)
6
-
7
- import jijmodeling.protobuf.from_protobuf.extract_attribute_value_from_header as extract_attribute_value_from_header
8
- import jijmodeling.protobuf.from_protobuf.from_protobuf as from_protobuf
9
- import jijmodeling.protobuf.from_protobuf.message_to_array_shape as message_to_array_shape
10
- import jijmodeling.protobuf.from_protobuf.message_to_binary_op as message_to_binary_op
11
- import jijmodeling.protobuf.from_protobuf.message_to_binary_var as message_to_binary_var
12
- import jijmodeling.protobuf.from_protobuf.message_to_constraint as message_to_constraint
13
- import jijmodeling.protobuf.from_protobuf.message_to_element as message_to_element
14
- import jijmodeling.protobuf.from_protobuf.message_to_expression as message_to_expression
15
- import jijmodeling.protobuf.from_protobuf.message_to_forall as message_to_forall
16
- import jijmodeling.protobuf.from_protobuf.message_to_integer_var as message_to_integer_var
17
- import jijmodeling.protobuf.from_protobuf.message_to_jagged_array as message_to_jagged_array
18
- import jijmodeling.protobuf.from_protobuf.message_to_number_lit as message_to_number_lit
19
- import jijmodeling.protobuf.from_protobuf.message_to_penalty as message_to_penalty
20
- import jijmodeling.protobuf.from_protobuf.message_to_placeholder as message_to_placeholder
21
- import jijmodeling.protobuf.from_protobuf.message_to_problem as message_to_problem
22
- import jijmodeling.protobuf.from_protobuf.message_to_reduction_op as message_to_reduction_op
23
- import jijmodeling.protobuf.from_protobuf.message_to_subscript_op as message_to_subscript_op
24
- import jijmodeling.protobuf.from_protobuf.message_to_unary_op as message_to_unary_op
25
-
26
- # from jijmodeling.protobuf.from_protobuf.from_protobuf import from_protobuf
27
-
28
- __all__ = [
29
- "extract_attribute_value_from_header",
30
- "from_protobuf",
31
- "message_to_array_shape",
32
- "message_to_binary_op",
33
- "message_to_binary_var",
34
- "message_to_constraint",
35
- "message_to_element",
36
- "message_to_expression",
37
- "message_to_forall",
38
- "message_to_integer_var",
39
- "message_to_jagged_array",
40
- "message_to_number_lit",
41
- "message_to_penalty",
42
- "message_to_placeholder",
43
- "message_to_problem",
44
- "message_to_reduction_op",
45
- "message_to_subscript_op",
46
- "message_to_unary_op",
47
- ]
@@ -1,26 +0,0 @@
1
- from __future__ import annotations
2
-
3
- from typing import Union
4
-
5
- import jijmodeling_schema as pb
6
-
7
-
8
- def extract_attribute_value_from_header(
9
- bytes: bytes,
10
- ) -> Union[pb.Problem, pb.Expression]:
11
- """
12
- Extract the attribute value from a header messsage.
13
-
14
- Args:
15
- bytes (bytes): a bytes object that can be decoded in the `Header` message
16
-
17
- Returns:
18
- Union[pb.Problem, pb.Expression]: an instance object of either `Problem` message class or `Expression` message class
19
- """
20
- # Convert the bytes object into the `Header` message object.
21
- header = pb.Header.FromString(bytes)
22
-
23
- # Extract the attribute value from the header message.
24
- attribute_value = pb.betterproto.which_one_of(header.value, "value")[1]
25
-
26
- return attribute_value
@@ -1,38 +0,0 @@
1
- from __future__ import annotations
2
-
3
- from typing import Union
4
-
5
- import jijmodeling_schema as pb
6
-
7
- from jijmodeling.expression.expression import Expression
8
- from jijmodeling.problem.problem import Problem
9
- from jijmodeling.protobuf.from_protobuf.extract_attribute_value_from_header import (
10
- extract_attribute_value_from_header,
11
- )
12
- from jijmodeling.protobuf.from_protobuf.message_to_expression import (
13
- message_to_expression,
14
- )
15
- from jijmodeling.protobuf.from_protobuf.message_to_problem import message_to_problem
16
-
17
-
18
- def from_protobuf(bytes: bytes) -> Union[Problem, Expression]:
19
- """
20
- Convert a bytes object in protobuf to a JijModeling's object.
21
-
22
- Args:
23
- bytes (bytes): a bytes object in protobuf
24
-
25
- Returns:
26
- Expression: an expression
27
- """
28
- # Convert the bytes object into the message object.
29
- attribute_value = extract_attribute_value_from_header(bytes)
30
-
31
- if type(attribute_value) is pb.Problem:
32
- return message_to_problem(attribute_value)
33
- elif isinstance(attribute_value, pb.Expression):
34
- return message_to_expression(attribute_value)
35
- else:
36
- raise RuntimeError(
37
- f"cannot convert the bytes object into the instance object according to the class in JijModeling (bytes = {str(bytes)})"
38
- )
@@ -1,35 +0,0 @@
1
- from __future__ import annotations
2
-
3
- import jijmodeling_schema as pb
4
-
5
- from jijmodeling.expression.variables.placeholders import ArrayShape
6
-
7
-
8
- def message_to_array_shape(
9
- id: str, message: pb.ArrayShape, array: pb.Expression
10
- ) -> ArrayShape:
11
- """
12
- Convert a message to a `ArrayShape` object.
13
-
14
- Args:
15
- id (str): the id of the `ArrayShape` object
16
- message (pb.ArrayShape): the `ArrayShape` message
17
- array (pb.Expression): the target array of the array shape
18
-
19
- Returns:
20
- ArrayShape: an `ArrayShape` object
21
- """
22
- # Set the number of axis.
23
- axis = message.axis
24
-
25
- # NOTE: Import a module within a local scope to fix a circular import.
26
- # - https://stackoverflow.com/questions/59462679/design-of-python-conditional-imports
27
- # - https://medium.com/@hamana.hadrien/so-you-got-a-circular-import-in-python-e9142fe10591
28
- from jijmodeling.protobuf.from_protobuf.message_to_expression import (
29
- message_to_expression,
30
- )
31
-
32
- # Set the target array of this array shape.
33
- array = message_to_expression(array)
34
-
35
- return ArrayShape(uuid=id, array=array, dimension=axis)
@@ -1,83 +0,0 @@
1
- from __future__ import annotations
2
-
3
- from typing import Union
4
-
5
- import jijmodeling_schema as pb
6
-
7
- from jijmodeling.expression.condition import (
8
- AndOperator,
9
- Condition,
10
- Equal,
11
- LessThan,
12
- LessThanEqual,
13
- NotEqual,
14
- OrOperator,
15
- XorOperator,
16
- )
17
- from jijmodeling.expression.expression import Add, BinaryOperator, Div, Mod, Mul, Power
18
- from jijmodeling.expression.variables.variable import Range
19
-
20
-
21
- def message_to_binary_op(
22
- id: str, message: pb.BinaryOp, left: pb.Expression, right: pb.Expression
23
- ) -> Union[BinaryOperator, Range, Condition]:
24
- """
25
- Convert a message to a `BinaryOperator` object.
26
-
27
- Args:
28
- id (str): the id of the `BinaryOperator` object
29
- message (pb.BinaryOp): the `BinaryOp` message
30
- operand (pb.Expression): the operand node that the `BinaryOp` message has
31
-
32
- Raises:
33
- TypeError: the error happens if the message cannot be converted to a `BinaryOperator` object
34
-
35
- Returns:
36
- BinaryOperator: a `BinaryOperator` object
37
- """
38
- # NOTE: Import a module within a local scope to fix a circular import.
39
- # - https://stackoverflow.com/questions/59462679/design-of-python-conditional-imports
40
- # - https://medium.com/@hamana.hadrien/so-you-got-a-circular-import-in-python-e9142fe10591
41
- from jijmodeling.protobuf.from_protobuf.message_to_expression import (
42
- message_to_expression,
43
- )
44
-
45
- # Convert the children to the `Expression` objects.
46
- lhs = message_to_expression(left)
47
- rhs = message_to_expression(right)
48
-
49
- # BinaryOp
50
- if message.kind == pb.BinaryOpKind.ADD:
51
- return Add(uuid=id, left=lhs, right=rhs)
52
- elif message.kind == pb.BinaryOpKind.MUL:
53
- return Mul(uuid=id, left=lhs, right=rhs)
54
- elif message.kind == pb.BinaryOpKind.DIV:
55
- return Div(uuid=id, left=lhs, right=rhs)
56
- elif message.kind == pb.BinaryOpKind.POW:
57
- return Power(uuid=id, left=lhs, right=rhs)
58
- elif message.kind == pb.BinaryOpKind.MOD:
59
- return Mod(uuid=id, left=lhs, right=rhs)
60
- # Range
61
- elif message.kind == pb.BinaryOpKind.RANGE:
62
- return Range(start=lhs, last=rhs, uuid=id)
63
- # ComparisonOp
64
- elif message.kind == pb.BinaryOpKind.EQ:
65
- return Equal(uuid=id, left=lhs, right=rhs)
66
- elif message.kind == pb.BinaryOpKind.NOT_EQ:
67
- return NotEqual(uuid=id, left=lhs, right=rhs)
68
- elif message.kind == pb.BinaryOpKind.LESS_THAN:
69
- return LessThan(uuid=id, left=lhs, right=rhs)
70
- elif message.kind == pb.BinaryOpKind.LESS_THAN_EQ:
71
- return LessThanEqual(uuid=id, left=lhs, right=rhs)
72
- # Logicalop
73
- elif message.kind == pb.BinaryOpKind.AND:
74
- return AndOperator(uuid=id, left=lhs, right=rhs)
75
- elif message.kind == pb.BinaryOpKind.OR:
76
- return OrOperator(uuid=id, left=lhs, right=rhs)
77
- elif message.kind == pb.BinaryOpKind.XOR:
78
- return XorOperator(uuid=id, left=lhs, right=rhs)
79
- # Otherwise
80
- else:
81
- raise TypeError(
82
- f"cannot convert the binary operator (actual = {message}) to an expression."
83
- )
@@ -1,46 +0,0 @@
1
- from __future__ import annotations
2
-
3
- from typing import List
4
-
5
- import jijmodeling_schema as pb
6
-
7
- from jijmodeling.expression.variables.deci_vars import Binary
8
-
9
-
10
- def message_to_binary_var(
11
- id: str, message: pb.BinaryVar, shape: List[pb.Expression]
12
- ) -> Binary:
13
- """
14
- Convert a message to a `Binary` object.
15
-
16
- Args:
17
- id (str): the id of the `Binary` object
18
- message (pb.BinaryVar): the `BinaryVar` message
19
- shape (List[pb.Expression]): the shape of the `Binary` object
20
-
21
- Raises:
22
- ValueError: the error occurs if `dim` is not equal to length of the shape
23
-
24
- Returns:
25
- Binary: a `Binary` object
26
- """
27
- # Validate length of the shape.
28
- if message.dim != len(shape):
29
- raise ValueError("invalid length of the shape")
30
-
31
- # Set the symbol.
32
- symbol = message.symbol
33
-
34
- # NOTE: Import a module within a local scope to fix a circular import.
35
- # - https://stackoverflow.com/questions/59462679/design-of-python-conditional-imports
36
- # - https://medium.com/@hamana.hadrien/so-you-got-a-circular-import-in-python-e9142fe10591
37
- from jijmodeling.protobuf.from_protobuf.message_to_expression import (
38
- message_to_expression,
39
- )
40
-
41
- # Set the shape.
42
- shape_element_list = [
43
- message_to_expression(shape_element) for shape_element in shape
44
- ]
45
-
46
- return Binary(label=symbol, shape=shape_element_list, uuid=id)
@@ -1,48 +0,0 @@
1
- from __future__ import annotations
2
-
3
- import jijmodeling_schema as pb
4
-
5
- from jijmodeling.expression.constraint import Constraint
6
- from jijmodeling.protobuf.from_protobuf.message_to_expression import (
7
- message_to_expression,
8
- )
9
- from jijmodeling.protobuf.from_protobuf.message_to_forall import message_to_forall
10
-
11
-
12
- def message_to_constraint(constraint: pb.Constraint) -> Constraint:
13
- """
14
- Convert a `Constraint` message into a `Constraint` object.
15
-
16
- Args:
17
- constraint (pb.Constraint): a `Constraint` message
18
-
19
- Returns:
20
- Constraint: a `Constraint` object
21
- """
22
- # Set the name of the constraint.
23
- name = constraint.name
24
-
25
- # Set the condition expression.
26
- condition = message_to_expression(constraint.expression)
27
-
28
- # Set the list of forall.
29
- forall = [message_to_forall(forall) for forall in constraint.forall]
30
-
31
- # Set the left_lower.
32
- has_left_lower = (
33
- pb.betterproto.which_one_of(constraint.left_lower.kind, "kind")[1] is not None
34
- )
35
- if has_left_lower:
36
- left_lower = message_to_expression(constraint.left_lower)
37
- else:
38
- left_lower = None
39
-
40
- return Constraint(
41
- label=name,
42
- condition=condition,
43
- forall=forall,
44
- left_lower=left_lower,
45
- with_penalty=constraint.is_penalty,
46
- with_multiplier=constraint.needs_multiplier,
47
- auto_qubo=constraint.needs_square,
48
- )
@@ -1,30 +0,0 @@
1
- from __future__ import annotations
2
-
3
- import jijmodeling_schema as pb
4
-
5
- from jijmodeling.expression.variables.variable import Element
6
-
7
-
8
- def message_to_element(id: str, message: pb.Element, parent: pb.Expression) -> Element:
9
- """
10
- Convert a message to a `Element` object.
11
-
12
- Args:
13
- id (str): the id of the `Element` object
14
- message (pb.Element): the `Element` message
15
- parent (pb.Expression): the parent node that the `Element` message has
16
-
17
- Returns:
18
- Element: an `Element` object
19
- """
20
- # Set the symbol
21
- symbol = message.symbol
22
-
23
- # NOTE: Import a module within a local scope to fix a circular import.
24
- # - https://stackoverflow.com/questions/59462679/design-of-python-conditional-imports
25
- # - https://medium.com/@hamana.hadrien/so-you-got-a-circular-import-in-python-e9142fe10591
26
- from jijmodeling.protobuf.from_protobuf.message_to_expression import (
27
- message_to_expression,
28
- )
29
-
30
- return Element(label=symbol, parent=message_to_expression(parent), uuid=id)