gamspy 1.19.0__py3-none-any.whl → 1.19.2__py3-none-any.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.
Files changed (89) hide show
  1. gamspy/__init__.py +86 -86
  2. gamspy/__main__.py +6 -6
  3. gamspy/_algebra/__init__.py +13 -13
  4. gamspy/_algebra/condition.py +290 -290
  5. gamspy/_algebra/domain.py +103 -103
  6. gamspy/_algebra/expression.py +820 -820
  7. gamspy/_algebra/number.py +79 -79
  8. gamspy/_algebra/operable.py +185 -185
  9. gamspy/_algebra/operation.py +948 -948
  10. gamspy/_backend/backend.py +313 -313
  11. gamspy/_backend/engine.py +960 -960
  12. gamspy/_backend/local.py +124 -124
  13. gamspy/_backend/neos.py +567 -567
  14. gamspy/_cli/__init__.py +1 -1
  15. gamspy/_cli/cli.py +64 -64
  16. gamspy/_cli/gdx.py +377 -377
  17. gamspy/_cli/install.py +375 -375
  18. gamspy/_cli/list.py +94 -94
  19. gamspy/_cli/mps2gms.py +128 -128
  20. gamspy/_cli/probe.py +52 -52
  21. gamspy/_cli/retrieve.py +79 -79
  22. gamspy/_cli/run.py +158 -158
  23. gamspy/_cli/show.py +246 -246
  24. gamspy/_cli/uninstall.py +165 -165
  25. gamspy/_cli/util.py +94 -94
  26. gamspy/_communication.py +215 -215
  27. gamspy/_config.py +132 -132
  28. gamspy/_container.py +1716 -1694
  29. gamspy/_convert.py +720 -720
  30. gamspy/_database.py +271 -271
  31. gamspy/_extrinsic.py +181 -181
  32. gamspy/_miro.py +356 -356
  33. gamspy/_model.py +1803 -1803
  34. gamspy/_model_instance.py +701 -701
  35. gamspy/_options.py +780 -780
  36. gamspy/_serialization.py +156 -156
  37. gamspy/_symbols/__init__.py +17 -17
  38. gamspy/_symbols/alias.py +305 -305
  39. gamspy/_symbols/equation.py +1407 -1407
  40. gamspy/_symbols/implicits/__init__.py +11 -11
  41. gamspy/_symbols/implicits/implicit_equation.py +186 -186
  42. gamspy/_symbols/implicits/implicit_parameter.py +272 -272
  43. gamspy/_symbols/implicits/implicit_set.py +124 -124
  44. gamspy/_symbols/implicits/implicit_symbol.py +315 -315
  45. gamspy/_symbols/implicits/implicit_variable.py +255 -255
  46. gamspy/_symbols/parameter.py +648 -648
  47. gamspy/_symbols/set.py +985 -985
  48. gamspy/_symbols/symbol.py +395 -395
  49. gamspy/_symbols/universe_alias.py +182 -182
  50. gamspy/_symbols/variable.py +1101 -1101
  51. gamspy/_types.py +7 -7
  52. gamspy/_validation.py +736 -735
  53. gamspy/_workspace.py +72 -72
  54. gamspy/exceptions.py +128 -128
  55. gamspy/formulations/__init__.py +46 -46
  56. gamspy/formulations/ml/__init__.py +11 -11
  57. gamspy/formulations/ml/decision_tree_struct.py +80 -80
  58. gamspy/formulations/ml/gradient_boosting.py +203 -203
  59. gamspy/formulations/ml/random_forest.py +187 -187
  60. gamspy/formulations/ml/regression_tree.py +533 -533
  61. gamspy/formulations/nn/__init__.py +19 -19
  62. gamspy/formulations/nn/avgpool2d.py +232 -232
  63. gamspy/formulations/nn/conv1d.py +533 -533
  64. gamspy/formulations/nn/conv2d.py +529 -529
  65. gamspy/formulations/nn/linear.py +341 -341
  66. gamspy/formulations/nn/maxpool2d.py +88 -88
  67. gamspy/formulations/nn/minpool2d.py +88 -88
  68. gamspy/formulations/nn/mpool2d.py +245 -245
  69. gamspy/formulations/nn/torch_sequential.py +278 -278
  70. gamspy/formulations/piecewise.py +682 -682
  71. gamspy/formulations/result.py +119 -119
  72. gamspy/formulations/shape.py +188 -188
  73. gamspy/formulations/utils.py +173 -173
  74. gamspy/math/__init__.py +215 -215
  75. gamspy/math/activation.py +783 -783
  76. gamspy/math/log_power.py +435 -435
  77. gamspy/math/matrix.py +534 -534
  78. gamspy/math/misc.py +1709 -1709
  79. gamspy/math/probability.py +170 -170
  80. gamspy/math/trigonometric.py +232 -232
  81. gamspy/utils.py +810 -810
  82. gamspy/version.py +5 -5
  83. {gamspy-1.19.0.dist-info → gamspy-1.19.2.dist-info}/METADATA +90 -90
  84. gamspy-1.19.2.dist-info/RECORD +90 -0
  85. {gamspy-1.19.0.dist-info → gamspy-1.19.2.dist-info}/licenses/LICENSE +22 -22
  86. gamspy-1.19.0.dist-info/RECORD +0 -90
  87. {gamspy-1.19.0.dist-info → gamspy-1.19.2.dist-info}/WHEEL +0 -0
  88. {gamspy-1.19.0.dist-info → gamspy-1.19.2.dist-info}/entry_points.txt +0 -0
  89. {gamspy-1.19.0.dist-info → gamspy-1.19.2.dist-info}/top_level.txt +0 -0
gamspy/__init__.py CHANGED
@@ -1,86 +1,86 @@
1
- from __future__ import annotations
2
-
3
- from gams.transfer import SpecialValues
4
-
5
- import gamspy.formulations as formulations
6
- import gamspy.math as math
7
- import gamspy.utils as utils
8
- from gamspy._algebra import (
9
- Card,
10
- Domain,
11
- Number,
12
- Ord,
13
- Product,
14
- Sand,
15
- Smax,
16
- Smin,
17
- Sor,
18
- Sum,
19
- )
20
- from gamspy._algebra.expression import Expression
21
- from gamspy._backend.engine import EngineClient
22
- from gamspy._backend.neos import NeosClient
23
- from gamspy._config import _set_default_options, get_option, set_options
24
- from gamspy._container import Container
25
- from gamspy._model import FileFormat, Model, ModelStatus, Problem, Sense, SolveStatus
26
- from gamspy._options import ConvertOptions, FreezeOptions, Options
27
- from gamspy._serialization import deserialize, serialize
28
- from gamspy._symbols import (
29
- Alias,
30
- Equation,
31
- EquationType,
32
- Parameter,
33
- Set,
34
- UniverseAlias,
35
- Variable,
36
- VariableType,
37
- )
38
-
39
- from .version import __version__
40
-
41
- _ctx_managers: dict[tuple[int, int], Container] = {}
42
- _set_default_options()
43
-
44
- __all__ = [
45
- "Container",
46
- "Set",
47
- "Alias",
48
- "UniverseAlias",
49
- "Parameter",
50
- "Variable",
51
- "Equation",
52
- "Model",
53
- "Problem",
54
- "Sense",
55
- "VariableType",
56
- "EquationType",
57
- "ModelStatus",
58
- "SolveStatus",
59
- "Sum",
60
- "Product",
61
- "Smax",
62
- "Smin",
63
- "Sand",
64
- "Sor",
65
- "Domain",
66
- "Number",
67
- "Ord",
68
- "Card",
69
- "Options",
70
- "FreezeOptions",
71
- "ModelInstanceOptions",
72
- "ConvertOptions",
73
- "FileFormat",
74
- "Expression",
75
- "EngineClient",
76
- "NeosClient",
77
- "math",
78
- "formulations",
79
- "utils",
80
- "SpecialValues",
81
- "__version__",
82
- "get_option",
83
- "set_options",
84
- "serialize",
85
- "deserialize",
86
- ]
1
+ from __future__ import annotations
2
+
3
+ from gams.transfer import SpecialValues
4
+
5
+ import gamspy.formulations as formulations
6
+ import gamspy.math as math
7
+ import gamspy.utils as utils
8
+ from gamspy._algebra import (
9
+ Card,
10
+ Domain,
11
+ Number,
12
+ Ord,
13
+ Product,
14
+ Sand,
15
+ Smax,
16
+ Smin,
17
+ Sor,
18
+ Sum,
19
+ )
20
+ from gamspy._algebra.expression import Expression
21
+ from gamspy._backend.engine import EngineClient
22
+ from gamspy._backend.neos import NeosClient
23
+ from gamspy._config import _set_default_options, get_option, set_options
24
+ from gamspy._container import Container
25
+ from gamspy._model import FileFormat, Model, ModelStatus, Problem, Sense, SolveStatus
26
+ from gamspy._options import ConvertOptions, FreezeOptions, Options
27
+ from gamspy._serialization import deserialize, serialize
28
+ from gamspy._symbols import (
29
+ Alias,
30
+ Equation,
31
+ EquationType,
32
+ Parameter,
33
+ Set,
34
+ UniverseAlias,
35
+ Variable,
36
+ VariableType,
37
+ )
38
+
39
+ from .version import __version__
40
+
41
+ _ctx_managers: dict[tuple[int, int], Container] = {}
42
+ _set_default_options()
43
+
44
+ __all__ = [
45
+ "Container",
46
+ "Set",
47
+ "Alias",
48
+ "UniverseAlias",
49
+ "Parameter",
50
+ "Variable",
51
+ "Equation",
52
+ "Model",
53
+ "Problem",
54
+ "Sense",
55
+ "VariableType",
56
+ "EquationType",
57
+ "ModelStatus",
58
+ "SolveStatus",
59
+ "Sum",
60
+ "Product",
61
+ "Smax",
62
+ "Smin",
63
+ "Sand",
64
+ "Sor",
65
+ "Domain",
66
+ "Number",
67
+ "Ord",
68
+ "Card",
69
+ "Options",
70
+ "FreezeOptions",
71
+ "ModelInstanceOptions",
72
+ "ConvertOptions",
73
+ "FileFormat",
74
+ "Expression",
75
+ "EngineClient",
76
+ "NeosClient",
77
+ "math",
78
+ "formulations",
79
+ "utils",
80
+ "SpecialValues",
81
+ "__version__",
82
+ "get_option",
83
+ "set_options",
84
+ "serialize",
85
+ "deserialize",
86
+ ]
gamspy/__main__.py CHANGED
@@ -1,6 +1,6 @@
1
- from __future__ import annotations
2
-
3
- from gamspy._cli.cli import main
4
-
5
- if __name__ == "__main__":
6
- main()
1
+ from __future__ import annotations
2
+
3
+ from gamspy._cli.cli import main
4
+
5
+ if __name__ == "__main__":
6
+ main()
@@ -1,13 +1,13 @@
1
- # flake8: noqa
2
- from __future__ import annotations
3
-
4
- from gamspy._algebra.domain import Domain
5
- from gamspy._algebra.number import Number
6
- from gamspy._algebra.operation import Card
7
- from gamspy._algebra.operation import Ord
8
- from gamspy._algebra.operation import Product
9
- from gamspy._algebra.operation import Smax
10
- from gamspy._algebra.operation import Smin
11
- from gamspy._algebra.operation import Sum
12
- from gamspy._algebra.operation import Sand
13
- from gamspy._algebra.operation import Sor
1
+ # flake8: noqa
2
+ from __future__ import annotations
3
+
4
+ from gamspy._algebra.domain import Domain
5
+ from gamspy._algebra.number import Number
6
+ from gamspy._algebra.operation import Card
7
+ from gamspy._algebra.operation import Ord
8
+ from gamspy._algebra.operation import Product
9
+ from gamspy._algebra.operation import Smax
10
+ from gamspy._algebra.operation import Smin
11
+ from gamspy._algebra.operation import Sum
12
+ from gamspy._algebra.operation import Sand
13
+ from gamspy._algebra.operation import Sor