Stop GHC 6.6.1 from fussing about lack of a trailing newline.
[match/match.git] / program / PMDefaults.hs
CommitLineData
8c5ee850 1module PMDefaults where
05a6f0ed 2import PMInstance
8c5ee850
MM
3import ProposalMatcher
4
5import qualified NaiveMinCostFlow
6import qualified CS2MinCostFlow
7
8pmDefaults = PMConfig {
fd0d2377
MM
9
10-- Choose a min-cost flow implementation (timings on mattlaptop2):
11
12-- A naive implementation that is slow for all but the smallest instances
13-- (30s on a 20x50 example).
8c5ee850 14minCostFlow = NaiveMinCostFlow.minCostFlow,
fd0d2377
MM
15
16-- Uses CS2 (http://www.igsystems.com/cs2/), which requires a license for
17-- non-research use but is faster (<1s on a 20x50 example, 64s on a 60x500
18-- example). Configure the path to cs2.exe in CS2MinCostFlow.hs.
8c5ee850 19--minCostFlow = CS2MinCostFlow.minCostFlow,
d7d9561e 20
8c5ee850 21reviewsEachProposal = 3,
2e7d5426 22
8c5ee850
MM
23prefIsExpert = \p -> p <= 10,
24prefIsKnowledgeable = \p -> p <= 20,
2e7d5426 25
8c5ee850
MM
26prefIsBoring = \p -> p > 15,
27prefIsVeryBoring = \p -> p > 25,
2e7d5426 28
8c5ee850 29prefIsConflict = \p -> p >= 40,
d7d9561e 30
2e7d5426
MM
31-- For now this is absolute. Later it might be proportional to a reviewer's
32-- target load.
8c5ee850 33loadTolerance = 1,
d7d9561e 34
2e7d5426
MM
35-- Cost to overload by one review.
36-- tx = 0 at target load, 1 at end of tolerance.
8c5ee850 37marginalLoadCost = \tx -> 1000 + tx*1000,
2e7d5426
MM
38
39-- Cost to review a boring (or very boring) proposal.
40-- lx = 0 at no load, 1 at target load.
8c5ee850 41marginalBoringCost = \lx -> 1000 + lx*1000,
2e7d5426 42-- Additional cost to review a very boring proposal.
8c5ee850 43marginalVeryBoringCost = \lx -> 1000 + lx*1000,
2e7d5426
MM
44
45-- Cost to make a review.
d7d9561e 46-- I'm using quadratic cost functions as a first attempt.
8c5ee850 47assignmentCost = \pref -> (numAsWt 10 + pref) ^ 2,
2e7d5426
MM
48
49-- Bonus for a first knowledgeable or expert review.
8c5ee850 50knowledgeableBonus = 1000,
2e7d5426
MM
51
52-- Bonus for an additional expert review.
8c5ee850
MM
53expertBonus = 1000
54
55}