Advanced Code Template (PRACTICAL)

Important information on code changes & updates can be found below this video

Code notes: Newer versions of scikit-learn (since recording) may have updates or changes.

One Hot Encoder: Updated parameter names.

Two examples that you might come across:

  • sparse = False updated to sparse_output = False
  • get_feature_names() updated to get_feature_names_out()


Pickle:

If you encounter the error message No module named 'pandas.core.indexes.numeric' when attempting to read in the pickle file, please use the Pandas version of read_pickle() instead:

data_for_model = pd.read_pickle("data/abc_classification_modelling.p")



Complete and Continue