pyoframe 0.2.0__tar.gz → 1.0.0__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 (301) hide show
  1. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/actions/setup_optimizers_linux/action.yml +52 -45
  2. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/workflows/ci.yml +10 -3
  3. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/workflows/format.yml +1 -0
  4. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/workflows/lines_changed_counter.yml +2 -0
  5. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/workflows/lint.yml +1 -0
  6. pyoframe-1.0.0/.github/workflows/publish_doc.yml +54 -0
  7. pyoframe-1.0.0/.github/workflows/publish_doc_dev.yml +43 -0
  8. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/workflows/publish_to_pypi.yml +1 -0
  9. pyoframe-1.0.0/.github/workflows/test_doc.yml +23 -0
  10. {pyoframe-0.2.0 → pyoframe-1.0.0}/.gitignore +1 -1
  11. pyoframe-1.0.0/.pre-commit-config.yaml +15 -0
  12. pyoframe-1.0.0/.vscode/launch.json +17 -0
  13. pyoframe-1.0.0/.vscode/settings.json +14 -0
  14. {pyoframe-0.2.0 → pyoframe-1.0.0}/PKG-INFO +37 -31
  15. {pyoframe-0.2.0 → pyoframe-1.0.0}/README.md +4 -4
  16. pyoframe-1.0.0/conftest.py +93 -0
  17. pyoframe-1.0.0/docs/.nav.yml +13 -0
  18. pyoframe-1.0.0/docs/contribute/index.md +51 -0
  19. pyoframe-1.0.0/docs/examples/.nav.yml +6 -0
  20. pyoframe-1.0.0/docs/examples/diet.md +68 -0
  21. pyoframe-1.0.0/docs/examples/facility_location.md +73 -0
  22. pyoframe-1.0.0/docs/examples/index.md +8 -0
  23. pyoframe-1.0.0/docs/examples/portfolio_optimization.md +66 -0
  24. pyoframe-1.0.0/docs/examples/production.md +60 -0
  25. pyoframe-1.0.0/docs/index.md +78 -0
  26. pyoframe-1.0.0/docs/javascripts/feedback.js +26 -0
  27. pyoframe-1.0.0/docs/learn/advanced-concepts/.nav.yml +6 -0
  28. pyoframe-0.2.0/docs/learn/03_concepts/01_pyoframe-datastructure.md → pyoframe-1.0.0/docs/learn/advanced-concepts/datastructure.md +2 -2
  29. pyoframe-1.0.0/docs/learn/advanced-concepts/internals.md +19 -0
  30. pyoframe-1.0.0/docs/learn/advanced-concepts/performance.md +36 -0
  31. pyoframe-1.0.0/docs/learn/advanced-concepts/quadratics.md +33 -0
  32. pyoframe-1.0.0/docs/learn/concepts/.nav.yml +5 -0
  33. pyoframe-1.0.0/docs/learn/concepts/addition.md +238 -0
  34. pyoframe-1.0.0/docs/learn/concepts/building-blocks.md +17 -0
  35. pyoframe-1.0.0/docs/learn/concepts/solver-access.md +104 -0
  36. pyoframe-1.0.0/docs/learn/concepts/special-functions.md +112 -0
  37. pyoframe-1.0.0/docs/learn/get-started/.nav.yml +4 -0
  38. pyoframe-1.0.0/docs/learn/get-started/basic-example/example-with-dimensions.md +187 -0
  39. pyoframe-1.0.0/docs/learn/get-started/basic-example/example.md +61 -0
  40. pyoframe-1.0.0/docs/learn/get-started/basic-example/food_data.csv +3 -0
  41. pyoframe-1.0.0/docs/learn/get-started/installation.md +76 -0
  42. {pyoframe-0.2.0/docs/learn/01_getting-started → pyoframe-1.0.0/docs/learn/get-started}/power_grid_example.ipynb +5 -7
  43. pyoframe-1.0.0/docs/learn/migrate/v1.0.md +124 -0
  44. pyoframe-1.0.0/docs/overrides/main.html +12 -0
  45. pyoframe-1.0.0/docs/overrides/partials/comments.html +46 -0
  46. pyoframe-1.0.0/docs/reference/.nav.yml +6 -0
  47. pyoframe-1.0.0/docs/reference/bases/.nav.yml +3 -0
  48. pyoframe-1.0.0/docs/reference/bases/BaseBlock.md +3 -0
  49. pyoframe-1.0.0/docs/reference/bases/BaseOperableBlock.md +3 -0
  50. pyoframe-1.0.0/docs/reference/external/.nav.yml +4 -0
  51. pyoframe-1.0.0/docs/reference/external/pandas.DataFrame.to_expr.md +3 -0
  52. pyoframe-1.0.0/docs/reference/external/pandas.Series.to_expr.md +3 -0
  53. pyoframe-1.0.0/docs/reference/external/polars.DataFrame.to_expr.md +3 -0
  54. pyoframe-1.0.0/docs/reference/index.md +32 -0
  55. pyoframe-1.0.0/docs/reference/public/.nav.yml +2 -0
  56. pyoframe-1.0.0/docs/reference/public/Config.md +12 -0
  57. pyoframe-1.0.0/docs/reference/types/.nav.yml +2 -0
  58. pyoframe-1.0.0/docs/reference/types/Operable.md +3 -0
  59. pyoframe-1.0.0/docs/stylesheets/extra.css +4 -0
  60. pyoframe-1.0.0/docs/why-pyoframe/index.md +11 -0
  61. {pyoframe-0.2.0 → pyoframe-1.0.0}/docs/why-pyoframe/pyoframe-performance.ipynb +6 -6
  62. pyoframe-1.0.0/giscus.json +3 -0
  63. {pyoframe-0.2.0 → pyoframe-1.0.0}/mkdocs.yml +61 -5
  64. {pyoframe-0.2.0/src → pyoframe-1.0.0}/pyoframe.egg-info/PKG-INFO +37 -31
  65. {pyoframe-0.2.0/src → pyoframe-1.0.0}/pyoframe.egg-info/SOURCES.txt +117 -46
  66. pyoframe-1.0.0/pyoframe.egg-info/requires.txt +39 -0
  67. pyoframe-1.0.0/pyproject.toml +116 -0
  68. pyoframe-1.0.0/scripts/archive/benchmark_assign_ids_constraints.py +226 -0
  69. pyoframe-1.0.0/scripts/archive/benchmark_assign_ids_constraints_2.py +158 -0
  70. pyoframe-1.0.0/scripts/archive/benchmark_assign_ids_variables.py +72 -0
  71. pyoframe-1.0.0/scripts/archive/benchmark_attr_performance.py +73 -0
  72. pyoframe-1.0.0/scripts/generate_api_reference.py +25 -0
  73. pyoframe-1.0.0/scripts/griffe_extensions.py +25 -0
  74. pyoframe-1.0.0/src/pyoframe/__init__.py +35 -0
  75. pyoframe-1.0.0/src/pyoframe/_arithmetic.py +549 -0
  76. pyoframe-1.0.0/src/pyoframe/_constants.py +463 -0
  77. pyoframe-1.0.0/src/pyoframe/_core.py +2652 -0
  78. pyoframe-1.0.0/src/pyoframe/_model.py +598 -0
  79. pyoframe-1.0.0/src/pyoframe/_model_element.py +189 -0
  80. pyoframe-1.0.0/src/pyoframe/_monkey_patch.py +82 -0
  81. pyoframe-0.2.0/src/pyoframe/objective.py → pyoframe-1.0.0/src/pyoframe/_objective.py +50 -17
  82. pyoframe-0.2.0/src/pyoframe/util.py → pyoframe-1.0.0/src/pyoframe/_utils.py +108 -129
  83. {pyoframe-0.2.0 → pyoframe-1.0.0}/src/pyoframe/_version.py +16 -3
  84. pyoframe-1.0.0/tests/conftest.py +41 -0
  85. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/README.md +1 -1
  86. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/model.py +8 -8
  87. pyoframe-1.0.0/tests/examples/cutting_stock_problem/results/problem-copt-machine.lp +89 -0
  88. pyoframe-1.0.0/tests/examples/cutting_stock_problem/results/problem-copt-pretty.lp +190 -0
  89. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/model.py +7 -15
  90. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/model_gurobipy.py +1 -3
  91. pyoframe-1.0.0/tests/examples/diet_problem/results/problem-copt-machine.lp +29 -0
  92. pyoframe-1.0.0/tests/examples/diet_problem/results/problem-copt-pretty.lp +36 -0
  93. pyoframe-1.0.0/tests/examples/diet_problem/results/solution-copt-machine.sol +11 -0
  94. pyoframe-1.0.0/tests/examples/diet_problem/results/solution-copt-pretty.sol +11 -0
  95. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_location/model.py +17 -21
  96. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/model.py +12 -9
  97. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/model_gurobipy.py +14 -11
  98. pyoframe-1.0.0/tests/examples/facility_problem/results/problem-copt-machine.lp +29 -0
  99. pyoframe-1.0.0/tests/examples/facility_problem/results/problem-copt-pretty.lp +41 -0
  100. pyoframe-1.0.0/tests/examples/facility_problem/results/solution-copt-machine.sol +27 -0
  101. pyoframe-1.0.0/tests/examples/facility_problem/results/solution-copt-pretty.sol +27 -0
  102. pyoframe-1.0.0/tests/examples/portfolio_optim/input_data/assets.csv +6 -0
  103. pyoframe-1.0.0/tests/examples/portfolio_optim/input_data/covariance.csv +26 -0
  104. pyoframe-1.0.0/tests/examples/portfolio_optim/input_data/portfolio_params.csv +3 -0
  105. pyoframe-1.0.0/tests/examples/portfolio_optim/model.py +214 -0
  106. pyoframe-1.0.0/tests/examples/portfolio_optim/results/con_min_return.csv +2 -0
  107. pyoframe-1.0.0/tests/examples/portfolio_optim/results/con_weights_sum.csv +2 -0
  108. pyoframe-1.0.0/tests/examples/portfolio_optim/results/objective.csv +2 -0
  109. pyoframe-1.0.0/tests/examples/portfolio_optim/results/problem-copt-machine.lp +20 -0
  110. pyoframe-1.0.0/tests/examples/portfolio_optim/results/problem-copt-pretty.lp +24 -0
  111. pyoframe-1.0.0/tests/examples/portfolio_optim/results/problem-gurobi-machine.lp +18 -0
  112. pyoframe-1.0.0/tests/examples/portfolio_optim/results/problem-gurobi-pretty.lp +24 -0
  113. pyoframe-1.0.0/tests/examples/portfolio_optim/results/problem-highs-machine.lp +14 -0
  114. pyoframe-1.0.0/tests/examples/portfolio_optim/results/problem-highs-pretty.lp +14 -0
  115. pyoframe-1.0.0/tests/examples/portfolio_optim/results/solution-copt-machine.sol +7 -0
  116. pyoframe-1.0.0/tests/examples/portfolio_optim/results/solution-copt-pretty.sol +7 -0
  117. pyoframe-1.0.0/tests/examples/portfolio_optim/results/solution-gurobi-machine.sol +7 -0
  118. pyoframe-1.0.0/tests/examples/portfolio_optim/results/solution-gurobi-pretty.sol +7 -0
  119. pyoframe-1.0.0/tests/examples/portfolio_optim/results/solution-highs-machine.sol +37 -0
  120. pyoframe-1.0.0/tests/examples/portfolio_optim/results/solution-highs-pretty.sol +37 -0
  121. pyoframe-1.0.0/tests/examples/portfolio_optim/results/weight.csv +6 -0
  122. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/model.py +10 -7
  123. pyoframe-1.0.0/tests/examples/production_planning/results/problem-copt-machine.lp +11 -0
  124. pyoframe-1.0.0/tests/examples/production_planning/results/problem-copt-pretty.lp +13 -0
  125. pyoframe-1.0.0/tests/examples/production_planning/results/solution-copt-machine.sol +5 -0
  126. pyoframe-1.0.0/tests/examples/production_planning/results/solution-copt-pretty.sol +5 -0
  127. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/model.py +15 -12
  128. pyoframe-1.0.0/tests/examples/pumped_storage/results/problem-copt-machine.lp +8146 -0
  129. pyoframe-1.0.0/tests/examples/pumped_storage/results/problem-copt-pretty.lp +20447 -0
  130. pyoframe-1.0.0/tests/examples/pumped_storage/results/solution-copt-machine.sol +4382 -0
  131. pyoframe-1.0.0/tests/examples/pumped_storage/results/solution-copt-pretty.sol +4382 -0
  132. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/model.py +11 -8
  133. pyoframe-1.0.0/tests/examples/sudoku/results/problem-copt-machine.lp +1469 -0
  134. pyoframe-1.0.0/tests/examples/sudoku/results/problem-copt-pretty.lp +1513 -0
  135. pyoframe-1.0.0/tests/examples/sudoku/results/solution-copt-machine.sol +731 -0
  136. pyoframe-1.0.0/tests/examples/sudoku/results/solution-copt-pretty.sol +731 -0
  137. pyoframe-1.0.0/tests/test_addition.py +470 -0
  138. pyoframe-1.0.0/tests/test_arithmetic.py +164 -0
  139. pyoframe-1.0.0/tests/test_constraint.py +38 -0
  140. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/test_examples.py +130 -65
  141. pyoframe-1.0.0/tests/test_io.py +176 -0
  142. pyoframe-1.0.0/tests/test_model.py +93 -0
  143. pyoframe-1.0.0/tests/test_names.py +77 -0
  144. pyoframe-1.0.0/tests/test_objective.py +22 -0
  145. pyoframe-1.0.0/tests/test_solver.py +295 -0
  146. pyoframe-1.0.0/tests/test_variable.py +68 -0
  147. pyoframe-1.0.0/tests/util.py +82 -0
  148. pyoframe-0.2.0/.github/workflows/publish_doc.yml +0 -33
  149. pyoframe-0.2.0/.pre-commit-config.yaml +0 -9
  150. pyoframe-0.2.0/.vscode/settings.json +0 -7
  151. pyoframe-0.2.0/conftest.py +0 -38
  152. pyoframe-0.2.0/docs/SUMMARY.md +0 -4
  153. pyoframe-0.2.0/docs/contribute/index.md +0 -36
  154. pyoframe-0.2.0/docs/index.md +0 -53
  155. pyoframe-0.2.0/docs/learn/01_getting-started/01_installation.md +0 -26
  156. pyoframe-0.2.0/docs/learn/01_getting-started/02_build-simple-model.md +0 -196
  157. pyoframe-0.2.0/docs/learn/01_getting-started/04_building_blocks.md +0 -17
  158. pyoframe-0.2.0/docs/learn/01_getting-started/05_special_functions.md +0 -18
  159. pyoframe-0.2.0/docs/learn/01_getting-started/06_accessing_the_solver.md +0 -40
  160. pyoframe-0.2.0/docs/learn/01_getting-started/SUMMARY.md +0 -5
  161. pyoframe-0.2.0/docs/learn/01_getting-started/inputs/food_data.csv +0 -3
  162. pyoframe-0.2.0/docs/learn/02_tutorials/index.md +0 -5
  163. pyoframe-0.2.0/docs/learn/03_concepts/02_performance_tips.md +0 -13
  164. pyoframe-0.2.0/docs/learn/03_concepts/03_quadratic_expressions.md +0 -41
  165. pyoframe-0.2.0/docs/learn/03_concepts/SUMMARY.md +0 -4
  166. pyoframe-0.2.0/docs/learn/04_examples/index.md +0 -8
  167. pyoframe-0.2.0/docs/learn/SUMMARY.md +0 -4
  168. pyoframe-0.2.0/docs/learn/index.md +0 -44
  169. pyoframe-0.2.0/docs/overrides/home.html +0 -4
  170. pyoframe-0.2.0/docs/why-pyoframe/SUMMARY.md +0 -5
  171. pyoframe-0.2.0/docs/why-pyoframe/index.md +0 -14
  172. pyoframe-0.2.0/docs/why-pyoframe/why-pyoframe.md +0 -1
  173. pyoframe-0.2.0/pyproject.toml +0 -70
  174. pyoframe-0.2.0/scripts/gen_ref_pages.py +0 -35
  175. pyoframe-0.2.0/src/pyoframe/__init__.py +0 -28
  176. pyoframe-0.2.0/src/pyoframe/_arithmetic.py +0 -441
  177. pyoframe-0.2.0/src/pyoframe/constants.py +0 -140
  178. pyoframe-0.2.0/src/pyoframe/core.py +0 -1794
  179. pyoframe-0.2.0/src/pyoframe/model.py +0 -408
  180. pyoframe-0.2.0/src/pyoframe/model_element.py +0 -184
  181. pyoframe-0.2.0/src/pyoframe/monkey_patch.py +0 -54
  182. pyoframe-0.2.0/src/pyoframe.egg-info/requires.txt +0 -31
  183. pyoframe-0.2.0/tests/conftest.py +0 -19
  184. pyoframe-0.2.0/tests/examples/facility_problem/results/con_max_capacity.csv +0 -6
  185. pyoframe-0.2.0/tests/examples/facility_problem/results/con_meet_demand.csv +0 -5
  186. pyoframe-0.2.0/tests/examples/pumped_storage/results/initial_storage_level.csv +0 -2
  187. pyoframe-0.2.0/tests/examples/pumped_storage/results/intermediate_storage_level.csv +0 -1461
  188. pyoframe-0.2.0/tests/examples/pumped_storage/results/pump_and_turbine_xor.csv +0 -1461
  189. pyoframe-0.2.0/tests/test_arithmetic.py +0 -518
  190. pyoframe-0.2.0/tests/test_io.py +0 -137
  191. pyoframe-0.2.0/tests/test_model.py +0 -70
  192. pyoframe-0.2.0/tests/test_operations.py +0 -53
  193. pyoframe-0.2.0/tests/test_solver.py +0 -208
  194. pyoframe-0.2.0/tests/util.py +0 -53
  195. {pyoframe-0.2.0 → pyoframe-1.0.0}/.gitattributes +0 -0
  196. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/CODEOWNERS +0 -0
  197. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/actions/setup_optimizers_macos/action.yml +0 -0
  198. {pyoframe-0.2.0 → pyoframe-1.0.0}/.github/actions/setup_optimizers_windows/action.yml +0 -0
  199. {pyoframe-0.2.0 → pyoframe-1.0.0}/CHANGELOG.md +0 -0
  200. {pyoframe-0.2.0 → pyoframe-1.0.0}/LICENSE +0 -0
  201. /pyoframe-0.2.0/docs/learn/03_concepts/04_troubleshooting.md → /pyoframe-1.0.0/docs/learn/advanced-concepts/troubleshooting.md +0 -0
  202. {pyoframe-0.2.0/docs/learn/01_getting-started/inputs → pyoframe-1.0.0/docs/learn/get-started/basic-example}/foods.csv +0 -0
  203. {pyoframe-0.2.0/docs/learn/01_getting-started/inputs → pyoframe-1.0.0/docs/learn/get-started/basic-example}/foods_to_nutrients.csv +0 -0
  204. {pyoframe-0.2.0/docs/learn/01_getting-started/inputs → pyoframe-1.0.0/docs/learn/get-started/basic-example}/nutrients.csv +0 -0
  205. {pyoframe-0.2.0/docs/learn/01_getting-started/inputs → pyoframe-1.0.0/docs/learn/get-started/basic-example}/results.csv +0 -0
  206. {pyoframe-0.2.0/docs/learn/01_getting-started → pyoframe-1.0.0/docs/learn/get-started}/three-bus.png +0 -0
  207. {pyoframe-0.2.0 → pyoframe-1.0.0}/docs/overrides/partials/actions.html +0 -0
  208. /pyoframe-0.2.0/docs/why-pyoframe/benchmarks.md → /pyoframe-1.0.0/docs/overrides/partials/integrations/analytics/custom.html +0 -0
  209. {pyoframe-0.2.0 → pyoframe-1.0.0}/docs/why-pyoframe/data_py.parquet +0 -0
  210. {pyoframe-0.2.0 → pyoframe-1.0.0}/docs/why-pyoframe/gen_py.parquet +0 -0
  211. {pyoframe-0.2.0 → pyoframe-1.0.0}/docs/why-pyoframe/three-bus-four-gen.png +0 -0
  212. {pyoframe-0.2.0/src → pyoframe-1.0.0}/pyoframe.egg-info/dependency_links.txt +0 -0
  213. {pyoframe-0.2.0/src → pyoframe-1.0.0}/pyoframe.egg-info/top_level.txt +0 -0
  214. {pyoframe-0.2.0 → pyoframe-1.0.0}/setup.cfg +0 -0
  215. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/__init__.py +0 -0
  216. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/__init__.py +0 -0
  217. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/__init__.py +0 -0
  218. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/input_data/orders.csv +0 -0
  219. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/input_data/parameters.csv +0 -0
  220. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/results/objective.csv +0 -0
  221. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/results/problem-gurobi-machine.lp +0 -0
  222. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/results/problem-gurobi-pretty.lp +0 -0
  223. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/results/problem-highs-machine.lp +0 -0
  224. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/cutting_stock_problem/results/problem-highs-pretty.lp +0 -0
  225. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/README.md +0 -0
  226. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/__init__.py +0 -0
  227. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/input_data/foods.csv +0 -0
  228. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/input_data/foods_to_nutrients.csv +0 -0
  229. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/input_data/nutrients.csv +0 -0
  230. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/Buy.csv +0 -0
  231. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/Buy_ub.csv +0 -0
  232. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/max_nutrients.csv +0 -0
  233. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/min_nutrients.csv +0 -0
  234. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/objective.csv +0 -0
  235. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/problem-gurobi-machine.lp +0 -0
  236. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/problem-gurobi-pretty.lp +0 -0
  237. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/problem-highs-machine.lp +0 -0
  238. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/problem-highs-pretty.lp +0 -0
  239. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/solution-gurobi-machine.sol +0 -0
  240. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/solution-gurobi-pretty.sol +0 -0
  241. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/solution-highs-machine.sol +0 -0
  242. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/diet_problem/results/solution-highs-pretty.sol +0 -0
  243. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_location/__init__.py +0 -0
  244. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_location/results/objective.csv +0 -0
  245. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_location/results/problem-gurobi-machine.lp +0 -0
  246. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_location/results/problem-gurobi-pretty.lp +0 -0
  247. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/__init__.py +0 -0
  248. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/input_data/plants.csv +0 -0
  249. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/input_data/transport_costs.csv +0 -0
  250. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/input_data/wharehouses.csv +0 -0
  251. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/objective.csv +0 -0
  252. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/open.csv +0 -0
  253. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/problem-gurobi-machine.lp +0 -0
  254. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/problem-gurobi-pretty.lp +0 -0
  255. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/problem-highs-machine.lp +0 -0
  256. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/problem-highs-pretty.lp +0 -0
  257. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/solution-gurobi-machine.sol +0 -0
  258. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/solution-gurobi-pretty.sol +0 -0
  259. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/solution-highs-machine.sol +0 -0
  260. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/solution-highs-pretty.sol +0 -0
  261. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/facility_problem/results/transport.csv +0 -0
  262. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/__init__.py +0 -0
  263. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/input_data/machines_availability.csv +0 -0
  264. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/input_data/processing_times.csv +0 -0
  265. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/input_data/products_profit.csv +0 -0
  266. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/objective.csv +0 -0
  267. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/problem-gurobi-machine.lp +0 -0
  268. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/problem-gurobi-pretty.lp +0 -0
  269. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/problem-highs-machine.lp +0 -0
  270. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/problem-highs-pretty.lp +0 -0
  271. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/solution-gurobi-machine.sol +0 -0
  272. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/solution-gurobi-pretty.sol +0 -0
  273. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/solution-highs-machine.sol +0 -0
  274. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/solution-highs-pretty.sol +0 -0
  275. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/production_planning/results/solution.csv +0 -0
  276. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/README.md +0 -0
  277. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/__init__.py +0 -0
  278. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/input_data/elspot-prices_2021_hourly_eur.csv +0 -0
  279. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/Pump.csv +0 -0
  280. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/Storage_level.csv +0 -0
  281. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/Turb.csv +0 -0
  282. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/objective.csv +0 -0
  283. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/problem-gurobi-machine.lp +0 -0
  284. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/problem-gurobi-pretty.lp +0 -0
  285. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/problem-highs-machine.lp +0 -0
  286. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/problem-highs-pretty.lp +0 -0
  287. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/solution-gurobi-machine.sol +0 -0
  288. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/solution-gurobi-pretty.sol +0 -0
  289. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/solution-highs-machine.sol +0 -0
  290. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/pumped_storage/results/solution-highs-pretty.sol +0 -0
  291. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/__init__.py +0 -0
  292. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/input_data/initial_numbers.csv +0 -0
  293. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/problem-gurobi-machine.lp +0 -0
  294. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/problem-gurobi-pretty.lp +0 -0
  295. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/problem-highs-machine.lp +0 -0
  296. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/problem-highs-pretty.lp +0 -0
  297. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/solution-gurobi-machine.sol +0 -0
  298. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/solution-gurobi-pretty.sol +0 -0
  299. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/solution-highs-machine.sol +0 -0
  300. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/solution-highs-pretty.sol +0 -0
  301. {pyoframe-0.2.0 → pyoframe-1.0.0}/tests/examples/sudoku/results/solution.csv +0 -0
@@ -5,19 +5,22 @@
5
5
  name: "Install optimizers on linux"
6
6
 
7
7
  inputs:
8
- GUROBI_WLS:
8
+ GUROBI_WLS:
9
+ description: "..."
10
+ required: true
11
+ COPT_LICENSE_KEY:
12
+ description: "..."
13
+ required: true
14
+ COPT_LICENSE_DAT:
9
15
  description: "..."
10
16
  required: true
11
- # COPT_CLIENT_INI:
12
- # description: "..."
13
- # required: true
14
17
  # MOSEK_LICENSE:
15
18
  # description: "..."
16
19
  # required: true
17
20
  # GITHUB_TOKEN:
18
21
  # description: "..."
19
22
  # required: true
20
- CHECK_LICENSE:
23
+ CHECK_LICENSE:
21
24
  description: "..."
22
25
  required: true
23
26
 
@@ -33,18 +36,21 @@ runs:
33
36
  id: cache-installers-linux
34
37
  uses: actions/cache@v4
35
38
  env:
36
- cache-name: cache-installers-linux
39
+ cache-name: cache-installers-linux-v2
37
40
  with:
38
41
  path: ~/installers
39
- key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('optimizer_version.toml') }}
42
+ key: ${{ runner.os }}-build-${{ env.cache-name }}-v2-${{ hashFiles('optimizer_version.toml') }}
40
43
  restore-keys: |
41
- ${{ runner.os }}-build-${{ env.cache-name }}-
44
+ ${{ runner.os }}-build-${{ env.cache-name }}-v2-
42
45
 
43
- - if: ${{ steps.cache-installers-linux.outputs.cache-hit != 'true' }}
46
+ - if: ${{ steps.cache-installers-linux-v2.outputs.cache-hit != 'true' }}
44
47
  shell: bash
45
48
  name: Download Installers
46
49
  run: |
47
50
  curl -L -o ~/installers/gurobi.tar.gz https://packages.gurobi.com/12.0/gurobi12.0.2_linux64.tar.gz
51
+ curl -L -o ~/installers/idaes-solvers.tar.gz https://github.com/IDAES/idaes-ext/releases/download/3.4.2/idaes-solvers-ubuntu2204-x86_64.tar.gz
52
+ curl -L -o ~/installers/copt.tar.gz https://pub.shanshu.ai/download/copt/7.2.11/linux64/CardinalOptimizer-7.2.11-lnx64.tar.gz
53
+ # curl -L -o ~/installers/mosek.tar.bz2 https://download.mosek.com/stable/10.2.0/mosektoolslinux64x86.tar.bz2
48
54
 
49
55
  - name: Setup Gurobi Installation
50
56
  shell: bash
@@ -59,41 +65,41 @@ runs:
59
65
  echo "PATH=${PATH}:${GUROBI_HOME}/bin" >> $GITHUB_ENV
60
66
  echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${GUROBI_HOME}/lib" >> $GITHUB_ENV
61
67
  echo $GUROBI_HOME
62
-
68
+
63
69
  # setup license using secrets
64
70
  echo "$GUROBI_WLS" > ~/gurobi.lic
65
71
  echo "GRB_LICENSE_FILE=${HOME}/gurobi.lic" >> $GITHUB_ENV
66
72
  - name: Test Gurobi
67
73
  if: ${{ inputs.CHECK_LICENSE == 'true' }}
68
- uses: nick-fields/retry@v3 # wait 30 seconds (5x) if all licenses are already in use
74
+ uses: nick-fields/retry@v3 # wait 30 seconds (5x) if all licenses are already in use
69
75
  with:
70
76
  max_attempts: 5
71
77
  retry_wait_seconds: 30
72
78
  timeout_minutes: 1
73
79
  command: gurobi_cl
74
80
 
75
- # - name: Setup COPT Installation
76
- # shell: bash
77
- # env:
78
- # COPT_CLIENT_INI: ${{ inputs.COPT_CLIENT_INI }}
79
- # run: |
80
- # tar xfz ~/installers/copt.tar.gz -C ~/
81
- # ls ~/copt72
82
- # # set environment variables
83
- # export COPT_HOME="${HOME}/copt72"
84
- # echo "COPT_HOME=${COPT_HOME}" >> $GITHUB_ENV
85
- # echo "PATH=${PATH}:${COPT_HOME}/bin" >> $GITHUB_ENV
86
- # echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${COPT_HOME}/lib" >> $GITHUB_ENV
87
- # echo $COPT_HOME
88
-
89
- # # Just use the size-limited license
90
- # # echo "$COPT_CLIENT_INI" > ~/client.ini
91
- # # echo "COPT_LICENSE_DIR=${HOME}" >> $GITHUB_ENV
92
- # - name: Test COPT
93
- # if: ${{ inputs.CHECK_LICENSE == 'true' }}
94
- # shell: bash
95
- # run: |
96
- # copt_cmd -c "quit"
81
+ - name: Setup COPT Installation
82
+ shell: bash
83
+ env:
84
+ COPT_LICENSE_KEY: ${{ inputs.COPT_LICENSE_KEY }}
85
+ COPT_LICENSE_DAT: ${{ inputs.COPT_LICENSE_DAT }}
86
+ run: |
87
+ tar xfz ~/installers/copt.tar.gz -C ~/
88
+ ls ~/copt72
89
+ # set environment variables
90
+ export COPT_HOME="${HOME}/copt72"
91
+ echo "COPT_HOME=${COPT_HOME}" >> $GITHUB_ENV
92
+ echo "PATH=${PATH}:${COPT_HOME}/bin" >> $GITHUB_ENV
93
+ echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${COPT_HOME}/lib" >> $GITHUB_ENV
94
+ echo $COPT_HOME
95
+ echo "$COPT_LICENSE_KEY" > ${COPT_HOME}/license.key
96
+ echo "$COPT_LICENSE_DAT" > ${COPT_HOME}/license.dat
97
+ echo "COPT_LICENSE_DIR=${COPT_HOME}" >> $GITHUB_ENV
98
+ - name: Test COPT
99
+ if: ${{ inputs.CHECK_LICENSE == 'true' }}
100
+ shell: bash
101
+ run: |
102
+ copt_cmd -c "quit"
97
103
 
98
104
  # - name: Setup MOSEK Installation
99
105
  # shell: bash
@@ -118,15 +124,16 @@ runs:
118
124
  # run: |
119
125
  # msktestlic
120
126
 
121
- # - name: Setup IPOPT Installation
122
- # shell: bash
123
- # run: |
124
- # mkdir -p ~/ipopt
125
- # tar xfz ~/installers/idaes-solvers.tar.gz -C ~/ipopt
126
- # echo "PATH=${PATH}:${HOME}/ipopt" >> $GITHUB_ENV
127
- # echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${HOME}/ipopt" >> $GITHUB_ENV
128
- # ls ~/ipopt
129
- # - name: Test IPOPT
130
- # shell: bash
131
- # run: |
132
- # ipopt -v
127
+ - name: Setup IPOPT Installation
128
+ shell: bash
129
+ run: |
130
+ sudo apt-get install -y libopenblas-dev liblapack3 libgfortran5
131
+ mkdir -p ~/ipopt
132
+ tar xfz ~/installers/idaes-solvers.tar.gz -C ~/ipopt
133
+ echo "PATH=${PATH}:${HOME}/ipopt" >> $GITHUB_ENV
134
+ echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${HOME}/ipopt" >> $GITHUB_ENV
135
+ ls ~/ipopt
136
+ - name: Test IPOPT
137
+ shell: bash
138
+ run: |
139
+ ipopt -v
@@ -1,3 +1,8 @@
1
+ # This workflow runs the tests.
2
+ # It is triggered automatically on pull requests and is also run weekly on the main branch.
3
+ # Tests are run in a matrix of different Python versions.
4
+ # This test also uploads coverage results to Codecov.
5
+
1
6
  # Note: We use the insecure pull_request_target to allow running workflows from forks.
2
7
  # However, we've added checks (see below) for safety.
3
8
  # In short, the 'safe to test' label must exist AND the workflow must be run by someone with write access.
@@ -75,13 +80,15 @@ jobs:
75
80
  with:
76
81
  python-version: ${{ matrix.python-version }}
77
82
  cache: "pip"
78
- - uses: ./.github/actions/setup_optimizers_linux
83
+ - name: Setup optimizers
84
+ uses: ./.github/actions/setup_optimizers_linux
79
85
  with:
80
86
  GUROBI_WLS: ${{ secrets.GUROBI_WLS }}
87
+ COPT_LICENSE_KEY: ${{ secrets.COPT_LICENSE_KEY }}
88
+ COPT_LICENSE_DAT: ${{ secrets.COPT_LICENSE_DAT }}
81
89
  CHECK_LICENSE: true
82
90
  - name: Install dependencies
83
- run: |
84
- pip install --editable .[dev]
91
+ run: pip install -e .[dev]
85
92
  - name: Run tests and collect coverage
86
93
  run: pytest --cov
87
94
  - name: Upload coverage to Codecov
@@ -1,3 +1,4 @@
1
+ # This workflow ensures that `ruff check` passes on pull requests.
1
2
  name: Check formatting with Ruff
2
3
 
3
4
  on: [pull_request]
@@ -1,3 +1,5 @@
1
+ # This workflow adds a comment to pull requests with the number of lines added, deleted, and changed.
2
+
1
3
  # MIT License
2
4
  # Copyright (c) 2021 Viacheslav Poturaev
3
5
  name: Comment on PR with lines changed
@@ -1,3 +1,4 @@
1
+ # This workflow ensures that `ruff format` passes on pull requests.
1
2
  name: Check linting with Ruff
2
3
  on: [pull_request]
3
4
 
@@ -0,0 +1,54 @@
1
+ # This workflow runs every time a new tag is released and publishes the documentation to the website.
2
+ name: Docs
3
+ on:
4
+ workflow_dispatch:
5
+ release:
6
+ types: [released]
7
+ env:
8
+ ENABLED_GIT_REVISION_DATE: true
9
+ ENABLED_GIT_COMMITTERS: true
10
+ DOCS_PRERELEASE: false
11
+ permissions:
12
+ contents: write
13
+ jobs:
14
+ deploy:
15
+ runs-on: ubuntu-latest
16
+ environment: build-docs
17
+ steps:
18
+ - uses: actions/checkout@v4
19
+ with:
20
+ fetch-depth: 0 # Needed for git-revision-date-localized plugin
21
+ fetch-tags: true
22
+ - name: Configure Git Credentials
23
+ run: |
24
+ git config user.name github-actions[bot]
25
+ git config user.email 41898282+github-actions[bot]@users.noreply.github.com
26
+ - uses: actions/setup-python@v5
27
+ with:
28
+ python-version: 3.x
29
+ cache: 'pip'
30
+ - run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
31
+ - uses: actions/cache@v4
32
+ with:
33
+ key: mkdocs-material-${{ env.cache_id }}
34
+ path: .cache
35
+ restore-keys: |
36
+ mkdocs-material-
37
+ - run: pip install .[docs]
38
+ - name: Get latest tag
39
+ id: tags
40
+ run: |
41
+ # Get the latest tag like v1.2.3, remove the leading 'v' if present, and remove the patch version
42
+ latest_tag=$(git describe --tags --abbrev=0)
43
+ clean_tag=${latest_tag#v}
44
+ minor_tag=$(echo "$clean_tag" | cut -d. -f1-2)
45
+
46
+ echo "latest_tag=$latest_tag" >> $GITHUB_ENV
47
+ echo "minor_tag=$minor_tag" >> $GITHUB_ENV
48
+ # Some examples
49
+ # https://github.com/squidfunk/mkdocs-material/discussions/6546
50
+ # https://github.com/arduino/arduino-cli/blob/master/.github/workflows/deploy-cobra-mkdocs-versioned-poetry.yml
51
+ # https://blog.grosdouli.dev/blog/mkdocs-mike-integration#setup-github-workflows
52
+ - run: mike deploy --update-aliases --push --title $latest_tag $minor_tag latest
53
+ env:
54
+ MKDOCS_GIT_COMMITTERS_APIKEY : ${{ secrets.MKDOCS_GIT_COMMITTERS_APIKEY }}
@@ -0,0 +1,43 @@
1
+ # This workflow runs on every commit to main and publishes a development version of the documentation to the website.
2
+ name: Publish dev docs
3
+ on:
4
+ workflow_dispatch:
5
+ push:
6
+ branches: [main]
7
+ env:
8
+ ENABLED_GIT_REVISION_DATE: true
9
+ ENABLED_GIT_COMMITTERS: true
10
+ DOCS_PRERELEASE: true
11
+ permissions:
12
+ contents: write
13
+ jobs:
14
+ deploy:
15
+ runs-on: ubuntu-latest
16
+ environment: build-docs
17
+ steps:
18
+ - uses: actions/checkout@v4
19
+ with:
20
+ fetch-depth: 0 # Needed for git-revision-date-localized plugin
21
+ - name: Configure Git Credentials
22
+ run: |
23
+ git config user.name github-actions[bot]
24
+ git config user.email 41898282+github-actions[bot]@users.noreply.github.com
25
+ - uses: actions/setup-python@v5
26
+ with:
27
+ python-version: 3.x
28
+ cache: "pip"
29
+ - run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
30
+ - uses: actions/cache@v4
31
+ with:
32
+ key: mkdocs-material-${{ env.cache_id }}
33
+ path: .cache
34
+ restore-keys: |
35
+ mkdocs-material-
36
+ - run: pip install .[docs]
37
+ # Some examples
38
+ # https://github.com/squidfunk/mkdocs-material/discussions/6546
39
+ # https://github.com/arduino/arduino-cli/blob/master/.github/workflows/deploy-cobra-mkdocs-versioned-poetry.yml
40
+ # https://blog.grosdouli.dev/blog/mkdocs-mike-integration#setup-github-workflows
41
+ - run: mike deploy --push dev
42
+ env:
43
+ MKDOCS_GIT_COMMITTERS_APIKEY: ${{ secrets.MKDOCS_GIT_COMMITTERS_APIKEY }}
@@ -1,3 +1,4 @@
1
+ # This workflow runs when a new release is published and uploads the package to PyPI.
1
2
  name: PyPi Publishing
2
3
 
3
4
  on:
@@ -0,0 +1,23 @@
1
+ # This workflow runs on pull requests and tests that building the docs works
2
+ name: Test documentation builds
3
+ on:
4
+ pull_request:
5
+ branches: ["*"]
6
+ jobs:
7
+ run:
8
+ runs-on: ubuntu-latest
9
+ steps:
10
+ - uses: actions/checkout@v4
11
+ - uses: actions/setup-python@v5
12
+ with:
13
+ python-version: 3.x
14
+ cache: "pip"
15
+ - run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
16
+ - uses: actions/cache@v4
17
+ with:
18
+ key: mkdocs-material-${{ env.cache_id }}
19
+ path: .cache
20
+ restore-keys: |
21
+ mkdocs-material-
22
+ - run: pip install .[docs]
23
+ - run: mkdocs build --strict
@@ -7,10 +7,10 @@ build
7
7
  tmp
8
8
  .coverage
9
9
  .cache
10
- docs/reference
11
10
  dist
12
11
  *.log
13
12
  site
14
13
  .idea
15
14
  src/pyoframe/_version.py
16
15
  htmlcov/
16
+ .snakemake/
@@ -0,0 +1,15 @@
1
+ repos:
2
+ - repo: https://github.com/astral-sh/ruff-pre-commit
3
+ # Ruff version.
4
+ rev: v0.12.7
5
+ hooks:
6
+ # Run the linter.
7
+ - id: ruff-check
8
+ args: [ --fix ]
9
+ # Run the formatter.
10
+ - id: ruff-format
11
+ - repo: https://github.com/adamtheturtle/doccmd-pre-commit
12
+ rev: v2025.4.8
13
+ hooks:
14
+ - id: doccmd
15
+ args: ["--language", "python", "--no-pad-file", "--no-use-pty", "--command", "ruff format", "docs/"]
@@ -0,0 +1,17 @@
1
+ {
2
+ // Use IntelliSense to learn about possible attributes.
3
+ // Hover to view descriptions of existing attributes.
4
+ // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5
+ "version": "0.2.0",
6
+ "configurations": [
7
+ {
8
+ "name": "Debug mkdocs",
9
+ "type": "debugpy",
10
+ "request": "launch",
11
+ "module": "mkdocs",
12
+ "args": [
13
+ "serve"
14
+ ]
15
+ }
16
+ ]
17
+ }
@@ -0,0 +1,14 @@
1
+ {
2
+ "python.testing.unittestEnabled": false,
3
+ "python.testing.pytestEnabled": true,
4
+ "cSpell.words": [
5
+ "dataframes",
6
+ "Gurobi",
7
+ "highs",
8
+ "ipopt",
9
+ "Pyoframe"
10
+ ],
11
+ "python.testing.pytestArgs": [
12
+ "."
13
+ ]
14
+ }
@@ -1,11 +1,11 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyoframe
3
- Version: 0.2.0
3
+ Version: 1.0.0
4
4
  Summary: Blazing fast linear program interface
5
5
  Author-email: Bravos Power <dev@bravospower.com>
6
6
  License-Expression: MIT
7
- Project-URL: Homepage, https://bravos-power.github.io/pyoframe/
8
- Project-URL: documentation, https://bravos-power.github.io/pyoframe/
7
+ Project-URL: Homepage, https://bravos-power.github.io/pyoframe/latest
8
+ Project-URL: documentation, https://bravos-power.github.io/pyoframe/latest
9
9
  Project-URL: repository, https://github.com/Bravos-Power/pyoframe/
10
10
  Project-URL: Issues, https://github.com/Bravos-Power/pyoframe/issues
11
11
  Classifier: Programming Language :: Python :: 3
@@ -16,51 +16,57 @@ Requires-Python: >=3.9
16
16
  Description-Content-Type: text/markdown
17
17
  License-File: LICENSE
18
18
  Requires-Dist: polars~=1.0
19
- Requires-Dist: numpy
20
19
  Requires-Dist: pyarrow
21
20
  Requires-Dist: pandas
22
- Requires-Dist: pyoptinterface<1,>=0.4.1
23
- Provides-Extra: dev
24
- Requires-Dist: ruff; extra == "dev"
25
- Requires-Dist: polars>=1.30.0; extra == "dev"
26
- Requires-Dist: bumpver; extra == "dev"
27
- Requires-Dist: pip-tools; extra == "dev"
28
- Requires-Dist: pytest; extra == "dev"
29
- Requires-Dist: pytest-cov; extra == "dev"
30
- Requires-Dist: pre-commit; extra == "dev"
31
- Requires-Dist: gurobipy; extra == "dev"
32
- Requires-Dist: highsbox; extra == "dev"
33
- Requires-Dist: coverage; extra == "dev"
34
- Requires-Dist: ipykernel; extra == "dev"
35
- Requires-Dist: pytest-markdown-docs; extra == "dev"
36
- Requires-Dist: mkdocs-material==9.*; extra == "dev"
37
- Requires-Dist: mkdocstrings[python]; extra == "dev"
38
- Requires-Dist: mkdocs-git-revision-date-localized-plugin; extra == "dev"
39
- Requires-Dist: mkdocs-git-committers-plugin-2; extra == "dev"
40
- Requires-Dist: mkdocs-gen-files; extra == "dev"
41
- Requires-Dist: mkdocs-section-index; extra == "dev"
42
- Requires-Dist: mkdocs-literate-nav; extra == "dev"
43
- Requires-Dist: mkdocs-table-reader-plugin; extra == "dev"
44
- Requires-Dist: markdown-hide-code>=0.1.1; extra == "dev"
21
+ Requires-Dist: pyoptinterface==0.5.1
45
22
  Provides-Extra: highs
46
23
  Requires-Dist: highsbox; extra == "highs"
24
+ Provides-Extra: ipopt
25
+ Requires-Dist: pyoptinterface[nlp]; extra == "ipopt"
26
+ Requires-Dist: llvmlite<=0.44.0; extra == "ipopt"
27
+ Provides-Extra: dev
28
+ Requires-Dist: ruff==0.12.11; extra == "dev"
29
+ Requires-Dist: polars>=1.32.3; extra == "dev"
30
+ Requires-Dist: pytest==8.4.1; extra == "dev"
31
+ Requires-Dist: pytest-cov==6.2.1; extra == "dev"
32
+ Requires-Dist: sybil[pytest]==9.2.0; extra == "dev"
33
+ Requires-Dist: pre-commit==4.3.0; extra == "dev"
34
+ Requires-Dist: gurobipy==12.0.3; extra == "dev"
35
+ Requires-Dist: coverage==7.10.6; extra == "dev"
36
+ Requires-Dist: ipykernel==6.30.1; extra == "dev"
37
+ Requires-Dist: highsbox; extra == "dev"
38
+ Requires-Dist: pyoptinterface[nlp]; extra == "dev"
39
+ Requires-Dist: numpy; extra == "dev"
40
+ Provides-Extra: docs
41
+ Requires-Dist: mkdocs-material~=9.6.18; extra == "docs"
42
+ Requires-Dist: mkdocstrings[python]~=0.30.0; extra == "docs"
43
+ Requires-Dist: mkdocs-git-revision-date-localized-plugin~=1.4.7; extra == "docs"
44
+ Requires-Dist: mkdocs-git-committers-plugin-2~=2.5.0; extra == "docs"
45
+ Requires-Dist: mkdocs-gen-files~=0.5.0; extra == "docs"
46
+ Requires-Dist: mkdocs-section-index~=0.3.10; extra == "docs"
47
+ Requires-Dist: mkdocs-awesome-nav~=3.1.2; extra == "docs"
48
+ Requires-Dist: doccmd==2025.4.8; extra == "docs"
49
+ Requires-Dist: mkdocs-table-reader-plugin~=3.1.0; extra == "docs"
50
+ Requires-Dist: markdown-katex==202406.1035; extra == "docs"
51
+ Requires-Dist: mike==2.1.3; extra == "docs"
52
+ Requires-Dist: ruff==0.12.11; extra == "docs"
47
53
  Dynamic: license-file
48
54
 
49
55
  # Pyoframe: Fast and low-memory linear programming models
50
56
 
51
57
  [![codecov](https://codecov.io/gh/Bravos-Power/pyoframe/graph/badge.svg?token=8258XESRYQ)](https://codecov.io/gh/Bravos-Power/pyoframe)
52
58
  [![Build](https://github.com/Bravos-Power/pyoframe/actions/workflows/ci.yml/badge.svg)](https://github.com/Bravos-Power/pyoframe/actions/workflows/ci.yml)
53
- [![Docs](https://github.com/Bravos-Power/pyoframe/actions/workflows/publish_doc.yml/badge.svg)](https://Bravos-Power.github.io/pyoframe/reference/)
59
+ [![Docs](https://github.com/Bravos-Power/pyoframe/actions/workflows/publish_doc.yml/badge.svg)](https://Bravos-Power.github.io/pyoframe/latest/reference/)
54
60
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
55
61
  [![Issues Needing Triage](https://img.shields.io/github/issues-search/Bravos-Power/pyoframe?query=no%3Alabel%20is%3Aopen&label=Needs%20Triage)](https://github.com/Bravos-Power/pyoframe/issues?q=is%3Aopen+is%3Aissue+no%3Alabel)
56
62
  [![Open Bugs](https://img.shields.io/github/issues-search/Bravos-Power/pyoframe?query=label%3Abug%20is%3Aopen&label=Open%20Bugs)](https://github.com/Bravos-Power/pyoframe/issues?q=is%3Aopen+is%3Aissue+label%3Abug)
57
63
 
58
64
 
59
- A library to rapidly and memory-efficiently formulate large and sparse optimization models using Pandas or Polars dataframes.
65
+ A library to rapidly and memory-efficiently formulate large and sparse optimization models using Pandas or Polars DataFrames.
60
66
 
61
- ## **[Documentation](https://bravos-power.github.io/pyoframe/)**
67
+ ## **[Documentation](https://bravos-power.github.io/pyoframe/latest/)**
62
68
 
63
- [Read the documentation](https://bravos-power.github.io/pyoframe/) to get started or to learn how to [contribute](https://bravos-power.github.io/pyoframe/contribute/).
69
+ [Read the documentation](https://bravos-power.github.io/pyoframe/latest/) to get started or to learn how to [contribute](https://bravos-power.github.io/pyoframe/latest/contribute/index.md).
64
70
 
65
71
 
66
72
  ## Acknowledgments
@@ -2,17 +2,17 @@
2
2
 
3
3
  [![codecov](https://codecov.io/gh/Bravos-Power/pyoframe/graph/badge.svg?token=8258XESRYQ)](https://codecov.io/gh/Bravos-Power/pyoframe)
4
4
  [![Build](https://github.com/Bravos-Power/pyoframe/actions/workflows/ci.yml/badge.svg)](https://github.com/Bravos-Power/pyoframe/actions/workflows/ci.yml)
5
- [![Docs](https://github.com/Bravos-Power/pyoframe/actions/workflows/publish_doc.yml/badge.svg)](https://Bravos-Power.github.io/pyoframe/reference/)
5
+ [![Docs](https://github.com/Bravos-Power/pyoframe/actions/workflows/publish_doc.yml/badge.svg)](https://Bravos-Power.github.io/pyoframe/latest/reference/)
6
6
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
7
7
  [![Issues Needing Triage](https://img.shields.io/github/issues-search/Bravos-Power/pyoframe?query=no%3Alabel%20is%3Aopen&label=Needs%20Triage)](https://github.com/Bravos-Power/pyoframe/issues?q=is%3Aopen+is%3Aissue+no%3Alabel)
8
8
  [![Open Bugs](https://img.shields.io/github/issues-search/Bravos-Power/pyoframe?query=label%3Abug%20is%3Aopen&label=Open%20Bugs)](https://github.com/Bravos-Power/pyoframe/issues?q=is%3Aopen+is%3Aissue+label%3Abug)
9
9
 
10
10
 
11
- A library to rapidly and memory-efficiently formulate large and sparse optimization models using Pandas or Polars dataframes.
11
+ A library to rapidly and memory-efficiently formulate large and sparse optimization models using Pandas or Polars DataFrames.
12
12
 
13
- ## **[Documentation](https://bravos-power.github.io/pyoframe/)**
13
+ ## **[Documentation](https://bravos-power.github.io/pyoframe/latest/)**
14
14
 
15
- [Read the documentation](https://bravos-power.github.io/pyoframe/) to get started or to learn how to [contribute](https://bravos-power.github.io/pyoframe/contribute/).
15
+ [Read the documentation](https://bravos-power.github.io/pyoframe/latest/) to get started or to learn how to [contribute](https://bravos-power.github.io/pyoframe/latest/contribute/index.md).
16
16
 
17
17
 
18
18
  ## Acknowledgments
@@ -0,0 +1,93 @@
1
+ """File related to setting up pytest."""
2
+
3
+ import doctest
4
+ import os
5
+ import warnings
6
+ from pathlib import Path
7
+
8
+ import polars as pl
9
+ import pytest
10
+
11
+ import pyoframe as pf
12
+
13
+
14
+ def _setup_before_each_test(doctest_namespace):
15
+ doctest_namespace["pf"] = pf
16
+ pf.Config.reset_defaults()
17
+ pf.Config.enable_is_duplicated_expression_safety_check = True
18
+
19
+
20
+ @pytest.fixture(autouse=True)
21
+ def _setup_fixture(doctest_namespace):
22
+ _setup_before_each_test(doctest_namespace)
23
+
24
+
25
+ def pytest_collection_modifyitems(items):
26
+ """Exclude certain paths from contributing to the test coverage.
27
+
28
+ Specifically, the integration tests and documentation code snippets are not
29
+ counted towards the coverage metrics because they're not rigorous enough.
30
+
31
+ See:
32
+ - https://docs.pytest.org/en/stable/reference/reference.html#pytest.hookspec.pytest_collection_modifyitems
33
+ - https://stackoverflow.com/questions/60608511/pytest-cov-dont-count-coverage-for-the-directory-of-integration-tests
34
+ """
35
+ root_dir = Path(__file__).parent
36
+ no_coverage_paths = (
37
+ root_dir / "docs",
38
+ root_dir / "tests" / "test_examples.py",
39
+ )
40
+
41
+ for item in items:
42
+ test_path = Path(item.fspath)
43
+ if any(test_path.is_relative_to(p) for p in no_coverage_paths):
44
+ item.add_marker(pytest.mark.no_cover)
45
+
46
+
47
+ @pytest.fixture(scope="module")
48
+ def markdown_setup_fixture_module():
49
+ cwd = os.getcwd()
50
+ yield
51
+ os.chdir(cwd)
52
+
53
+
54
+ @pytest.fixture
55
+ def markdown_setup_fixture():
56
+ pl.Config.restore_defaults()
57
+ pl.Config.set_tbl_hide_dataframe_shape(True)
58
+ yield
59
+ pl.Config.set_tbl_hide_dataframe_shape(False)
60
+
61
+
62
+ SYBIL = False
63
+ try:
64
+ from sybil import Sybil
65
+ from sybil.evaluators.doctest import NUMBER
66
+ from sybil.parsers.markdown import (
67
+ ClearNamespaceParser,
68
+ PythonCodeBlockParser,
69
+ SkipParser,
70
+ )
71
+ from sybil.parsers.rest import DocTestParser
72
+
73
+ SYBIL = True
74
+ except ImportError:
75
+ # Sybil is not installed, so we won't collect markdown files.
76
+ pass
77
+
78
+ if SYBIL:
79
+ pytest_collect_file = Sybil(
80
+ parsers=[
81
+ PythonCodeBlockParser(),
82
+ SkipParser(),
83
+ ClearNamespaceParser(),
84
+ DocTestParser(
85
+ optionflags=doctest.ELLIPSIS | NUMBER | doctest.NORMALIZE_WHITESPACE
86
+ ),
87
+ ],
88
+ patterns=["*.md"],
89
+ setup=_setup_before_each_test,
90
+ fixtures=["markdown_setup_fixture", "markdown_setup_fixture_module"],
91
+ ).pytest()
92
+ else:
93
+ warnings.warn("Sybil not installed. Documentation tests will not run.")
@@ -0,0 +1,13 @@
1
+ sort:
2
+ by: filename
3
+ nav:
4
+ - Home: index.md
5
+ - Learn:
6
+ - learn/get-started
7
+ - learn/concepts
8
+ - learn/advanced-concepts
9
+ - learn/migrate
10
+ - examples
11
+ - reference
12
+ - why-pyoframe/index.md
13
+ - contribute