preprocessing scripts