adding joblib parallelization