Can't pickle <class 'MemoryError'>: it's not the same object as builtins.MemoryError - Python

Viewed 219

I'm trying to run the code from this link https://github.com/sdorkenw/CompressedSensing/blob/master/sensing.py It gives me this error:

Traceback (most recent call last):
  File "/home/kali/Desktop/CompressedSensing/sensing.py", line 319, in <module>
    sense_multiple(img_path, ks, alphas, folder=folder,
  File "/home/kali/Desktop/CompressedSensing/sensing.py", line 295, in sense_multiple
    pool.map(_sense_thread, params)
  File "/usr/lib/python3.9/multiprocessing/pool.py", line 364, in map
    return self._map_async(func, iterable, mapstar, chunksize).get()
  File "/usr/lib/python3.9/multiprocessing/pool.py", line 771, in get
    raise self._value
multiprocessing.pool.MaybeEncodingError: Error sending result: '<multiprocessing.pool.ExceptionWithTraceback object at 0x7f28d105bb20>'. Reason: 'PicklingError("Can't pickle <class 'MemoryError'>: it's not the same object as builtins.MemoryError")'

As far as i know this is related to pool, so how can i fix this?

0 Answers
Related