Pickle dump huge file without memory error

后端 未结 9 859
梦谈多话
梦谈多话 2020-12-23 14:26

I have a program where I basically adjust the probability of certain things happening based on what is already known. My file of data is already saved as a pickle

9条回答
  •  礼貌的吻别
    2020-12-23 14:56

    I had memory error and resolved it by using protocol=2:

    cPickle.dump(obj, file, protocol=2)

提交回复
热议问题