Commit 647dad88 authored by Gaetano Raffaele's avatar Gaetano Raffaele

ENH: Made classification step parallel (using Nproc)

parent a603b304
......@@ -816,8 +816,9 @@ def queuedProcess(cmd_list,N_processes=4,shell=False,delay=0):
prc_queue = []
for t in range(N_processes):
prc_queue.append(subprocess.Popen(cmd_queue.pop(0), shell=shell))
time.sleep(delay)
if len(cmd_queue) > 0:
prc_queue.append(subprocess.Popen(cmd_queue.pop(0), shell=shell))
time.sleep(delay)
while len(prc_queue) > 0:
for i in range(len(prc_queue)):
......
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