Skip to content

Commit

Permalink
use tolerance to prune nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
hlefebvr committed Nov 29, 2024
1 parent 29efe30 commit 21fd882
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -795,7 +795,7 @@ void idol::Optimizers::BranchAndBound<NodeInfoT>::prune_nodes_by_bound(BranchAnd
const double raw_lower_bound = node.info().objective_value();
const double lower_bound = m_has_integer_objective && !is_integer(raw_lower_bound, Tolerance::Integer) ? std::ceil(raw_lower_bound) : raw_lower_bound;

if (lower_bound >= upper_bound) { // TODO use tolerance in terms of gap
if (lower_bound >= upper_bound - get_tol_mip_absolute_gap()) {
it = t_active_nodes.erase(it);
end = t_active_nodes.by_objective_value().end();
} else {
Expand Down

0 comments on commit 21fd882

Please sign in to comment.