How to save & load xgboost model?

后端 未结 5 452
南方客
南方客 2020-12-04 18:00

On the link of XGBoost guide:

After training, the model can be saved.

bst.save_model(\'0001.model\')

The model a

5条回答
  •  一个人的身影
    2020-12-04 18:08

    An easy way of saving and loading a xgboost model is with joblib library.

    import joblib
    #save model
    joblib.dump(xgb, filename) 
    
    #load saved model
    xgb = joblib.load(filename)
    

提交回复
热议问题