Changing this to directly use multiprocessing from python