Changed bgprocess to use multiprocessing instead of threading