Closed MilesCranmer closed 5 months ago
Awesome...we were also running into trouble with pickled model files with Caleb. Pytorch seemed to suggest this to avoid pickling:
https://pytorch.org/tutorials/beginner/saving_loading_models.html#saving-loading-model-for-inference
Safetensors is more robust?
Yeah safetensors is pretty much all that they recommend there, plus additional stuff to make it even safer (since pickle allows arbitrary code execution).
Also don't merge this yet; trying to fix some issues...
If you figure it out, could you tell Caleb how you did it so we can save his models your way? With pickle it also causes problems being loaded in a different module from the one in which it was saved.
What is his branch?
working on the caleb branch
Thanks!
Okay I think this PR is ready for review. I also removed the pandas and matplotlib dependency for good measure.
Re: Caleb's branch, I don't see data for the model stored anywhere (?)
Also is there a test to try it out on for debugging?
Thanks so much Miles. Will merge these changes into the caleb branch and add a test
Also I made the README example of deep regressor a bit better.