A friendly fork of multiprocessing which uses dill instead of pickle
Project description
Multiprocessing on Dill
This project is a friendly fork – for Python 3 – of the Python Standard Library multiprocessing module, which uses the third-party dill serializer instead of the standard pickle serializer. This overcomes many shortcomings of pickle which prevent multiprocessing being used with lambdas, closures and other useful Python objects.
The easiest way to use multiprocessing_on_dill in place of multiprocessing is simply to replace any import statements like this:
import multiprocessing
with:
import multiprocessing_on_dill as multiprocessing
and import statements like this:
from multiprocessing import Pool
with:
from multiprocessing_on_dill import Pool
With such import changes in place, it will now be possible to use functions like Pool.map() with lambdas:
pool = Pool(12) result = pool.map(lambda x: x*x, range(10000))
Everything else should be identical to the Python version.
You can determine from which version of the Python Standard Library multiprocessing_on_dill has been forked, by examining the multiprocessing_on_dill.__version__ attribute.
Future
It is our hope that one day the Python Standard Library pickle module will gain the additional capabilities of dill and there will no longer be a need for multiprocessing_on_dill to exist.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file multiprocessing_on_dill-3.5.0a4.tar.gz
.
File metadata
- Download URL: multiprocessing_on_dill-3.5.0a4.tar.gz
- Upload date:
- Size: 53.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d6d50c300ff4bd408bb71eb78725e60231039ee9b3d0d9bb7697b9d0e15045e7 |
|
MD5 | cd9da5a57987eddb0040939296fe3c3d |
|
BLAKE2b-256 | 864d4b135e2e5cd0194eb29f2ed36e9a77a07596787a9a8ac2279bd4445398f2 |