* rename swig files .i in .swig * update constraint_solver and routing * backport math_opt changes * move dynamic loading to ortools/third_party_solvers
111 lines
4.1 KiB
Protocol Buffer
111 lines
4.1 KiB
Protocol Buffer
// Copyright 2010-2025 Google LLC
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
// you may not use this file except in compliance with the License.
|
|
// You may obtain a copy of the License at
|
|
//
|
|
// http://www.apache.org/licenses/LICENSE-2.0
|
|
//
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
// See the License for the specific language governing permissions and
|
|
// limitations under the License.
|
|
|
|
// Protocol buffer used to store search statistics.
|
|
|
|
syntax = "proto3";
|
|
|
|
option java_package = "com.google.ortools.constraintsolver";
|
|
option java_multiple_files = true;
|
|
option csharp_namespace = "Google.OrTools.ConstraintSolver";
|
|
|
|
package operations_research;
|
|
|
|
// Statistics on local search.
|
|
message LocalSearchStatistics {
|
|
// First solution statistics collected during search.
|
|
message FirstSolutionStatistics {
|
|
// Name of the strategy used.
|
|
string strategy = 1;
|
|
// Time spent in the decision builder.
|
|
double duration_seconds = 2;
|
|
}
|
|
// Statistics for each first solution called during the search.
|
|
repeated FirstSolutionStatistics first_solution_statistics = 6;
|
|
// Statistics on local search operators called during the search.
|
|
message LocalSearchOperatorStatistics {
|
|
// Name of the operator.
|
|
string local_search_operator = 1;
|
|
// Number of neighbors generated by the operator.
|
|
int64 num_neighbors = 2;
|
|
// Number of neighbors which were filtered.
|
|
int64 num_filtered_neighbors = 3;
|
|
// Number of neighbors eventually accepted.
|
|
int64 num_accepted_neighbors = 4;
|
|
// Time spent in the operator.
|
|
double duration_seconds = 5;
|
|
// Time spent in creating neighbors (calling MakeNextNeighbor).
|
|
double make_next_neighbor_duration_seconds = 6;
|
|
// Time spent in accepting a neighbor (restoration and storage, not
|
|
// including filtering).
|
|
double accept_neighbor_duration_seconds = 7;
|
|
}
|
|
// Statistics for each operator called during the search.
|
|
repeated LocalSearchOperatorStatistics local_search_operator_statistics = 1;
|
|
// Total number of (filtered/accepted) neighbors created during the search.
|
|
int64 total_num_neighbors = 3;
|
|
int64 total_num_filtered_neighbors = 4;
|
|
int64 total_num_accepted_neighbors = 5;
|
|
// Statistics on local search filters called during the search.
|
|
message LocalSearchFilterStatistics {
|
|
// Name of the filter.
|
|
string local_search_filter = 1;
|
|
// Number of times the filter was called.
|
|
int64 num_calls = 2;
|
|
// Number of times the filter rejected a neighbor.
|
|
int64 num_rejects = 3;
|
|
// Time spent in the filter.
|
|
double duration_seconds = 4;
|
|
// Number of rejects per second.
|
|
double num_rejects_per_second = 5;
|
|
// Context within which the filter was called.
|
|
string context = 6;
|
|
}
|
|
// Statistics for each filter called during the search.
|
|
repeated LocalSearchFilterStatistics local_search_filter_statistics = 2;
|
|
}
|
|
|
|
// Statistics on the search in the constraint solver.
|
|
message ConstraintSolverStatistics {
|
|
// Number of branches explored.
|
|
int64 num_branches = 1;
|
|
// Number of failures/backtracks.
|
|
int64 num_failures = 2;
|
|
// Number of solutions found.
|
|
int64 num_solutions = 3;
|
|
// Memory usage of the solver.
|
|
int64 bytes_used = 4;
|
|
// Total time spent in the solver.
|
|
double duration_seconds = 5;
|
|
}
|
|
|
|
// Statistics on sub-solvers.
|
|
message SubSolverStatistics {
|
|
// Number of calls to Glop in LP scheduling.
|
|
int64 num_glop_calls_in_lp_scheduling = 1;
|
|
// Number of calls to CP-SAT in LP scheduling.
|
|
int64 num_cp_sat_calls_in_lp_scheduling = 2;
|
|
// Number of calls to min cost flow.
|
|
int64 num_min_cost_flow_calls = 3;
|
|
}
|
|
|
|
// Search statistics.
|
|
message SearchStatistics {
|
|
// Local search statistics for each solver context.
|
|
repeated LocalSearchStatistics local_search_statistics = 1;
|
|
// Constraint solver statistics.
|
|
repeated ConstraintSolverStatistics constraint_solver_statistics = 2;
|
|
// Sub-solver statistics.
|
|
repeated SubSolverStatistics sub_solver_statistics = 3;
|
|
}
|