Unable to create pickle file of a model with Transformer+fastai
Need help, please tell us how to save this kind of model? learner.export() is not working its giving following error- PicklingError: Can’t pickle <function at 0x7fdfbffea1e0>: attribute lookup on main failed
I follow this tutorial https://towardsdatascience.com/fastai-with-transformers-bert-roberta-xlnet-xlm-distilbert-4f41ee18ecb2
So, now what should I do?
I trained my model on colab and created the .pth model. It was working properly on it, but when I started working on a local machine It gave me such error-
“BrokenProcessPool: A process in the process pool was terminated abruptly while the future was running or pending.”
This error is occurring when I am trying to create a databunch on a local machine.