1
votes

I'm working on a machine learning classification task in which I have trained many models with different algorithms in scikit-learn and Random Forest Classifier performed the best. Now I want to train the model further with new examples but if I train the same model by calling the fit method on new examples then it will start training the model from beginning by erasing the old parameters. So, how can I train the trained model by training it with new examples in scikit-learn?

I got some idea by reading online to pickle and unpickle the model but how would it help I don't know.

3
Maybe something proposed here will help datascience.stackexchange.com/questions/28512/…rafvasq
I have checked that page before asking my question here and the answers to that question are not helpful.NikeshPrasad9

3 Answers

1
votes

You should use incremental learning and estimators implementing the partial_fit API.

0
votes

RandomForrestClassifier has a flag warm_start. Note that this will not give the same results as if you train on both sets at once.

0
votes

Append the new data to your existing dataset, and train over the whole thing. Might want to reserve some of the new data for your testset.