There should be what to do after saving the trained Scikit-Learn model (e.g., using joblib)
The code show how to save but not say how to use, access it later! So it not meaningful yet.
If you using pickle library to save the model. you can use pickle.load() to access it later. https://www.geeksforgeeks.org/understanding-python-pickling-example/
Hi @ladylazy9x , Thanks for your feedback. Both the book and the notebook contain the following code:
import joblib
joblib.dump(my_model, "my_model.pkl")
#...
my_model_loaded = joblib.load("my_model.pkl")
This shows how to save the model using joblib.dump() and how to recover it later using joblib.load(). Does this answer your question or were you referring to something else?
my_model_loaded
Dear @ageron
yeah, I think there should be how to use the my_model_loaded after that. Like what my_model_loaded is like. What does it contain? Show the reader until this fit to their work.
Oh I see! It's just identical to my_model. So you can make predictions with it, just like you would with my_model:
my_model_loaded.predict(X_new)
Makes sense?