-- Sort this proposal's reviews, best first.
let jPrefsInc = sort $ map (\i -> prefA ! (i,j)) rl in
-- Charge each review's assignmentCost.
- sum $ zipWith (\wt prf -> (numAsWt wt) * assignmentCost cfg prf)
- -- The assignment costs are weighted by
- -- reviewsEachProposal, ..., 1 from best to worst.
- -- (It's most important for the best to be good.)
- (take (reviewsEachProposal cfg) $
- iterate (subtract 1) (reviewsEachProposal cfg))
+ sum $ zipWith (\wt prf -> wt * assignmentCost cfg prf)
+ (reviewEvalWeights cfg)
-- A missing review counts as a preference of 50 (really bad).
(jPrefsInc ++ repeat 50)
- )
+ )
reviewersByProposal
doEvaluateMatching :: PMConfig -> PMInstance -> MatchingEvaluation