misc
This commit is contained in:
committed by
Corentin Le Molgat
parent
e55172a5d2
commit
b6c198050d
@@ -184,7 +184,7 @@ ComputeShortestPath(const GraphType& graph,
|
||||
}
|
||||
|
||||
if (std::vector<typename GraphType::NodeIndex> path =
|
||||
std::move(dijkstra.NodePathTo(destination));
|
||||
dijkstra.NodePathTo(destination);
|
||||
!path.empty()) {
|
||||
return {std::move(path), path_length};
|
||||
} else {
|
||||
|
||||
@@ -440,6 +440,7 @@ cc_test(
|
||||
":test_util",
|
||||
":trust_region",
|
||||
"//ortools/base:gmock_main",
|
||||
"@abseil-cpp//absl/base:core_headers",
|
||||
"@abseil-cpp//absl/strings",
|
||||
"@eigen",
|
||||
],
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
|
||||
#include "Eigen/Core"
|
||||
#include "Eigen/SparseCore"
|
||||
#include "absl/base/optimization.h"
|
||||
#include "absl/strings/str_cat.h"
|
||||
#include "absl/strings/string_view.h"
|
||||
#include "gtest/gtest.h"
|
||||
@@ -610,6 +611,7 @@ INSTANTIATE_TEST_SUITE_P(
|
||||
case PrimalDualNorm::kMaxNorm:
|
||||
return absl::StrCat("MaxNorm", "_", suffix);
|
||||
}
|
||||
ABSL_UNREACHABLE();
|
||||
});
|
||||
|
||||
TEST_P(ComputeLocalizedLagrangianBoundsTest, ZeroGapAtOptimal) {
|
||||
|
||||
@@ -115,6 +115,9 @@ class SolverLogger {
|
||||
if ((logger)->LoggingIsEnabled()) \
|
||||
(logger)->LogInfo(__FILE__, __LINE__, absl::StrCat(__VA_ARGS__))
|
||||
|
||||
#define FORCED_SOLVER_LOG(logger, ...) \
|
||||
(logger)->LogInfo(__FILE__, __LINE__, absl::StrCat(__VA_ARGS__))
|
||||
|
||||
// Simple helper class to:
|
||||
// - log in an uniform way a "time-consuming" presolve operation.
|
||||
// - track a deterministic work limit.
|
||||
|
||||
Reference in New Issue
Block a user