Fix scalastyle moanings.
Finish moving the NNLS solver.
More safeguards against numerical ridiculousness.