update sat_runner
This commit is contained in:
@@ -284,6 +284,17 @@ cc_binary(
|
||||
],
|
||||
)
|
||||
|
||||
cc_binary(
|
||||
name = "magic_sequence_sat",
|
||||
srcs = ["magic_sequence_sat.cc"],
|
||||
deps = [
|
||||
"//ortools/base",
|
||||
"@com_google_absl//absl/strings",
|
||||
"//ortools/sat:cp_model",
|
||||
"//ortools/sat:model",
|
||||
],
|
||||
)
|
||||
|
||||
cc_binary(
|
||||
name = "magic_square_sat",
|
||||
srcs = ["magic_square_sat.cc"],
|
||||
@@ -328,6 +339,17 @@ cc_binary(
|
||||
],
|
||||
)
|
||||
|
||||
cc_binary(
|
||||
name = "multi_knapsack_sat",
|
||||
srcs = ["multi_knapsack_sat.cc"],
|
||||
deps = [
|
||||
"//ortools/base",
|
||||
"@com_google_absl//absl/strings",
|
||||
"//ortools/sat:cp_model",
|
||||
"//ortools/sat:model",
|
||||
],
|
||||
)
|
||||
|
||||
cc_binary(
|
||||
name = "network_routing_sat",
|
||||
srcs = ["network_routing_sat.cc"],
|
||||
|
||||
@@ -199,6 +199,7 @@ int Run() {
|
||||
}
|
||||
|
||||
// Parse the --params flag.
|
||||
parameters.set_log_search_progress(true);
|
||||
if (!absl::GetFlag(FLAGS_params).empty()) {
|
||||
CHECK(google::protobuf::TextFormat::MergeFromString(
|
||||
absl::GetFlag(FLAGS_params), ¶meters))
|
||||
@@ -445,9 +446,8 @@ int main(int argc, char** argv) {
|
||||
// By default, we want to show how the solver progress. Note that this needs
|
||||
// to be set before InitGoogle() which has the nice side-effect of allowing
|
||||
// the user to override it.
|
||||
absl::SetFlag(&FLAGS_vmodule, "cp_model_solver=1");
|
||||
gflags::SetUsageMessage(kUsage);
|
||||
gflags::ParseCommandLineFlags(&argc, &argv, true);
|
||||
google::InitGoogleLogging(kUsage);
|
||||
absl::ParseCommandLine(argc, argv);
|
||||
absl::SetFlag(&FLAGS_alsologtostderr, true);
|
||||
return operations_research::sat::Run();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user