Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8dac47f commit 9f21406Copy full SHA for 9f21406
1 file changed
lib/core/bigarray.py
@@ -5,8 +5,12 @@
5
See the file 'doc/COPYING' for copying permission
6
"""
7
8
+try:
9
+ import cPickle as pickle
10
+except:
11
+ import pickle
12
+
13
import os
-import pickle
14
import tempfile
15
16
from lib.core.settings import BIGARRAY_CHUNK_LENGTH
@@ -62,7 +66,7 @@ def _dump(self, value):
62
66
self.filenames.add(filename)
63
67
os.close(handle)
64
68
with open(filename, "w+b") as fp:
65
- pickle.dump(value, fp)
69
+ pickle.dump(value, fp, pickle.HIGHEST_PROTOCOL)
70
return filename
71
72
def _checkcache(self, index):
0 commit comments