I have some old sklearn models which I can't retrain. They were pickled long time ago with unclear versions. I can open them with Python 3.6 and Numpy 1.14. But when I try to move to Python 3.8 with Numpy 1.18, I get a segfault on loading them.
I tried dumping them with protocol 4 from Python 3.6, it didn't help.
Saving:
with open('model.pkl', 'wb') as fid:
pickle.dump(model, fid, protocol=4)
Loading:
model = pickle.load(open('model.pkl', "rb"))
Is there anything I can do in such situation?