Added parrallel functionality