Rewrote RandOMs and MaxMargin to descend from WeightLearningApplication.