I have a function pre_raw()
and pandas data train_raw.values
in python3 I could like this:
with concurrent.futures.ThreadPoolExecutor() as executor:
executor.map(pre_raw, train_raw.values)
How to wrote it on Python2?
Thanks.
I have a function pre_raw()
and pandas data train_raw.values
in python3 I could like this:
with concurrent.futures.ThreadPoolExecutor() as executor:
executor.map(pre_raw, train_raw.values)
How to wrote it on Python2?
Thanks.
procs=[]
for val in train_raw.values:
p = multiprocessing.Process(target=pre_raw, args=(val,))
procs.append(p)
p.start()
for p in procs:
p.join()