-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
allocator: scale member ItemLimit to the relative share of ItemSlots
Item replication may not be evenly distributed. Previously, we were not accounting for this within each allocation sub-problem, and scaled member ItemLimits by the relative ratio of items in each sub-problem rather than the relative ratio of item *slots*. This caused excessive re-assignement of items in solved maximum assignment flows, as push/relabel must spend more time back-tracking as it overflows the initial constraints on item limits. Introduce a new BenchmarkChangingReplication which reproduces this effect. Then, solve it by tweaking sparse flow network construction to scale a member ItemLimit by the relative portion of assignment slots that must be allocated within each sub-problem (rather than just the relative number of items). BenchmarkChangingReplication confirms this heuristic update dramatically reduces the degree of assignment churn (note `run.ratio`, which is a measure of average churn per item replication change): Before: final metrics adds=142806 packs=90617 removes=83044 run.ratio=16.58809060161935 run.total=9757 After: final metrics adds=69854 packs=4457 removes=10092 run.ratio=1.6343138259710976 run.total=9757
- Loading branch information
1 parent
da22df6
commit f510dce
Showing
3 changed files
with
178 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters