Adaptive lambdas for loss functions