Commit Graph

262 Commits

Author SHA1 Message Date
Guillaume Chatelet
6d76575f3d Format xpress files 2025-12-15 13:06:04 +01:00
Mizux Seiha
26b01437f4 math_opt: backport from main 2025-12-09 22:49:43 +01:00
Guillaume Chatelet
7345481dfe Remove fuzztest support from OR-Tools (#4938)
* Remove fuzztest support from OR-Tools
2025-12-08 11:31:29 +01:00
Guillaume Chatelet
b880e0fb64 Use new bintest framework (#4928) 2025-12-02 15:33:12 +01:00
Corentin Le Molgat
91e63a7d41 scip: Fix 10.0.0 support 2025-12-01 17:48:28 +01:00
Corentin Le Molgat
d15a2e67e3 math_opt: export from google3 2025-11-24 13:56:15 +01:00
Corentin Le Molgat
8e56816c8a cmake: fixup 2025-11-21 14:23:30 +01:00
Corentin Le Molgat
ebe81847a8 cmake: fix configure when using -DBUILD_TESTING=OFF 2025-11-21 11:21:29 +01:00
Corentin Le Molgat
f204b720b8 glpk: move it to third_party_solvers/ 2025-11-12 17:26:40 +01:00
Corentin Le Molgat
b0800ae209 math_opt: backport from main 2025-11-05 13:54:57 +01:00
Corentin Le Molgat
b4b226801b update include guards 2025-11-05 11:54:02 +01:00
Corentin Le Molgat
6969f23df4 math_opt: export absl_nonnull attribute from google3 2025-11-05 11:29:11 +01:00
Corentin Le Molgat
901027adeb math_opt: export from google3 2025-10-16 17:02:41 +02:00
Corentin Le Molgat
2fc6549813 math_opt: backport from main 2025-10-16 13:07:05 +02:00
Guillaume Chatelet
4a3e68cc2e Fix math_opt tests 2025-10-16 11:44:18 +02:00
Guillaume Chatelet
8710e86e8a Test export 2025-10-16 11:43:45 +02:00
Guillaume Chatelet
e1f2e3f0d7 Remove unneeded string_view_migration 2025-10-01 08:08:36 +02:00
Guillaume Chatelet
3d96b9a6ac [bazel] mark a few more tests as manual 2025-10-01 08:08:16 +02:00
Guillaume Chatelet
54ae17fa91 [bazel] Update bazel files 2025-09-29 17:21:58 +02:00
Corentin Le Molgat
67e1520a41 math_opt: backport from main 2025-09-22 17:23:15 +02:00
Mizux Seiha
4f381f6d07 backport from main:
* bump abseil to 20250814
* bump protobuf to v32.0
* cmake: add ccache auto support
* backport flatzinc, math_opt and sat update
2025-09-16 16:25:04 +02:00
Corentin Le Molgat
b27676402f math_opt: fixup 2025-08-29 18:08:51 +02:00
Mizux Seiha
c89483a0db math_opt: add cpp/model_test 2025-08-29 15:31:26 +02:00
Mizux Seiha
a144ae4033 math_opt: export few cpp/ tests 2025-08-29 15:31:26 +02:00
Mizux Seiha
bb745da2c2 base: rework to match google3 2025-08-29 15:31:26 +02:00
Corentin Le Molgat
5b7702910a math_opt: fix visibility issue 2025-08-27 15:10:10 +02:00
Corentin Le Molgat
e48814866f math_opt: cleanup 2025-08-27 15:10:01 +02:00
Corentin Le Molgat
ba7e81f729 ortools: various export from google3 2025-08-22 14:24:48 +02:00
Corentin Le Molgat
30805fd498 math_opt: fix gscip_from_mp_model_proto_test 2025-08-20 14:27:46 +02:00
Mizux Seiha
1bf2448981 cmake: fix math_opt update
* fix cxx build
* fix python build
2025-08-20 11:37:19 +02:00
Corentin Le Molgat
82bc28d3c1 math_opt: backport from google3
* move gscip/ to math_opt/solvers/
2025-08-20 11:36:44 +02: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
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
Guillaume Chatelet
6759325e87 Fix load statements 2025-07-24 16:37:06 +00:00
Guillaume Chatelet
447ce0b3e2 Fix bazel load rules 2025-07-23 09:05:10 +00:00
Pavlo Muts
fd1443e820 Implement setting of partial solution, activate corresponding tests 2025-07-22 19:29:26 +02:00
Pavlo Muts
97636fdec7 test: enable primal only warm starts for Highs LP model solve parameters 2025-07-22 13:29:46 +02:00
Pavlo Muts
0ab3f0fabd setSolution() from Highs accepts solution hint 2025-07-22 10:49:51 +02:00
Guillaume Chatelet
8098080ff3 Merge pull request #4735 from google/backport_string_view_migration
Backport string_view_migration.h
2025-07-21 10:01:20 +02:00
Guillaume Chatelet
924ba73402 Fix
* Re-introduce it in base/ BUILD.bazel
* Add explicit deps in every target using it
2025-07-18 16:18:11 +00:00
Guillaume Chatelet
7db9c0e956 Backport string_view_migration.h 2025-07-18 11:59:34 +00:00
Guillaume Chatelet
d869a1fd4c Backport trivial changes 2025-07-18 08:11:03 +00:00
Corentin Le Molgat
d90690fcf4 math_opt: remove scaler_util (not used) 2025-07-07 11:28:20 +02:00
Laurent Perron
6c09169099 missing files 2025-07-01 17:07:29 +02:00
Laurent Perron
5b1376b9df small cleaning 2025-07-01 16:51:11 +02:00
Corentin Le Molgat
15824de47d math_opt: export from google3
* Protobuf::StringCopy LSC
* absl_nonnull attribut
2025-06-23 18:15:45 +02:00
Laurent Perron
9888ce3da1 polish third_party_solvers; speed up cp-sat on no_ovrlap_2d 2025-06-19 14:08:49 +02:00
Laurent Perron
c4b01c1294 reorganize gurobi and xpress side loading 2025-06-18 18:20:30 +02:00
Laurent Perron
1c81bd833c more gscip cleaning 2025-06-17 12:47:56 +02:00
Corentin Le Molgat
7b67f855e6 cleanup and formatting 2025-06-16 17:55:56 +02:00