Enhanced Bin Packing propagator - #202
Conversation
be6b80c to
a883d63
Compare
zayenz
left a comment
There was a problem hiding this comment.
I pushed 44fbbe3 to fix the definite integer-range defects in the DFF arithmetic: half-capacity comparisons, transformed-weight accumulation, RMax capacity arithmetic, and lambda-step overflow. The commit also adds boundary regressions. The focused BinPacking tests pass in Debug/Audit and UBSan builds, the CMake smoke suite passes, and the tree passes tidy.
I am leaving three algorithm and policy questions for manual review:
- The sampler drops both interval endpoints and every singleton interval. That differs from the inclusive ranges in the cited algorithm and weakens propagation in at least one small case: capacity 11, three bins, weights {7, 7, 5, 5, 5} fails at the root on main, but not on this branch.
- RMin currently duplicates R0 at this call site because the minimum virtual weight is always zero.
- The sequential portfolio has a substantial hot-path cost. On u120_00 it explored the same 94 nodes and ran the same 217 propagations, but took 47.99 ms versus 2.67 ms on main (five samples, 20 runs per sample, Release builds). The paper's implementation relies on parallel evaluation of the DFF portfolio.
I would keep the PR open until we decide whether the exact L2 check should be preserved alongside the sampled portfolio, and what performance gate this propagator should meet.
|
Superseded by the replacement PR #224, which carries the BinPacking DFF work plus the local integration and overflow-safety changes on |
Hello,
This patch implements a stronger pruning technique for the BinPacking constraint. It leverages tighter lower bounds based on Dual-Feasible Functions. This approach was presented at CP 2024 in the paper CP for Bin Packing with Multi-Core and GPUs.
There might be a need for some polishing and testing, but I think the benefits are worth the effort. I attached a simple model for testing.
Cheers
bpp.mzn.txt
N2W1B2R5.dzn.txt