python-constraint2 2.2.3__tar.gz → 2.3.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/PKG-INFO +28 -20
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/README.rst +27 -19
- python_constraint2-2.3.1/constraint/constraints.c +55117 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/constraints.py +761 -109
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/domain.c +3740 -3264
- python_constraint2-2.3.1/constraint/parser.c +23450 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/parser.py +127 -30
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/problem.c +6522 -6493
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/solvers.c +9857 -11090
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/pyproject.toml +1 -1
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_parser.py +63 -9
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_solvers.py +43 -0
- python_constraint2-2.2.3/constraint/constraints.c +0 -30433
- python_constraint2-2.2.3/constraint/parser.c +0 -19108
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/LICENSE +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/__init__.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/domain.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/problem.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/solvers.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/cythonize_build.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/__init__.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/benchmarks.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/setup_teardown.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_compilation.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_constraint.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_doctests.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_problem.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_some_not_in_set.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_toml_file.py +0 -0
- {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_util_benchmark.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: python-constraint2
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.3.1
|
|
4
4
|
Summary: python-constraint is a module for efficiently solving CSPs (Constraint Solving Problems) over finite domains.
|
|
5
5
|
License: BSD-2-Clause
|
|
6
6
|
Keywords: CSP,constraint solving problems,problem solver,SMT,satisfiability modulo theory,SAT
|
|
@@ -48,6 +48,7 @@ python-constraint
|
|
|
48
48
|
| New: writing constraints in the new string format is preferable over functions and lambdas.
|
|
49
49
|
| These strings, even as compound statements, are automatically parsed to faster built-in constraints, are more concise, and do not require constraint solving familiarity by the user to be efficient.
|
|
50
50
|
| For example, :code:`problem.addConstraint(["50 <= x * y < 100"])` is parsed to :code:`[MinProdConstraint(50, ["x", "y"]), MaxProdConstraint(100, ["x", "y"])]`.
|
|
51
|
+
| Similarly, :code:`problem.addConstraint(["x / y == z"])` is parsed to :code:`[ExactProdConstraint("x", ["z", "y"])]`.
|
|
51
52
|
| This feature is in beta and subject to possible change, please provide feedback.
|
|
52
53
|
|
|
53
54
|
.. contents::
|
|
@@ -147,29 +148,36 @@ Features
|
|
|
147
148
|
|
|
148
149
|
The following solvers are available:
|
|
149
150
|
|
|
150
|
-
-
|
|
151
|
-
-
|
|
152
|
-
-
|
|
153
|
-
-
|
|
154
|
-
-
|
|
151
|
+
- :code:`OptimizedBacktrackingSolver` (default)
|
|
152
|
+
- :code:`BacktrackingSolver`
|
|
153
|
+
- :code:`RecursiveBacktrackingSolver`
|
|
154
|
+
- :code:`MinConflictsSolver`
|
|
155
|
+
- :code:`ParallelSolver`
|
|
155
156
|
|
|
156
157
|
.. role:: python(code)
|
|
157
158
|
:language: python
|
|
158
159
|
|
|
159
|
-
Predefined constraint types currently available:
|
|
160
|
-
|
|
161
|
-
- :
|
|
162
|
-
- :
|
|
163
|
-
- :
|
|
164
|
-
- :
|
|
165
|
-
- :
|
|
166
|
-
- :
|
|
167
|
-
- :
|
|
168
|
-
- :
|
|
169
|
-
- :
|
|
170
|
-
- :
|
|
171
|
-
- :
|
|
172
|
-
- :
|
|
160
|
+
Predefined constraint types currently available (use the parsing for automatic conversion to these types):
|
|
161
|
+
|
|
162
|
+
- :code:`FunctionConstraint`
|
|
163
|
+
- :code:`AllDifferentConstraint`
|
|
164
|
+
- :code:`AllEqualConstraint`
|
|
165
|
+
- :code:`ExactSumConstraint`
|
|
166
|
+
- :code:`MinSumConstraint`
|
|
167
|
+
- :code:`MaxSumConstraint`
|
|
168
|
+
- :code:`MinProdConstraint`
|
|
169
|
+
- :code:`ExactProdConstraint`
|
|
170
|
+
- :code:`MaxProdConstraint`
|
|
171
|
+
- :code:`VariableExactSumConstraint`
|
|
172
|
+
- :code:`VariableMinSumConstraint`
|
|
173
|
+
- :code:`VariableMaxSumConstraint`
|
|
174
|
+
- :code:`VariableMinProdConstraint`
|
|
175
|
+
- :code:`VariableExactProdConstraint`
|
|
176
|
+
- :code:`VariableMaxProdConstraint`
|
|
177
|
+
- :code:`InSetConstraint`
|
|
178
|
+
- :code:`NotInSetConstraint`
|
|
179
|
+
- :code:`SomeInSetConstraint`
|
|
180
|
+
- :code:`SomeNotInSetConstraint`
|
|
173
181
|
|
|
174
182
|
API documentation
|
|
175
183
|
-----------------
|
|
@@ -15,6 +15,7 @@ python-constraint
|
|
|
15
15
|
| New: writing constraints in the new string format is preferable over functions and lambdas.
|
|
16
16
|
| These strings, even as compound statements, are automatically parsed to faster built-in constraints, are more concise, and do not require constraint solving familiarity by the user to be efficient.
|
|
17
17
|
| For example, :code:`problem.addConstraint(["50 <= x * y < 100"])` is parsed to :code:`[MinProdConstraint(50, ["x", "y"]), MaxProdConstraint(100, ["x", "y"])]`.
|
|
18
|
+
| Similarly, :code:`problem.addConstraint(["x / y == z"])` is parsed to :code:`[ExactProdConstraint("x", ["z", "y"])]`.
|
|
18
19
|
| This feature is in beta and subject to possible change, please provide feedback.
|
|
19
20
|
|
|
20
21
|
.. contents::
|
|
@@ -114,29 +115,36 @@ Features
|
|
|
114
115
|
|
|
115
116
|
The following solvers are available:
|
|
116
117
|
|
|
117
|
-
-
|
|
118
|
-
-
|
|
119
|
-
-
|
|
120
|
-
-
|
|
121
|
-
-
|
|
118
|
+
- :code:`OptimizedBacktrackingSolver` (default)
|
|
119
|
+
- :code:`BacktrackingSolver`
|
|
120
|
+
- :code:`RecursiveBacktrackingSolver`
|
|
121
|
+
- :code:`MinConflictsSolver`
|
|
122
|
+
- :code:`ParallelSolver`
|
|
122
123
|
|
|
123
124
|
.. role:: python(code)
|
|
124
125
|
:language: python
|
|
125
126
|
|
|
126
|
-
Predefined constraint types currently available:
|
|
127
|
-
|
|
128
|
-
- :
|
|
129
|
-
- :
|
|
130
|
-
- :
|
|
131
|
-
- :
|
|
132
|
-
- :
|
|
133
|
-
- :
|
|
134
|
-
- :
|
|
135
|
-
- :
|
|
136
|
-
- :
|
|
137
|
-
- :
|
|
138
|
-
- :
|
|
139
|
-
- :
|
|
127
|
+
Predefined constraint types currently available (use the parsing for automatic conversion to these types):
|
|
128
|
+
|
|
129
|
+
- :code:`FunctionConstraint`
|
|
130
|
+
- :code:`AllDifferentConstraint`
|
|
131
|
+
- :code:`AllEqualConstraint`
|
|
132
|
+
- :code:`ExactSumConstraint`
|
|
133
|
+
- :code:`MinSumConstraint`
|
|
134
|
+
- :code:`MaxSumConstraint`
|
|
135
|
+
- :code:`MinProdConstraint`
|
|
136
|
+
- :code:`ExactProdConstraint`
|
|
137
|
+
- :code:`MaxProdConstraint`
|
|
138
|
+
- :code:`VariableExactSumConstraint`
|
|
139
|
+
- :code:`VariableMinSumConstraint`
|
|
140
|
+
- :code:`VariableMaxSumConstraint`
|
|
141
|
+
- :code:`VariableMinProdConstraint`
|
|
142
|
+
- :code:`VariableExactProdConstraint`
|
|
143
|
+
- :code:`VariableMaxProdConstraint`
|
|
144
|
+
- :code:`InSetConstraint`
|
|
145
|
+
- :code:`NotInSetConstraint`
|
|
146
|
+
- :code:`SomeInSetConstraint`
|
|
147
|
+
- :code:`SomeNotInSetConstraint`
|
|
140
148
|
|
|
141
149
|
API documentation
|
|
142
150
|
-----------------
|