tentative fix for #1918

This commit is contained in:
Laurent Perron
2020-08-19 20:47:16 +02:00
parent 316875740c
commit a88f3372c2
2 changed files with 4 additions and 2 deletions

View File

@@ -55,7 +55,7 @@ LinearConstraintManager::~LinearConstraintManager() {
if (num_coeff_strenghtening_ > 0) {
VLOG(2) << "num_coeff_strenghtening: " << num_coeff_strenghtening_;
}
if (sat_parameters_.log_search_progress() && num_cuts_ > 0) {
if (log_search_progress_ && num_cuts_ > 0) {
LOG(INFO) << "Total cuts added: " << num_cuts_;
for (const auto& entry : type_to_num_cuts_) {
LOG(INFO) << "Added " << entry.second << " cuts of type '" << entry.first

View File

@@ -66,7 +66,8 @@ class LinearConstraintManager {
: sat_parameters_(*model->GetOrCreate<SatParameters>()),
integer_trail_(*model->GetOrCreate<IntegerTrail>()),
time_limit_(model->GetOrCreate<TimeLimit>()),
model_(model) {}
model_(model),
log_search_progress_(sat_parameters_.log_search_progress()) {}
~LinearConstraintManager();
// Add a new constraint to the manager. Note that we canonicalize constraints
@@ -210,6 +211,7 @@ class LinearConstraintManager {
double constraint_active_count_increase_ = 1.0;
int32 num_deletable_constraints_ = 0;
const bool log_search_progress_;
};
} // namespace sat