Model = joblib.load('/home/ncpd241/Service/SI_MODEL_FINAL.pkl') error


/home/ncpd241/Service/ FutureWarning: Passing a negative integer is deprecated in version 1.0 and will not be supported in future version. Instead, use None to not limit the column width.
pd.set_option(‘display.max_colwidth’, -1)
Traceback (most recent call last):
File “/home/ncpd241/Service/”, line 367, in
File “/home/ncpd241/Service/”, line 355, in service
POLNUM, prediction_score, prediction_STP = predict_application(policy_all_features)
File “/home/ncpd241/Service/”, line 330, in predict_application
model = joblib.load(’/home/ncpd241/Service/SI_MODEL_FINAL.pkl’)
File “/usr/local/lib/python3.6/dist-packages/joblib/”, line 605, in load
obj = _unpickle(fobj, filename, mmap_mode)
File “/usr/local/lib/python3.6/dist-packages/joblib/”, line 529, in _unpickle
obj = unpickler.load()
File “/usr/lib/python3.6/”, line 1050, in load
File “/usr/local/lib/python3.6/dist-packages/joblib/”, line 342, in load_build
File “/usr/lib/python3.6/”, line 1507, in load_build
File “/usr/local/lib/python3.6/dist-packages/xgboost/”, line 1094, in setstate
_LIB.XGBoosterUnserializeFromBuffer(handle, ptr, length))
File “/usr/local/lib/python3.6/dist-packages/xgboost/”, line 189, in _check_call
raise XGBoostError(py_str(LIB.XGBGetLastError()))
xgboost.core.XGBoostError: [11:57:39] /workspace/src/ Check failed: header == serialisation_header

If you are loading a serialized model (like pickle in Python) generated by older
XGBoost, please export the model by calling Booster.save_model from that version
first, then load it back in current version. There’s a simple script for helping
the process. See:

for reference to the script, and more details about differences between saving model and