ValueError in pickle module during unpickling a infinite float (python 2.5.2)
Peter Otten
__peter__ at web.de
Wed Mar 12 14:16:59 EDT 2008
rehn at iwm.mw.tu-dresden.de wrote:
> Unpickling an infinite float caused a ValueError in the pickle module.
> I need to pickle and load infinite floats in my project. Do you have
> any suggestions how to solve the issue?
You could try another protocol. Does
>>> inf = 1e1000
>>> pickle.loads(pickle.dumps(inf, pickle.HIGHEST_PROTOCOL))
inf
work?
Peter
More information about the Python-list
mailing list