BUG: parallel crashes when array too big.
See original GitHub issueI am not sure whether this is a bug or a bad parametrization on my part, but I get an error when passing a unique large arrays to Parallel with max_nbytes=None, and n_jobs > 1.
from joblib import Parallel, delayed
import numpy as np
def func(X):
pass
X = np.random.rand(841, 306, 1445)
chunks = map(list, zip(*[np.array_split(X, 1)])) # note n_jobs > n_splits
parallel = Parallel(-1, max_nbytes=None)
p_func = delayed(func)
out = parallel(p_func(chunk) for chunk in chunks)
However, it works is max_nbytes isn’t provided, or when the array is smaller.
This issue is replicable on ubuntu 14.04 + anaconda build with joblib 0.9.4 and numpy 1.11.0
It may be related to https://github.com/joblib/joblib/issues/138
Issue Analytics
- State:
- Created 7 years ago
- Comments:14 (8 by maintainers)
Top Results From Across the Web
OpenMP Crashing with Large Arrays - fortran - Stack Overflow
Specifying -fopenmp in GNU Fortran implies -frecursive which means that all local variables (even large arrays) are automatic (i.e. allocated on the stack)....
Read more >Error reading and/or creating large meshes - FEAP User Forum
There seems to be a bug in parallel FEAP which effects reading or creating very large meshes. The bug is triggered mostly when...
Read more >Resolve "Out of Memory" Errors - MATLAB & Simulink
MATLAB has built-in protection against creating arrays that are too large. For example, this code results in an error, because MATLAB cannot create...
Read more >R session crash for a multinomial model; Multiple Indexing in ...
R session crash for a multinomial model; Multiple Indexing in arrays ... For another, I get the error for parallel chains ... (2)[array...
Read more >[Compute Shader] Compiler crashes when trying to read value ...
Update nope, it just moved the error, Definitely connected to arrays - Update confirmed nothing todo with the shader being too big, ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

It’s not pickle but multiprocessing. You can have a look at https://bugs.python.org/issue17560 for more details. I think this quote extracted from it pretty much sums it up:
ok thanks @lesteve & @ogrisel