Preprocessing: use all available threads

...the limitation to 8 threads looks a bit random to me.
This commit is contained in:
Jan Engelmohr 2018-11-18 21:39:45 +01:00 committed by GitHub
parent a2ba23c3da
commit 113e582b8a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8,8 +8,8 @@ from multiprocessing.dummy import Pool
from util.audio import audiofile_to_input_vector
from util.text import text_to_char_array
def pmap(fun, iterable, threads=8):
pool = Pool(threads)
def pmap(fun, iterable):
pool = Pool()
results = pool.map(fun, iterable)
pool.close()
return results