diff --git a/cpp/src/branch_and_bound/branch_and_bound.cpp b/cpp/src/branch_and_bound/branch_and_bound.cpp index e94e8c93e1..1526baa367 100644 --- a/cpp/src/branch_and_bound/branch_and_bound.cpp +++ b/cpp/src/branch_and_bound/branch_and_bound.cpp @@ -180,7 +180,7 @@ f_t compute_user_abs_gap(const lp_problem_t& lp, f_t obj_value, f_t lo // abs_gap = |user_obj - user_lower| = |obj_scale| * |obj_value - lower_bound| // obj_constant cancels out in the subtraction; obj_scale sign must be removed via abs f_t gap = std::abs(lp.obj_scale) * (obj_value - lower_bound); - if (gap < -1e-4) { CUOPT_LOG_ERROR("Gap is negative %e", gap); } + if (gap < -1e-4) { CUOPT_LOG_DEBUG("Gap is negative %e", gap); } return gap; } diff --git a/cpp/src/mip_heuristics/mip_scaling_strategy.cu b/cpp/src/mip_heuristics/mip_scaling_strategy.cu index 0aaa606aea..f9b9037131 100644 --- a/cpp/src/mip_heuristics/mip_scaling_strategy.cu +++ b/cpp/src/mip_heuristics/mip_scaling_strategy.cu @@ -310,14 +310,14 @@ void scale_objective(cuopt::linear_programming::optimization_problem_t if (!std::isfinite(static_cast(min_abs_obj)) || min_abs_obj <= f_t(0) || max_abs_obj <= f_t(0)) { - CUOPT_LOG_INFO("MIP_OBJ_SCALING skipped: no finite nonzero objective coefficients"); + CUOPT_LOG_DEBUG("MIP_OBJ_SCALING skipped: no finite nonzero objective coefficients"); return; } if (static_cast(min_abs_obj) >= min_abs_objective_coefficient_threshold) { - CUOPT_LOG_INFO("MIP_OBJ_SCALING skipped: min_abs_coeff=%g already above threshold=%g", - static_cast(min_abs_obj), - min_abs_objective_coefficient_threshold); + CUOPT_LOG_DEBUG("MIP_OBJ_SCALING skipped: min_abs_coeff=%g already above threshold=%g", + static_cast(min_abs_obj), + min_abs_objective_coefficient_threshold); return; } @@ -326,9 +326,9 @@ void scale_objective(cuopt::linear_programming::optimization_problem_t double post_max = static_cast(max_abs_obj) * scale; if (post_max > 1.0e6) { - CUOPT_LOG_INFO("MIP_OBJ_SCALING skipped: would push max_coeff from %g to %g (limit 1e6)", - static_cast(max_abs_obj), - post_max); + CUOPT_LOG_DEBUG("MIP_OBJ_SCALING skipped: would push max_coeff from %g to %g (limit 1e6)", + static_cast(max_abs_obj), + post_max); return; } @@ -344,7 +344,7 @@ void scale_objective(cuopt::linear_programming::optimization_problem_t op_problem.set_objective_scaling_factor(old_sf / scale_f); op_problem.set_objective_offset(old_off * scale_f); - CUOPT_LOG_INFO( + CUOPT_LOG_DEBUG( "MIP_OBJ_SCALING applied: min_abs_coeff=%g max_abs_coeff=%g scale=%g new_scaling_factor=%g", static_cast(min_abs_obj), static_cast(max_abs_obj), @@ -505,7 +505,7 @@ void mip_scaling_strategy_t::scale_problem(bool do_objective_scaling) if (do_objective_scaling) { scale_objective(op_problem_scaled_); } else { - CUOPT_LOG_INFO("MIP_OBJ_SCALING skipped: disabled by user setting"); + CUOPT_LOG_DEBUG("MIP_OBJ_SCALING skipped: disabled by user setting"); } if (n_rows == 0 || nnz <= 0) { return; } @@ -565,11 +565,11 @@ void mip_scaling_strategy_t::scale_problem(bool do_objective_scaling) i_t big_m_rows = thrust::count( handle_ptr_->get_thrust_policy(), row_skip_scaling.begin(), row_skip_scaling.end(), i_t(1)); - CUOPT_LOG_INFO("MIP row scaling start: rows=%d cols=%d max_iterations=%d soft_big_m_rows=%d", - n_rows, - n_cols, - row_scaling_max_iterations, - big_m_rows); + CUOPT_LOG_DEBUG("MIP row scaling start: rows=%d cols=%d max_iterations=%d soft_big_m_rows=%d", + n_rows, + n_cols, + row_scaling_max_iterations, + big_m_rows); f_t original_max_coeff = thrust::transform_reduce(handle_ptr_->get_thrust_policy(), matrix_values.begin(), @@ -615,9 +615,9 @@ void mip_scaling_strategy_t::scale_problem(bool do_objective_scaling) const double row_log2_spread = thrust::get<3>(row_norm_log2_stats) - thrust::get<2>(row_norm_log2_stats); if (iteration == 0 && row_log2_spread <= row_scaling_min_initial_log2_spread) { - CUOPT_LOG_INFO("MIP row scaling skipped: initial_log2_spread=%g threshold=%g", - row_log2_spread, - row_scaling_min_initial_log2_spread); + CUOPT_LOG_DEBUG("MIP row scaling skipped: initial_log2_spread=%g threshold=%g", + row_log2_spread, + row_scaling_min_initial_log2_spread); break; } if (std::isfinite(previous_row_log2_spread)) { @@ -771,7 +771,7 @@ void mip_scaling_strategy_t::scale_problem(bool do_objective_scaling) iteration_scaling.begin(), iteration_scaling.end(), [] __device__(f_t row_scale) -> bool { return row_scale != f_t(1); }); - CUOPT_LOG_INFO( + CUOPT_LOG_DEBUG( "MIP_SCALING_METRICS iteration=%d log2_spread=%g target_norm=%g scaled_rows=%d " "valid_rows=%d", iteration, @@ -789,9 +789,9 @@ void mip_scaling_strategy_t::scale_problem(bool do_objective_scaling) max_op_t{}, thrust::multiplies{}); if (predicted_max > original_max_coeff) { - CUOPT_LOG_INFO("MIP_SCALING magnitude guard: predicted_max=%g > original_max=%g, stopping", - static_cast(predicted_max), - static_cast(original_max_coeff)); + CUOPT_LOG_DEBUG("MIP_SCALING magnitude guard: predicted_max=%g > original_max=%g, stopping", + static_cast(predicted_max), + static_cast(original_max_coeff)); break; } @@ -832,10 +832,10 @@ void mip_scaling_strategy_t::scale_problem(bool do_objective_scaling) } } - CUOPT_LOG_INFO("MIP_SCALING_SUMMARY rows=%d bigm_rows=%d final_spread=%g", - n_rows, - big_m_rows, - previous_row_log2_spread); + CUOPT_LOG_DEBUG("MIP_SCALING_SUMMARY rows=%d bigm_rows=%d final_spread=%g", + n_rows, + big_m_rows, + previous_row_log2_spread); cuopt_func_call(assert_integer_coefficient_integrality( op_problem_scaled_, temp_storage, temp_storage_bytes, pre_scaling_gcd, stream_view_)); @@ -867,7 +867,6 @@ void mip_scaling_strategy_t::scale_problem(bool do_objective_scaling) } CUOPT_LOG_INFO("MIP row scaling completed"); - op_problem_scaled_.print_scaling_information(); } #define INSTANTIATE(F_TYPE) template class mip_scaling_strategy_t;