I'm trying to load the dumped files, using the following code:
cols = None
with open('./experiments/columns.p', 'rb') as p:
cols = pkl.loads(p).read()
but i get this error instead:
"a bytes-like object is required, not '_io.BufferedReader' "
You're using pickle, so you should use the pickle.load function:
import pickle
with open('./experiments/columns.p', 'rb') as p:
cols = pickle.load(p)
This is less likely to trigger a MemoryError.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With