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.
Files changed (30) hide show
  1. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/PKG-INFO +28 -20
  2. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/README.rst +27 -19
  3. python_constraint2-2.3.1/constraint/constraints.c +55117 -0
  4. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/constraints.py +761 -109
  5. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/domain.c +3740 -3264
  6. python_constraint2-2.3.1/constraint/parser.c +23450 -0
  7. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/parser.py +127 -30
  8. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/problem.c +6522 -6493
  9. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/solvers.c +9857 -11090
  10. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/pyproject.toml +1 -1
  11. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_parser.py +63 -9
  12. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_solvers.py +43 -0
  13. python_constraint2-2.2.3/constraint/constraints.c +0 -30433
  14. python_constraint2-2.2.3/constraint/parser.c +0 -19108
  15. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/LICENSE +0 -0
  16. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/__init__.py +0 -0
  17. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/domain.py +0 -0
  18. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/problem.py +0 -0
  19. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/constraint/solvers.py +0 -0
  20. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/cythonize_build.py +0 -0
  21. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/__init__.py +0 -0
  22. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/benchmarks.py +0 -0
  23. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/setup_teardown.py +0 -0
  24. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_compilation.py +0 -0
  25. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_constraint.py +0 -0
  26. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_doctests.py +0 -0
  27. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_problem.py +0 -0
  28. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_some_not_in_set.py +0 -0
  29. {python_constraint2-2.2.3 → python_constraint2-2.3.1}/tests/test_toml_file.py +0 -0
  30. {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.2.3
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
- - Backtracking solver
151
- - Optimized backtracking solver
152
- - Recursive backtracking solver
153
- - Minimum conflicts solver
154
- - Parallel solver
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
- - :python:`FunctionConstraint`
162
- - :python:`AllDifferentConstraint`
163
- - :python:`AllEqualConstraint`
164
- - :python:`MaxSumConstraint`
165
- - :python:`ExactSumConstraint`
166
- - :python:`MinSumConstraint`
167
- - :python:`MaxProdConstraint`
168
- - :python:`MinProdConstraint`
169
- - :python:`InSetConstraint`
170
- - :python:`NotInSetConstraint`
171
- - :python:`SomeInSetConstraint`
172
- - :python:`SomeNotInSetConstraint`
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
- - Backtracking solver
118
- - Optimized backtracking solver
119
- - Recursive backtracking solver
120
- - Minimum conflicts solver
121
- - Parallel solver
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
- - :python:`FunctionConstraint`
129
- - :python:`AllDifferentConstraint`
130
- - :python:`AllEqualConstraint`
131
- - :python:`MaxSumConstraint`
132
- - :python:`ExactSumConstraint`
133
- - :python:`MinSumConstraint`
134
- - :python:`MaxProdConstraint`
135
- - :python:`MinProdConstraint`
136
- - :python:`InSetConstraint`
137
- - :python:`NotInSetConstraint`
138
- - :python:`SomeInSetConstraint`
139
- - :python:`SomeNotInSetConstraint`
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
  -----------------