Fix extra 2 in the LossFunction() call.