Commit Graph

15533 Commits

Author SHA1 Message Date
Corentin Le Molgat
d206973ced bazel: fix sat loads 2025-08-08 09:07:52 +02:00
Mizux Seiha
01d00d98cf Merge remote-tracking branch 'origin/v99bugfix' 2025-08-07 13:19:08 +02:00
Mizux Seiha
badef91fb5 Merge remote-tracking branch 'origin/stable' into v99bugfix 2025-08-07 13:17:42 +02:00
Mizux Seiha
aa28d976ac Merge remote-tracking branch 'origin/v99bugfix' 2025-08-07 12:46:55 +02:00
Mizux Seiha
d389457ae8 cmake: regenerate docs/ images 2025-08-07 12:46:27 +02:00
Mizux Seiha
a762c579b7 cmake: update docs/ 2025-08-07 12:45:53 +02:00
Corentin Le Molgat
3a97726664 linear_solver: backport .lp support to solve_model 2025-08-06 13:21:18 +02:00
Corentin Le Molgat
260856bf0f linear_solver: rework python typing 2025-08-06 13:20:32 +02:00
Corentin Le Molgat
9cde24d763 highs: rework HighsInterface::Solve 2025-08-06 10:59:09 +02:00
Corentin Le Molgat
80af949922 bazel: fix with_highs support 2025-08-06 10:58:29 +02:00
Corentin Le Molgat
2fd586595b bazel: fix more load statements 2025-08-06 10:57:31 +02:00
Corentin Le Molgat
0db80a34f6 sat: backport from main 2025-08-06 10:54:53 +02:00
Corentin Le Molgat
5d5a115dec util: add MatrixOrFunction 2025-08-06 10:53:59 +02:00
Corentin Le Molgat
bcf774e65a math_opt: backport from main 2025-08-06 10:53:04 +02:00
Corentin Le Molgat
679b042944 bazel: regenerate requirements.txt 2025-08-06 10:09:34 +02:00
Corentin Le Molgat
3bef66b3cb bazel: regenerate requirements.txt 2025-08-06 09:50:36 +02:00
Laurent Perron
4ffb359524 [Bazel] enable highs for linear_solver by default; better support for highs in linear_solver; read .lp file in solve_model.py 2025-08-05 10:26:22 -07:00
Laurent Perron
9fa0db877b Merge pull request #4745 from flokli/scip-tests
math_opt: only run SCIP tests if enabled
2025-08-01 14:05:24 -07:00
Florian Klink
b5a2f8ac40 math_opt: only run SCIP tests if enabled
Usage of SCIP library can be disabled in CMake build by setting
-DUSE_SCIP=OFF.

However, the tests were still run unconditionally, showing test failures like this:

```
/build/source/ortools/math_opt/solver_tests/test_models_test.cc:29: Failure
Value of: Solve(*model, SolverType::kGscip)
Expected: is OK and has a value that (is an object whose field `termination` (is an object whose field `reason` is equal to optimal) and (is an object whose field `problem_status` (is an object whose field `primal_status` is equal to feasible) and (is an object whose field `dual_status` is equal to feasible) and (is an object whose field `primal_or_dual_infeasible` is equal to false))) and (is an object whose property `has_primal_feasible_solution` is equal to true) and (is an object whose property `objective_value` is approximately 9 (absolute error <= 1.0000000000000001e-05))
  Actual: [INVALID_ARGUMENT: solver type SOLVER_TYPE_GSCIP is not registered, support for this solver has not been compiled], which has status INVALID_ARGUMENT: solver type SOLVER_TYPE_GSCIP is not registered, support for this solver has not been compiled

[  FAILED  ] SmallModelTest.Integer (2 ms)
[ RUN      ] SmallModelTest.Continuous
[       OK ] SmallModelTest.Continuous (1 ms)
[----------] 2 tests from SmallModelTest (3 ms total)

[----------] 2 tests from DenseIndependentSetTest
[ RUN      ] DenseIndependentSetTest.Integer
/build/source/ortools/math_opt/solver_tests/test_models_test.cc:40: Failure
Value of: Solve(*model, SolverType::kGscip)
Expected: is OK and has a value that (is an object whose field `termination` (is an object whose field `reason` is equal to optimal) and (is an object whose field `problem_status` (is an object whose field `primal_status` is equal to feasible) and (is an object whose field `dual_status` is equal to feasible) and (is an object whose field `primal_or_dual_infeasible` is equal to false))) and (is an object whose property `has_primal_feasible_solution` is equal to true) and (is an object whose property `objective_value` is approximately 7 (absolute error <= 1.0000000000000001e-05))
  Actual: [INVALID_ARGUMENT: solver type SOLVER_TYPE_GSCIP is not registered, support for this solver has not been compiled], which has status INVALID_ARGUMENT: solver type SOLVER_TYPE_GSCIP is not registered, support for this solver has not been compiled

[  FAILED  ] DenseIndependentSetTest.Integer (0 ms)
[ RUN      ] DenseIndependentSetTest.Continuous
[       OK ] DenseIndependentSetTest.Continuous (1 ms)
[----------] 2 tests from DenseIndependentSetTest (2 ms total)

[----------] 1 test from DenseIndependentSetHint5Test
[ RUN      ] DenseIndependentSetHint5Test.HintIsFeasibleWithObjective5
/build/source/ortools/math_opt/solver_tests/test_models_test.cc:59: Failure
Value of: Solve(*model, SolverType::kGscip)
Expected: is OK and has a value that (is an object whose field `termination` (is an object whose field `reason` is equal to optimal) and (is an object whose field `problem_status` (is an object whose field `primal_status` is equal to feasible) and (is an object whose field `dual_status` is equal to feasible) and (is an object whose field `primal_or_dual_infeasible` is equal to false))) and (is an object whose property `has_primal_feasible_solution` is equal to true) and (is an object whose property `objective_value` is approximately 5 (absolute error <= 1.0000000000000001e-05))
  Actual: [INVALID_ARGUMENT: solver type SOLVER_TYPE_GSCIP is not registered, support for this solver has not been compiled], which has status INVALID_ARGUMENT: solver type SOLVER_TYPE_GSCIP is not registered, support for this solver has not been compiled

[  FAILED  ] DenseIndependentSetHint5Test.HintIsFeasibleWithObjective5 (0 ms)
[----------] 1 test from DenseIndependentSetHint5Test (0 ms total)

[----------] 2 tests from IndependentSetCompleteGraphTest
[ RUN      ] IndependentSetCompleteGraphTest.Integer
/build/source/ortools/math_opt/solver_tests/test_models_test.cc:65: Failure
Value of: Solve(*model, SolverType::kGscip)
Expected: is OK and has a value that (is an object whose field `termination` (is an object whose field `reason` is equal to optimal) and (is an object whose field `problem_status` (is an object whose field `primal_status` is equal to feasible) and (is an object whose field `dual_status` is equal to feasible) and (is an object whose field `primal_or_dual_infeasible` is equal to false))) and (is an object whose property `has_primal_feasible_solution` is equal to true) and (is an object whose property `objective_value` is approximately 1 (absolute error <= 1.0000000000000001e-05))
  Actual: [INVALID_ARGUMENT: solver type SOLVER_TYPE_GSCIP is not registered, support for this solver has not been compiled], which has status INVALID_ARGUMENT: solver type SOLVER_TYPE_GSCIP is not registered, support for this solver has not been compiled

[  FAILED  ] IndependentSetCompleteGraphTest.Integer (0 ms)
```

Fix this, by conditionalizing these tests on USE_SCIP.
2025-08-01 14:53:43 +02:00
Laurent Perron
32bd8e0209 [CP-SAT] small cleanup, more work on linear2 2025-07-31 13:57:50 -07:00
Laurent Perron
0e4f0bcad7 Merge pull request #4700 from google/dependabot/pip/bazel/pip-2c7469b053
build(deps): bump urllib3 from 2.2.2 to 2.5.0 in /bazel in the pip group across 1 directory
2025-07-29 10:59:28 -07:00
Laurent Perron
9fa9bd4da4 [CP-SAT] better dtime for scheduling constraints; connect the time limit in the repair_hint mode; fix #4743 2025-07-29 09:07:13 -07:00
Laurent Perron
a3fc2000e4 Merge pull request #4737 from pavlomuts/highs_solution_hint
Pass solution hint to HiGHS from mathopt
2025-07-29 05:44:53 -07:00
Laurent Perron
13e2a14ab6 wrap flat matrices 2025-07-28 10:34:48 -07:00
Laurent Perron
87a66e6239 update python typing 2025-07-28 10:34:20 -07:00
Laurent Perron
99ede3bbde [CP-SAT] more polishing on the python API; fix #4733; improve linear2 processing 2025-07-28 10:34:04 -07:00
Laurent Perron
374cc3e596 polish code 2025-07-27 15:29:20 -07:00
Laurent Perron
a0e25debc5 [CP-SAT] extend support for enforcement literals in constraints 2025-07-26 21:29:40 +02:00
Laurent Perron
8b4c79dd75 [CP-SAT] Python: rewrite support for variable numbers of arguments 2025-07-26 21:29:09 +02:00
Laurent Perron
f2cf147e79 [CP-SAT] rewrite and speed up the python layer; extend support for enforcement literals to more constraints 2025-07-24 23:51:00 +02:00
Guillaume Chatelet
f1113bcb47 Fix load statements 2025-07-24 20:55:56 +02:00
Guillaume Chatelet
99694439f1 Remove duplicated load statement 2025-07-24 16:39:17 +00:00
Guillaume Chatelet
6759325e87 Fix load statements 2025-07-24 16:37:06 +00:00
Mizux Seiha
91e0e8a70f ci: bump actions/setup-java to v4 2025-07-24 10:17:09 +02:00
Mizux Seiha
0a0fd2c761 bazel: fixup requirements.txt 2025-07-24 10:16:40 +02:00
Mizux Seiha
abe220e357 bazel/docker: bump bazelisk to 1.25 2025-07-24 10:15:55 +02:00
Guillaume Chatelet
5ffb66cdce Fix bazel load rules 2025-07-24 10:10:29 +02:00
Corentin Le Molgat
6a6e57a0b8 ci: fix system_deps python jobs not using archlinux's pybind11 3.0.0 2025-07-24 09:52:38 +02:00
Corentin Le Molgat
f0d0fe71ba examples: backport from main 2025-07-23 23:12:34 +02:00
Corentin Le Molgat
a7f49a2585 backport from main
* rename swig files .i in .swig
* update constraint_solver and routing
* backport math_opt changes
* move dynamic loading to ortools/third_party_solvers
2025-07-23 23:12:34 +02:00
Corentin Le Molgat
03e2551e61 set_cover: backport from main 2025-07-23 15:06:59 +02:00
Corentin Le Molgat
4151254eba sat: backport from main 2025-07-23 15:04:05 +02:00
Guillaume Chatelet
cddd80e8e2 Backport string_view_migration.h 2025-07-23 15:04:05 +02:00
Corentin Le Molgat
fd1b2cc68c ci: remove mvn custom build in cmake windows jobs
note: now runners do provide mvn 3.9.11
2025-07-23 15:04:05 +02:00
Corentin Le Molgat
5b6f33d75c cmake: disable fuzztest by default
no distro provide it
2025-07-23 15:04:05 +02:00
Corentin Le Molgat
0ea743fe9a bazel(ci): bazelisk cleanup 2025-07-23 15:04:04 +02:00
Corentin Le Molgat
c268b16b6a tools: backport from main 2025-07-23 15:04:04 +02:00
Corentin Le Molgat
3f48e2f1d5 tools/docker: backport from main 2025-07-23 15:04:04 +02:00
Guillaume Chatelet
ff01f2f1af Merge pull request #4740 from google/fix_bazel_rules
Fix bazel load rules
2025-07-23 11:11:47 +02:00
Guillaume Chatelet
447ce0b3e2 Fix bazel load rules 2025-07-23 09:05:10 +00:00