Finish training and predict