Added multiprocessing capability