mirror of
https://github.com/ANL-CEEESA/MIPLearn.jl.git
synced 2025-12-06 08:28:52 -06:00
BB: Expose enable_plunging in collect
This commit is contained in:
@@ -16,6 +16,7 @@ function collect!(
|
||||
gap_limit::Float64 = 1e-4,
|
||||
print_interval::Int = 5,
|
||||
branch_rule::VariableBranchingRule = ReliabilityBranching(collect = true),
|
||||
enable_plunging = true,
|
||||
)::NodePool
|
||||
model = read_from_file(filename)
|
||||
mip = init(optimizer)
|
||||
@@ -36,6 +37,7 @@ function collect!(
|
||||
gap_limit,
|
||||
print_interval,
|
||||
branch_rule,
|
||||
enable_plunging,
|
||||
)
|
||||
|
||||
h5 = Hdf5Sample(replace(filename, ".mps.gz" => ".h5"))
|
||||
|
||||
@@ -182,6 +182,9 @@ function find_branching_var(
|
||||
end
|
||||
|
||||
function collect!(rule::ReliabilityBranching, h5)
|
||||
if rule.stats.num_strong_branch_calls == 0
|
||||
return
|
||||
end
|
||||
h5.put_array("bb_score_var_names", to_str_array(rule.stats.score_var_names))
|
||||
h5.put_array("bb_score_features", vcat(rule.stats.score_features'...))
|
||||
h5.put_array("bb_score_targets", rule.stats.score_targets)
|
||||
|
||||
Reference in New Issue
Block a user