Fixed the ridge regression trainer