Remove path cleaning from genpath

Path cleanup was taking a long time (>1 second)