Commit fa96bee7 authored by Daniel Scheffler's avatar Daniel Scheffler
Browse files

Fixed config. Set Pool(CPUs, maxtasksperchild=1).

parent a66877a7
......@@ -113,7 +113,7 @@ gms_schema_input = dict(
write_output=dict(type='boolean', required=False),
delete_output=dict(type='boolean', required=False),
spechomo_method=dict(type='string', required=False, allowed=['LI', 'LR', 'RR']),
estimate_accuracy=dict(type='boolean', required=False),
spechomo_estimate_accuracy=dict(type='boolean', required=False),
)),
L2C=dict(type='dict', required=False, schema=dict(
run_processor=dict(type='boolean', required=False),
......
......@@ -58,7 +58,7 @@ def imap_unordered(func, args, CPUs=None, flatten_output=False):
CPUs = CPUs if CPUs <= CFG.CPUs else CFG.CPUs # treat CFG.CPUs as maximum number of CPUs
if CPUs and CPUs > 1 and len(args) > 1:
with Pool(CPUs) as pool:
with Pool(CPUs, maxtasksperchild=1) as pool:
results = list(pool.imap_unordered(func, args)) # returns an iterator
else:
results = [func(argset) for argset in args] # generator does not always work properly here
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment